From: Andrey Golovko <andrey.golovko@gmail.com>
To: Shenghao Ding <shenghao-ding@ti.com>, Kevin Lu <kevin-lu@ti.com>,
Baojun Xu <baojun.xu@ti.com>, Sen Wang <sen@ti.com>,
Liam Girdwood <lgirdwood@gmail.com>,
Mark Brown <broonie@kernel.org>, Jaroslav Kysela <perex@perex.cz>,
Takashi Iwai <tiwai@suse.com>
Cc: "Holalu Yogendra, Niranjan" <niranjan.hy@ti.com>,
Pierre-Louis Bossart <pierre-louis.bossart@linux.dev>,
Charles Keepax <ckeepax@opensource.cirrus.com>,
Vijendar Mukunda <Vijendar.Mukunda@amd.com>,
Antoine Monnet <antoine@montane.tech>,
Robin Everaars <robineveraars@pm.me>,
Ville Saarinen <wiza@saarinenkoti.fi>,
linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH v2 0/2] ASoC: tas2783-sdw: fix the read-only Control handling
Date: Fri, 14 Aug 2026 09:40:00 +0300 [thread overview]
Message-ID: <20260814094000.22118-1-andrey.golovko@gmail.com> (raw)
The two read-only Control patches from 13 August, resent together as a
series because the second one depends on the first, and with the change
Mark asked for.
He pointed out that the XU22 Control 0x14 in the read-only list is
SDCA_CTL_XU_FDL_STATUS, which sdca_fdl_process() writes. He is right,
and the description I gave it - "firmware download status" - reads like
a status the device owns, which it is not. It is a handshake: the
device sets the bits it owns, and the host writes its response back into
the same Control, keeping the device bits, which is exactly what
sdca_fdl_process() does with response | (status & ~SDCA_CTL_XU_FDLH_MASK).
So it is out of the list in 1/2.
Whether the write is reachable on this device today: the driver
registers no SDCA interrupts and never calls into sdca_fdl.c. It
downloads its firmware itself, with request_firmware_nowait() and its
own container format in tas2783_fw_ready(), and the machines I have
describe no Smart Amp SDCA function in the BIOS at all, so nothing
populates the interrupt that would drive the state machine. But the
Function does implement the FDL Controls - the driver lists 0x10 and
0x12 through 0x16 in its defaults - so the state machine is a plausible
thing for this driver to grow, and _regmap_write() answers -EIO for a
register the callback refuses. That would break the handshake at the
first response. Not a trap worth planting for one entry in a list.
2/2 still keeps the Control out of the cache, and now says why on its
own: sdca_fdl_process() reads it to see what the device asked for, and a
cached answer would hide the device half of the handshake. Writable and
volatile, which is the normal shape for a handshake register.
The two are otherwise unchanged. The behaviour I measured on an ASUS
ProArt PX13 for v1 stands: the calibration data written at probe is byte
for byte what it was before the series, and a read of the PDE23 actual
power state answers 0x0 with the Function powered, where before it
answered the 0x3 placeholder from the defaults. The only difference in
v2 is that a write to the File Download Status is no longer rejected,
and nothing in the driver issues one.
The questions in 1/2 stand as well: the list is static because
sdca_regmap_writeable() is not available to a driver running its
fallback tables, so it would be good to have it confirmed against the
documentation, and to know whether the read-only Controls were meant to
be in tas2783_reg_default[] at all.
Andrey Golovko (2):
ASoC: tas2783-sdw: do not treat read-only Controls as writable
ASoC: tas2783-sdw: do not cache read-only Controls
sound/soc/codecs/tas2783-sdw.c | 99 +++++++++++++++++++++++-----------
1 file changed, 68 insertions(+), 31 deletions(-)
next reply other threads:[~2026-08-14 7:16 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-14 6:40 Andrey Golovko [this message]
2026-08-14 6:40 ` [PATCH v2 2/2] ASoC: tas2783-sdw: do not cache read-only Controls Andrey Golovko
2026-08-14 15:13 ` Mark Brown
2026-08-15 11:45 ` Andrey Golovko
2026-08-18 8:16 ` Charles Keepax
2026-08-24 10:40 ` Andrey Golovko
2026-08-14 6:40 ` [PATCH v2 1/2] ASoC: tas2783-sdw: do not treat read-only Controls as writable Andrey Golovko
2026-08-14 15:21 ` (subset) [PATCH v2 0/2] ASoC: tas2783-sdw: fix the read-only Control handling Mark Brown
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=20260814094000.22118-1-andrey.golovko@gmail.com \
--to=andrey.golovko@gmail.com \
--cc=Vijendar.Mukunda@amd.com \
--cc=antoine@montane.tech \
--cc=baojun.xu@ti.com \
--cc=broonie@kernel.org \
--cc=ckeepax@opensource.cirrus.com \
--cc=kevin-lu@ti.com \
--cc=lgirdwood@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-sound@vger.kernel.org \
--cc=niranjan.hy@ti.com \
--cc=perex@perex.cz \
--cc=pierre-louis.bossart@linux.dev \
--cc=robineveraars@pm.me \
--cc=sen@ti.com \
--cc=shenghao-ding@ti.com \
--cc=tiwai@suse.com \
--cc=wiza@saarinenkoti.fi \
/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®