ASoC: SDCA: fix HID dependency
authorArnd Bergmann <arnd@arndb.de>
Wed, 9 Jul 2025 15:24:17 +0000 (17:24 +0200)
committerMark Brown <broonie@kernel.org>
Wed, 9 Jul 2025 15:42:22 +0000 (16:42 +0100)
commitad4655653a6c463026ed3c300e5fb34f39abff48
treee8014960bf8376b679505b869d7a5acc46cb8ffb
parentf5b92c7449a2905963083836150f1085ce9d58c9
ASoC: SDCA: fix HID dependency

It is not possible to enable SND_SOC_SDCA_HID when SND_SOC_SDCA is built-in
but HID is in a loadable module, as that results in a link failure:

x86_64-linux-ld: sound/soc/sdca/sdca_functions.o: in function `find_sdca_entity_hide':
sdca_functions.c:(.text+0x25b): undefined reference to `sdca_add_hid_device'

Change SND_SOC_SDCA_HID into a 'bool' option that can only be enabled
if this results in a working build, and change the Makefile so this driver
is a loadable module if possible.

Fixes: ac558015dfd8 ("ASoC: SDCA: add a HID device for HIDE entity")
Reviewed-by: Charles Keepax <ckeepax@opensource.cirrus.com>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Link: https://patch.msgid.link/20250709152430.1498427-1-arnd@kernel.org
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/sdca/Kconfig
sound/soc/sdca/Makefile