Messages in this thread | | | Date | Wed, 8 May 2013 22:40:26 +0800 | Subject | Re: [PATCH RFC] iio: dac: Fix build error when CONFIG_SPI_MASTER=y && CONFIG_I2C=m | From | Axel Lin <> |
| |
2013/5/8 Lars-Peter Clausen <lars@metafoo.de>: > On 05/08/2013 10:36 AM, Axel Lin wrote: >> This patch fixes below build error when CONFIG_SPI_MASTER=y && CONFIG_I2C=m: >> >> drivers/built-in.o: In function `ad5064_i2c_write': >> drivers/iio/dac/ad5064.c:608: undefined reference to `i2c_master_send' >> drivers/built-in.o: In function `ad5064_i2c_register_driver': >> drivers/iio/dac/ad5064.c:646: undefined reference to `i2c_register_driver' >> drivers/built-in.o: In function `ad5064_i2c_unregister_driver': >> drivers/iio/dac/ad5064.c:651: undefined reference to `i2c_del_driver' >> make: *** [vmlinux] Error 1 >> >> Add config IIO_DAC_I2C_AND_SPI helper to handle such case: >> When CONFIG_I2C=m, meaning we can't build the drivers in with I2C support. >> Thus don't allow the drivers to be compiled as built-in. >> > > My plan was to do something like "depends on (SPI_MASTER && I2C!=m) || I2C", This change seems simpler than this path. Thus I'm going to send v2 for it.
Thanks, Axel
| |