mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] ASoC: Intel: kmb_platform: select BITREVERSE
@ 2026-11-04 13:51 Jude Gyimah
  2026-11-13 21:21 ` Mark Brown
  0 siblings, 1 reply; 2+ messages in thread
From: Jude Gyimah @ 2026-11-04 13:51 UTC (permalink / raw)
  To: cezary.rojewski, liam.r.girdwood, peter.ujfalusi,
	yung-chuan.liao, kai.vehmanen, broonie
  Cc: pierre-louis.bossart, perex, tiwai, linux-sound, linux-kernel,
	Jude Gyimah

kmb_platform calls byte_rev_table, which lib/bitrev.c provides under
BITREVERSE.

  kmb_platform.c:(.text+0x1473): undefined reference to `byte_rev_table'

The driver can be built into vmlinux while GENERIC_BITREVERSE is a module,
in which case the symbol is not there at link time.

Select rather than depend on: BITREVERSE has no prompt of its own and is
only ever enabled by a select, so a depends on would leave
SND_SOC_INTEL_KEEMBAY unselectable.

BITREVERSE is the symbol to select rather than GENERIC_BITREVERSE: it
selects GENERIC_BITREVERSE only where the architecture has no native
implementation, so this stays correct on the architectures that do.

Reproduced on v7.3, x86_64, with CONFIG_SND_SOC_INTEL_KEEMBAY=y and
CONFIG_GENERIC_BITREVERSE=m.

Found with kreach, a static check that compares what Kconfig allows
against the symbols the compiled objects actually reference.

Fixes: c5477e966728 ("ASoC: Intel: Add KeemBay platform driver")
Signed-off-by: Jude Gyimah <jude.gyimah87@gmail.com>
---
The checker is at https://github.com/JGyimah/kreach, and the
reproducer configuration for each finding is published with it
under results/.

 sound/soc/intel/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/sound/soc/intel/Kconfig b/sound/soc/intel/Kconfig
index 63367364916a..3d361778a48d 100644
--- a/sound/soc/intel/Kconfig
+++ b/sound/soc/intel/Kconfig
@@ -87,6 +87,7 @@ config SND_SOC_INTEL_KEEMBAY
 	tristate "Keembay Platforms"
 	depends on ARCH_KEEMBAY || COMPILE_TEST
 	depends on COMMON_CLK
+	select BITREVERSE
 	select SND_DMAENGINE_PCM
 	select SND_SOC_GENERIC_DMAENGINE_PCM
 	help
-- 
2.43.0


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2026-11-15 11:43 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-04 13:51 [PATCH] ASoC: Intel: kmb_platform: select BITREVERSE Jude Gyimah
2026-11-13 21:21 ` Mark Brown

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®