ASoC: rt766: fix HID dependency for SND_SOC_SDCA_HID
PATCH 1/1 ASoC: rt766: fix HID dependency for SND_SOC_SDCA_HID
From: Arnd Bergmann <[email protected]>
Selecting SND_SOC_SDCA_HID only works if HID is enabled:
WARNING: unmet direct dependencies detected for SND_SOC_SDCA_HID
Depends on [n]: SOUND [=y] && SND [=y] && SND_SOC [=y] && SND_SOC_SDCA [=y] && (HID [=n]=y [=y] || HID [=n]=SND_SOC_SDCA [=y]) Selected by [y]:
- SND_SOC_RT766_SDCA_SDW [=y] && SOUND [=y] && SND [=y] && SND_SOC [=y] && SOUNDWIRE [=y] && SND_SOC_SDCA [=y]
Add this an a dependency to SND_SOC_RT766_SDCA_SDW as well.
--- sound/soc/codecs/Kconfig | 1 + 1 file changed, 1 insertion(+)
sound/soc/codecs/Kconfig +1 -0
@@ -1992,6 +1992,7 @@ config SND_SOC_RT766_SDCA_SDW tristate "Realtek RT766 SDCA Codec - SDW" depends on SOUNDWIRE depends on SND_SOC_SDCA + depends on HID select SND_SOC_SDCA_HID select SND_SOC_SDCA_IRQ select REGMAP_SOUNDWIRE
Signature · 1 line
2.53.0
Mark Brown
maintainerQuoted 7 lines · Arnd Bergmann
From: Arnd Bergmann <[email protected]>
Selecting
SND_SOC_SDCA_HIDonly works if HID is enabled:
sound/soc/codecs/Kconfig config SND_SOC_RT766_SDCA_SDW · line 1998
Quoted 7 lines
sound/soc/codecs/Kconfig +1
-0@@ -1992,6 +1992,7 @@ config SND_SOC_RT766_SDCA_SDW tristate "Realtek RT766 SDCA Codec - SDW" depends on SOUNDWIRE depends on SND_SOC_SDCA + depends on HID select SND_SOC_SDCA_HID select SND_SOC_SDCA_IRQ select REGMAP_SOUNDWIRE
Should that be HID=y || HID=SND_SOC_SDCA like for SND_SOC_SDCA_HID and SND_SOC_SDCA_CLASS? The dependencies on _CLASS should stop the problematic cases from actually occurring but I'm not sure if it stops the warning.
Quoted 1 line · Mark Brown
On Tue, Sep 15, 2026 at 11:16:34PM +0200, Arnd Bergmann wrote:
...
Quoted 5 lines
Quoted 5 lines
config
SND_SOC_RT766_SDCA_SDWsound/soc/codecs/Kconfig +1
-0tristate "Realtek RT766 SDCA Codec - SDW" depends on SOUNDWIRE depends on SND_SOC_SDCA + depends on HID
Quoted 8 lines
sound/soc/codecs/Kconfig config SND_SOC_RT766_SDCA_SDW · line 1998
Quoted 3 lines
sound/soc/codecs/Kconfig +0
-0select SND_SOC_SDCA_HID select SND_SOC_SDCA_IRQ select REGMAP_SOUNDWIREShould that be HID=y || HID=SND_SOC_SDCA like for
SND_SOC_SDCA_HIDandSND_SOC_SDCA_CLASS? The dependencies on_CLASSshould stop the problematic cases from actually occurring but I'm not sure if it stops the warning.
(Based just on this comment without looking into details) there is also 'depends on FOO if BAR' syntax that might be useful.
Signature · 2 lines
With Best Regards, Andy Shevchenko
Quoted 5 lines · Mark Brown
Quoted 3 lines · Arnd Bergmann
From: Arnd Bergmann <[email protected]>
Selecting
SND_SOC_SDCA_HIDonly works if HID is enabled:
Quoted 15 lines
sound/soc/codecs/Kconfig config SND_SOC_RT766_SDCA_SDW · line 1998
Quoted 10 lines
sound/soc/codecs/Kconfig +1
-0@@ -1992,6 +1992,7 @@ config SND_SOC_RT766_SDCA_SDW tristate "Realtek RT766 SDCA Codec - SDW" depends on SOUNDWIRE depends on SND_SOC_SDCA + depends on HID select SND_SOC_SDCA_HID select SND_SOC_SDCA_IRQ select REGMAP_SOUNDWIREShould that be HID=y || HID=SND_SOC_SDCA like for
SND_SOC_SDCA_HIDandSND_SOC_SDCA_CLASS? The dependencies on_CLASSshould stop the problematic cases from actually occurring but I'm not sure if it stops the warning.
Yes. Just as I was trying to write up my presentation slides for next week trying to explain how nobody ever gets this right, you have reminded me that I can't do it either ;-)
How about this version?
sound/soc/codecs/Kconfig +1 -4
@@ -1991,10 +1991,7 @@ config SND_SOC_RT715_SDCA_SDW config SND_SOC_RT766_SDCA_SDW tristate "Realtek RT766 SDCA Codec - SDW" depends on SOUNDWIRE - depends on SND_SOC_SDCA - depends on HID - select SND_SOC_SDCA_HID - select SND_SOC_SDCA_IRQ + depends on SND_SOC_SDCA_CLASS select REGMAP_SOUNDWIRE select REGMAP_SOUNDWIRE_MBQ
I think this is much clearer than the original version or my first patch, as it avoids the fragile 'select'. If you like this one, I'll send a v2 after this passes some more randconfig testing, or you can apply that directly.
Arnd
Quoted 42 lines · Arnd Bergmann
Quoted 18 lines · Mark Brown
sound/soc/codecs/Kconfig config SND_SOC_RT766_SDCA_SDW · line 1998
Quoted 12 lines · Arnd Bergmann
Selecting
SND_SOC_SDCA_HIDonly works if HID is enabled:sound/soc/codecs/Kconfig +1
-0@@ -1992,6 +1992,7 @@ config SND_SOC_RT766_SDCA_SDW tristate "Realtek RT766 SDCA Codec - SDW" depends on SOUNDWIRE depends on SND_SOC_SDCA + depends on HID select SND_SOC_SDCA_HID select SND_SOC_SDCA_IRQ select REGMAP_SOUNDWIREShould that be HID=y || HID=SND_SOC_SDCA like for
SND_SOC_SDCA_HIDandSND_SOC_SDCA_CLASS? The dependencies on_CLASSshould stop the problematic cases from actually occurring but I'm not sure if it stops the warning.Yes. Just as I was trying to write up my presentation slides for next week trying to explain how nobody ever gets this right, you have reminded me that I can't do it either ;-)
How about this version?
sound/soc/codecs/Kconfig +1
-4@@ -1991,10 +1991,7 @@ config SND_SOC_RT715_SDCA_SDW config SND_SOC_RT766_SDCA_SDW tristate "Realtek RT766 SDCA Codec - SDW" depends on SOUNDWIRE - depends on SND_SOC_SDCA - depends on HID - select SND_SOC_SDCA_HID - select SND_SOC_SDCA_IRQ + depends on SND_SOC_SDCA_CLASS select REGMAP_SOUNDWIRE select REGMAP_SOUNDWIRE_MBQ
Quoted 4 lines
I think this is much clearer than the original version or my first patch, as it avoids the fragile 'select'. If you like this one, I'll send a v2 after this passes some more randconfig testing, or you can apply that directly.
This seems a little odd though, as the driver doesn't actually depend on SND_SOC_SDCA_CLASS. That builds in the actual class driver, which this driver doesn't use, it only uses functions from the SDCA library.
THanks,
Charles
Mark Brown
maintainerQuoted 17 lines · Arnd Bergmann
Quoted 10 lines · Mark Brown
Review
Quoted 3 lines · Arnd Bergmann
(quoted diff) +1
-0depends on SOUNDWIRE depends on SND_SOC_SDCA + depends on HIDShould that be HID=y || HID=SND_SOC_SDCA like for
SND_SOC_SDCA_HIDandSND_SOC_SDCA_CLASS? The dependencies on_CLASSshould stop the problematic cases from actually occurring but I'm not sure if it stops the warning.Yes. Just as I was trying to write up my presentation slides for next week trying to explain how nobody ever gets this right, you have reminded me that I can't do it either ;-)
How about this version?
...
Quoted 4 lines
I think this is much clearer than the original version or my first patch, as it avoids the fragile 'select'. If you like this one, I'll send a v2 after this passes some more randconfig testing, or you can apply that directly.
Looks good to me but I'm not entirely confident in my Kconfig special case knowledge, I'll wait for your new version after testing.