Sfoglia il codice sorgente

rtc: max77802: Report platform modalias to fix module autoload

If the rtc-max77802 driver is built as a module, modalias information is
not filled so the module is not autoloaded. Use the MODULE_DEVICE_TABLE()
macro to export the platform ID table so the module contains that data.

Signed-off-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
Javier Martinez Canillas 10 anni fa
parent
commit
9bde31df56
1 ha cambiato i file con 1 aggiunte e 0 eliminazioni
  1. 1 0
      drivers/rtc/rtc-max77802.c

+ 1 - 0
drivers/rtc/rtc-max77802.c

@@ -484,6 +484,7 @@ static const struct platform_device_id rtc_id[] = {
 	{ "max77802-rtc", 0 },
 	{},
 };
+MODULE_DEVICE_TABLE(platform, rtc_id);
 
 static struct platform_driver max77802_rtc_driver = {
 	.driver		= {