Message ID | 20200418090853.30340-1-yuehaibing@huawei.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | ASoC: wm89xx: Fix build error without CONFIG_I2C | expand |
On Sat, Apr 18, 2020 at 05:08:53PM +0800, YueHaibing wrote: > sound/soc/codecs/wm8900.o: In function `wm8900_i2c_probe': > wm8900.c:(.text+0xa36): undefined reference to `__devm_regmap_init_i2c' > sound/soc/codecs/wm8900.o: In function `wm8900_modinit': > wm8900.c:(.init.text+0xb): undefined reference to `i2c_register_driver' > sound/soc/codecs/wm8900.o: In function `wm8900_exit': > wm8900.c:(.exit.text+0x8): undefined reference to `i2c_del_driver' > sound/soc/codecs/wm8988.o: In function `wm8988_i2c_probe': > wm8988.c:(.text+0x857): undefined reference to `__devm_regmap_init_i2c' > sound/soc/codecs/wm8988.o: In function `wm8988_modinit': > wm8988.c:(.init.text+0xb): undefined reference to `i2c_register_driver' > sound/soc/codecs/wm8988.o: In function `wm8988_exit': > wm8988.c:(.exit.text+0x8): undefined reference to `i2c_del_driver' > sound/soc/codecs/wm8995.o: In function `wm8995_i2c_probe': > wm8995.c:(.text+0x1c4f): undefined reference to `__devm_regmap_init_i2c' > sound/soc/codecs/wm8995.o: In function `wm8995_modinit': > wm8995.c:(.init.text+0xb): undefined reference to `i2c_register_driver' > sound/soc/codecs/wm8995.o: In function `wm8995_exit': > wm8995.c:(.exit.text+0x8): undefined reference to `i2c_del_driver' > > Add missing I2C dependency to fix this. > This doesn't look like the right fix there, all these parts can be used on SPI so should be usable without I2C build in. Thanks, Charles
On 2020/4/20 18:27, Charles Keepax wrote: > On Sat, Apr 18, 2020 at 05:08:53PM +0800, YueHaibing wrote: >> sound/soc/codecs/wm8900.o: In function `wm8900_i2c_probe': >> wm8900.c:(.text+0xa36): undefined reference to `__devm_regmap_init_i2c' >> sound/soc/codecs/wm8900.o: In function `wm8900_modinit': >> wm8900.c:(.init.text+0xb): undefined reference to `i2c_register_driver' >> sound/soc/codecs/wm8900.o: In function `wm8900_exit': >> wm8900.c:(.exit.text+0x8): undefined reference to `i2c_del_driver' >> sound/soc/codecs/wm8988.o: In function `wm8988_i2c_probe': >> wm8988.c:(.text+0x857): undefined reference to `__devm_regmap_init_i2c' >> sound/soc/codecs/wm8988.o: In function `wm8988_modinit': >> wm8988.c:(.init.text+0xb): undefined reference to `i2c_register_driver' >> sound/soc/codecs/wm8988.o: In function `wm8988_exit': >> wm8988.c:(.exit.text+0x8): undefined reference to `i2c_del_driver' >> sound/soc/codecs/wm8995.o: In function `wm8995_i2c_probe': >> wm8995.c:(.text+0x1c4f): undefined reference to `__devm_regmap_init_i2c' >> sound/soc/codecs/wm8995.o: In function `wm8995_modinit': >> wm8995.c:(.init.text+0xb): undefined reference to `i2c_register_driver' >> sound/soc/codecs/wm8995.o: In function `wm8995_exit': >> wm8995.c:(.exit.text+0x8): undefined reference to `i2c_del_driver' >> >> Add missing I2C dependency to fix this. >> > > This doesn't look like the right fix there, all these parts can > be used on SPI so should be usable without I2C build in. Sorry, the patch title is wrong, the issue is CONFIG_I2C m but SND_SOC_WM8900 is y. This should depends on SND_SOC_I2C_AND_SPI like others. > > Thanks, > Charles > > . >
diff --git a/sound/soc/codecs/Kconfig b/sound/soc/codecs/Kconfig index e6a0c5d05fa5..2d8d0bba0c0a 100644 --- a/sound/soc/codecs/Kconfig +++ b/sound/soc/codecs/Kconfig @@ -1525,6 +1525,7 @@ config SND_SOC_WM8804_SPI config SND_SOC_WM8900 tristate + depends on I2C config SND_SOC_WM8903 tristate "Wolfson Microelectronics WM8903 CODEC" @@ -1576,6 +1577,7 @@ config SND_SOC_WM8985 config SND_SOC_WM8988 tristate + depends on I2C config SND_SOC_WM8990 tristate @@ -1594,6 +1596,7 @@ config SND_SOC_WM8994 config SND_SOC_WM8995 tristate + depends on I2C config SND_SOC_WM8996 tristate
sound/soc/codecs/wm8900.o: In function `wm8900_i2c_probe': wm8900.c:(.text+0xa36): undefined reference to `__devm_regmap_init_i2c' sound/soc/codecs/wm8900.o: In function `wm8900_modinit': wm8900.c:(.init.text+0xb): undefined reference to `i2c_register_driver' sound/soc/codecs/wm8900.o: In function `wm8900_exit': wm8900.c:(.exit.text+0x8): undefined reference to `i2c_del_driver' sound/soc/codecs/wm8988.o: In function `wm8988_i2c_probe': wm8988.c:(.text+0x857): undefined reference to `__devm_regmap_init_i2c' sound/soc/codecs/wm8988.o: In function `wm8988_modinit': wm8988.c:(.init.text+0xb): undefined reference to `i2c_register_driver' sound/soc/codecs/wm8988.o: In function `wm8988_exit': wm8988.c:(.exit.text+0x8): undefined reference to `i2c_del_driver' sound/soc/codecs/wm8995.o: In function `wm8995_i2c_probe': wm8995.c:(.text+0x1c4f): undefined reference to `__devm_regmap_init_i2c' sound/soc/codecs/wm8995.o: In function `wm8995_modinit': wm8995.c:(.init.text+0xb): undefined reference to `i2c_register_driver' sound/soc/codecs/wm8995.o: In function `wm8995_exit': wm8995.c:(.exit.text+0x8): undefined reference to `i2c_del_driver' Add missing I2C dependency to fix this. Reported-by: Hulk Robot <hulkci@huawei.com> Fixes: ea00d95200d02ece ("ASoC: Use imply for SND_SOC_ALL_CODECS") Signed-off-by: YueHaibing <yuehaibing@huawei.com> --- sound/soc/codecs/Kconfig | 3 +++ 1 file changed, 3 insertions(+)