2015-04-16 00:21:38

by Arun Bharadwaj

[permalink] [raw]
Subject: [PATCH] gpio-backlight: Discover driver during boot time

The gpio-backlight driver seems to be missing the
MODULE_DEVICE_TABLE line which is preventing it from
being modprobed during boot time even if the
gpio-backlight device exists.

This seems to be a bug and this patch attempts to
fix that.

Signed-off-by: Arun Bharadwaj <[email protected]>
Signed-off-by: Ash Charles <[email protected]>
---
drivers/video/backlight/gpio_backlight.c | 2 ++
1 file changed, 2 insertions(+)

diff --git a/drivers/video/backlight/gpio_backlight.c b/drivers/video/backlight/gpio_backlight.c
index 439feb2..5fbbc2e 100644
--- a/drivers/video/backlight/gpio_backlight.c
+++ b/drivers/video/backlight/gpio_backlight.c
@@ -146,6 +146,8 @@ static struct of_device_id gpio_backlight_of_match[] = {
{ .compatible = "gpio-backlight" },
{ /* sentinel */ }
};
+
+MODULE_DEVICE_TABLE(of, gpio_backlight_of_match);
#endif

static struct platform_driver gpio_backlight_driver = {
--
1.9.1


2015-04-29 12:32:33

by Lee Jones

[permalink] [raw]
Subject: Re: [PATCH] gpio-backlight: Discover driver during boot time

Jingoo?

> The gpio-backlight driver seems to be missing the
> MODULE_DEVICE_TABLE line which is preventing it from
> being modprobed during boot time even if the
> gpio-backlight device exists.
>
> This seems to be a bug and this patch attempts to
> fix that.
>
> Signed-off-by: Arun Bharadwaj <[email protected]>
> Signed-off-by: Ash Charles <[email protected]>
> ---
> drivers/video/backlight/gpio_backlight.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/drivers/video/backlight/gpio_backlight.c b/drivers/video/backlight/gpio_backlight.c
> index 439feb2..5fbbc2e 100644
> --- a/drivers/video/backlight/gpio_backlight.c
> +++ b/drivers/video/backlight/gpio_backlight.c
> @@ -146,6 +146,8 @@ static struct of_device_id gpio_backlight_of_match[] = {
> { .compatible = "gpio-backlight" },
> { /* sentinel */ }
> };
> +
> +MODULE_DEVICE_TABLE(of, gpio_backlight_of_match);
> #endif
>
> static struct platform_driver gpio_backlight_driver = {

--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog

2015-04-29 12:33:10

by Lee Jones

[permalink] [raw]
Subject: Re: [PATCH] gpio-backlight: Discover driver during boot time

> Jingoo?

Never mind.

Applied, thanks.

> > The gpio-backlight driver seems to be missing the
> > MODULE_DEVICE_TABLE line which is preventing it from
> > being modprobed during boot time even if the
> > gpio-backlight device exists.
> >
> > This seems to be a bug and this patch attempts to
> > fix that.
> >
> > Signed-off-by: Arun Bharadwaj <[email protected]>
> > Signed-off-by: Ash Charles <[email protected]>
> > ---
> > drivers/video/backlight/gpio_backlight.c | 2 ++
> > 1 file changed, 2 insertions(+)
> >
> > diff --git a/drivers/video/backlight/gpio_backlight.c b/drivers/video/backlight/gpio_backlight.c
> > index 439feb2..5fbbc2e 100644
> > --- a/drivers/video/backlight/gpio_backlight.c
> > +++ b/drivers/video/backlight/gpio_backlight.c
> > @@ -146,6 +146,8 @@ static struct of_device_id gpio_backlight_of_match[] = {
> > { .compatible = "gpio-backlight" },
> > { /* sentinel */ }
> > };
> > +
> > +MODULE_DEVICE_TABLE(of, gpio_backlight_of_match);
> > #endif
> >
> > static struct platform_driver gpio_backlight_driver = {
>

--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog