iio: Export SPI module alias information in missing drivers
authorJavier Martinez Canillas <javier@osg.samsung.com>
Thu, 20 Aug 2015 07:07:14 +0000 (09:07 +0200)
committerJonathan Cameron <jic23@kernel.org>
Sat, 22 Aug 2015 18:07:09 +0000 (19:07 +0100)
The SPI core always reports the MODALIAS uevent as "spi:<modalias>"
regardless of the mechanism that was used to register the device
(i.e: OF or board code) and the table that is used later to match
the driver with the device (i.e: SPI id table or OF match table).

So drivers needs to export the SPI id table and this be built into
the module or udev won't have the necessary information to autoload
the needed driver module when the device is added.

Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
Acked-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
drivers/iio/amplifiers/ad8366.c
drivers/iio/frequency/adf4350.c

index c0d364e..32b82a2 100644 (file)
@@ -195,6 +195,7 @@ static const struct spi_device_id ad8366_id[] = {
        {"ad8366", 0},
        {}
 };
+MODULE_DEVICE_TABLE(spi, ad8366_id);
 
 static struct spi_driver ad8366_driver = {
        .driver = {
index 9a6ef3c..73f27e0 100644 (file)
@@ -628,6 +628,7 @@ static const struct spi_device_id adf4350_id[] = {
        {"adf4351", 4351},
        {}
 };
+MODULE_DEVICE_TABLE(spi, adf4350_id);
 
 static struct spi_driver adf4350_driver = {
        .driver = {