From: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
To: Valerio Setti <vsetti@baylibre.com>, xianwei.zhao@amlogic.com
Cc: Jerome Brunet <jbrunet@baylibre.com>,
Liam Girdwood <lgirdwood@gmail.com>,
Mark Brown <broonie@kernel.org>, Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
Neil Armstrong <neil.armstrong@linaro.org>,
Kevin Hilman <khilman@baylibre.com>,
Jaroslav Kysela <perex@perex.cz>, Takashi Iwai <tiwai@suse.com>,
linux-sound@vger.kernel.org, devicetree@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-amlogic@lists.infradead.org, linux-kernel@vger.kernel.org,
Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
Subject: Re: [PATCH v5 1/7] ASoC: dt-bindings: add amlogic,gxbb-audin
Date: Tue, 24 Nov 2026 22:14:38 +0100 [thread overview]
Message-ID: <CAFBinCCd==1Vf7jMCHP0VuWTNa7A5FvRfPYdk2zUaZ8eR54Z+A@mail.gmail.com> (raw)
In-Reply-To: <71ede0e6-7f8f-4594-ae56-5be10f9159a3@baylibre.com>
Hi Valerio,
+Cc Xianwei Zhao, I would appreciate it if you could take some time to
help us clarify the questions below (or refer us to a colleague).
On Mon, Nov 16, 2026 at 11:24 PM Valerio Setti <vsetti@baylibre.com> wrote:
>
> Hi Martin
>
> >> +properties:
> >> + compatible:
> >> + oneOf:
> >> + - const: amlogic,gxbb-audin
> >> + - items:
> >> + - const: amlogic,gxl-audin
> >> + - const: amlogic,gxbb-audin
> > From what I can tell it's even amlogic,meson8-audin compatible.
> > Although I didn't have the time to test in on hardware yet.
> >
>
> Thanks for catching it!
> Any testing is more than welcome. I don't have that board at home and,
> based on my quick search, it seems not super easy to find one these days.
>
> > [...]
> >> + audio-controller@a000 {
> >> + compatible = "amlogic,gxbb-audin";
> >> + reg = <0xa000 0x148>;
> > I believe the audin registers are 0x300 wide.
> > Both, GXL datasheet [0] page 43 and GXM datasheet [1] page 48 claim
> > that the register area is 0x100 wide.
> > The last documented register with AUDIN_ prefix is AUDIN_FIFO2_PIO_RDH
> > = 0xb8. The datasheet [0] (page 395) lists register numbers divided by
> > 4, so to get the actual address in the memory map we need to multiply
> > it by 4, which gives 0x2e0.
> > The 32-bit SoC vendor kernel [2] has a header that states: #define
> > AUDIN_ADDR_END 0x28bf (same as in datasheet, we need to multiply this
> > by 4).
>
> I know that the register layout in these SoC is a bit messy, so let me
> explain how I got to the 0x148 that I wrote above.
>
> When working at this driver I used the S095 and S905X manuals that I
> found online, but based on the link you shared for the S912, I would say
> it's the same when it comes to AUDIN.
>
> Using [0] as reference, the highest register being mentioned in the
> AUDIN chapter is AUD_RESAMPLE_STATUS whose offset is 0x304 (i.e. 0xc1 *
> 4). However I noticed that before that there are a lot of registers
> whose name doesn't start with AUDIN_, but rather with AUDOUT_, PCMOUT_,
> PCMIN_.
> The first contiguous block of AUDIN_ stops at AUDIN_FIFO_INT which is
> 0x148 (= 0x52 * 4). The other AUDIN_ block you mentioned is between
> AUDIN_FIFO0_PIO_STS (at 0x2c0) and AUDIN_FIFO2_PIO_RDH (at 0x2e0).
Your approach is logical. And I have no way of proving my theory.
So the question for someone with access to better documentation or the
actual hardware description is:
- how big is the AUDIN IP block register space?
- what inputs are routed to the AUDIN IP block that neither Valerio
nor I identified so far (one reset line, one clock input, one
interrupt)?
> > I'm bringing this up because dt-bindings are supposed to be complete.
> > So even if the driver doesn't use a resource yet we're supposed to
> > still describe it.
>
> I perfectly agree with this, but at the same time I thought that
> including registers which potentially do not belong to AUDIN was
> dangerous in the other direction, i.e. we cover a too large area that
> will be hard to use in the future if/when we want to use it and we
> realize it's really not part of AUDIN.
My concern is actually that the AUDIN hardware block spans 0x300 (or
close to it) and we'll find out later that there's a bit that we need
to toggle which is outside of the 0x148 area covered already.
Even worse: what if we put another register area after AUDIN and then
find out that this theoretical bit sits in the second register area.
Best regards,
Martin
_______________________________________________
linux-amlogic mailing list
linux-amlogic@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-amlogic
next prev parent reply other threads:[~2026-11-24 21:14 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-18 10:17 [PATCH v5 0/7] ASoC: meson: gx: add base support for I2S audio input Valerio Setti
2026-10-18 10:17 ` [PATCH v5 1/7] ASoC: dt-bindings: add amlogic,gxbb-audin Valerio Setti
2026-11-15 21:03 ` Martin Blumenstingl
2026-11-16 22:24 ` Valerio Setti
2026-11-24 21:14 ` Martin Blumenstingl [this message]
2026-10-18 10:17 ` [PATCH v5 2/7] ASoC: meson: build gx-formatter as a separate module Valerio Setti
2026-11-15 21:04 ` Martin Blumenstingl
2026-10-18 10:18 ` [PATCH v5 3/7] ASoC: meson: aiu-encoder-i2s: ensure clk divider gets disabled in hw_free Valerio Setti
2026-11-15 21:09 ` Martin Blumenstingl
2026-10-18 10:18 ` [PATCH v5 4/7] ASoC: meson: add AUDIN driver Valerio Setti
2026-10-18 10:39 ` sashiko-bot
2026-10-20 13:02 ` Valerio Setti
2026-10-22 7:13 ` Valerio Setti
2026-11-15 21:26 ` Martin Blumenstingl
2026-10-18 10:18 ` [PATCH v5 5/7] ASoC: meson: aiu: add I2S Capture DAI Valerio Setti
2026-11-15 21:27 ` Martin Blumenstingl
2026-10-18 10:18 ` [PATCH v5 6/7] ASoC: meson: gx-card: add support for audin FIFO Valerio Setti
2026-11-15 21:28 ` Martin Blumenstingl
2026-11-16 23:06 ` Valerio Setti
2026-11-24 21:21 ` Martin Blumenstingl
2026-11-25 22:26 ` Valerio Setti
2026-10-18 10:18 ` [PATCH v5 7/7] arm64: dts: amlogic: gx: add AUDIN node Valerio Setti
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAFBinCCd==1Vf7jMCHP0VuWTNa7A5FvRfPYdk2zUaZ8eR54Z+A@mail.gmail.com' \
--to=martin.blumenstingl@googlemail.com \
--cc=broonie@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=jbrunet@baylibre.com \
--cc=khilman@baylibre.com \
--cc=krzk+dt@kernel.org \
--cc=krzysztof.kozlowski@oss.qualcomm.com \
--cc=lgirdwood@gmail.com \
--cc=linux-amlogic@lists.infradead.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-sound@vger.kernel.org \
--cc=neil.armstrong@linaro.org \
--cc=perex@perex.cz \
--cc=robh@kernel.org \
--cc=tiwai@suse.com \
--cc=vsetti@baylibre.com \
--cc=xianwei.zhao@amlogic.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®