i2c: digicolor: Fix module autoload
authorJavier Martinez Canillas <javier@osg.samsung.com>
Tue, 18 Oct 2016 21:01:48 +0000 (18:01 -0300)
committerWolfram Sang <wsa@the-dreams.de>
Tue, 25 Oct 2016 09:49:01 +0000 (11:49 +0200)
If the driver is built as a module, autoload won't work because the module
alias information is not filled. So user-space can't match the registered
device with the corresponding module.

Export the module alias information using the MODULE_DEVICE_TABLE() macro.

Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
Acked-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
drivers/i2c/busses/i2c-digicolor.c

index 9604024..49f2084 100644 (file)
@@ -368,6 +368,7 @@ static const struct of_device_id dc_i2c_match[] = {
        { .compatible = "cnxt,cx92755-i2c" },
        { },
 };
+MODULE_DEVICE_TABLE(of, dc_i2c_match);
 
 static struct platform_driver dc_i2c_driver = {
        .probe   = dc_i2c_probe,