misc: bh1780: Add module aliases
authorJean Delvare <jdelvare@suse.de>
Sun, 8 Mar 2015 08:49:50 +0000 (09:49 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 16 Mar 2015 20:10:28 +0000 (21:10 +0100)
The bh1780gli driver does not create an i2c module alias for the
device it supports, preventing the driver from being loaded
automatically when needed on non-OF/DT systems. Add it.

Signed-off-by: Jean Delvare <jdelvare@suse.de>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/misc/bh1780gli.c

index 4c4a59b..7f90ce5 100644 (file)
@@ -230,6 +230,8 @@ static const struct i2c_device_id bh1780_id[] = {
        { },
 };
 
+MODULE_DEVICE_TABLE(i2c, bh1780_id);
+
 #ifdef CONFIG_OF
 static const struct of_device_id of_bh1780_match[] = {
        { .compatible = "rohm,bh1780gli", },