提交 472b854b 编写于 作者: P Paolo Pisati 提交者: Bryan Wu

leds-gpio: of: introduce MODULE_DEVICE_TABLE for module autoloading

Enable autoloading of leds-gpio module when a corresponing DT entry is present.
Signed-off-by: NPaolo Pisati <paolo.pisati@canonical.com>
Signed-off-by: NBryan Wu <cooloney@gmail.com>
上级 aad0f292
...@@ -226,6 +226,8 @@ static const struct of_device_id of_gpio_leds_match[] = { ...@@ -226,6 +226,8 @@ static const struct of_device_id of_gpio_leds_match[] = {
{ .compatible = "gpio-leds", }, { .compatible = "gpio-leds", },
{}, {},
}; };
MODULE_DEVICE_TABLE(of, of_gpio_leds_match);
#else /* CONFIG_OF_GPIO */ #else /* CONFIG_OF_GPIO */
static struct gpio_leds_priv *gpio_leds_create_of(struct platform_device *pdev) static struct gpio_leds_priv *gpio_leds_create_of(struct platform_device *pdev)
{ {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册