bug in spi and i2c dual buses codecs
Hi Mark/Liam,
I think there is really a bug in spi and i2c dual buses codecs drivers, for example, for any codec with two buses, if you config kernel like this:
SPI MASTER built-in
I2C module
Codec built-in
You will get a link error like this:sound/built-in.o: In function `i2c_add_driver':include/linux/i2c.h:423: undefined reference to i2c_register_driver' sound/built-in.o: In function ad193x_modexit':sound/soc/codecs/ad193x.c:537: undefined reference to `i2c_del_driver'
make: *** [.tmp_vmlinux1] Error 1
I remember that is also one reason why we have splitted this kind of driver into three parts(codec core, i2c bus, spi bus).
In fact, if any bus is compiled as module and code is built-in, link error will be reported.
Thanks
Barry
Quoted 2 lines · Barry Song
In fact, if any bus is compiled as module and code is built-in, link error will be reported.
Yes, this is expected behaviour. It's not been a practical problem - the combination of audio built in and one of the buses modular is far from common.
Quoted 9 lines · Mark Brown
Quoted 2 lines · Barry Song
In fact, if any bus is compiled as module and code is built-in, link error will be reported.
Yes, this is expected behaviour. It's not been a practical problem - the combination of audio built in and one of the buses modular is far from common.
Ok. if so, practically, people should either built-in all, or keep codec driver as module if anyone of i2c and spi is module.
_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
Quoted 7 lines · Mark Brown
Quoted 2 lines · Barry Song
In fact, if any bus is compiled as module and code is built-in, link error will be reported.
Yes, this is expected behaviour. It's not been a practical problem - the combination of audio built in and one of the buses modular is far from common.
knowingly breaking randconfig is viewed as a bad thing by people on lkml -mike
_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
A message that is not in the archive (sent off-list or not yet received): 8bd0f97a1003291125t77aa762eida59cd4a112927ae-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org
Quoted 7 lines · Mike Frysinger
Quoted 3 lines · Mark Brown
Yes, this is expected behaviour. ??It's not been a practical problem - the combination of audio built in and one of the buses modular is far from common.
knowingly breaking randconfig is viewed as a bad thing by people on lkml
Right, the machine drivers need to take care of this when they select the CODEC drivers like SND_SOC_ALL_CODECS does (at least with drivers for the platforms where people care about that, anyway - I'm not going to insist on it for random machines that hardly ever get built).
This isn't exactly something that's been introduced just recently, we've been doing this for some considerable time - well over a year.