video: backlight: pwm_bl.c: make of_device_id structure to const

Message ID 20170705155406.GA22144@lynnl.yet
State New
Headers show

Commit Message

Lynn Lei July 5, 2017, 3:55 p.m.
Fixed a of_device_id structure normally be const warning issue which
checked by scripts/checkpatch.pl:
  WARNING: struct of_device_id should normally be const

Signed-off-by: Lynn Lei <lynnl.wit@gmail.com>
---
 drivers/video/backlight/pwm_bl.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Thierry Reding July 6, 2017, 9:33 a.m. | #1
On Wed, Jul 05, 2017 at 11:55:09PM +0800, Lynn Lei wrote:
> Fixed a of_device_id structure normally be const warning issue which
> checked by scripts/checkpatch.pl:
>   WARNING: struct of_device_id should normally be const
> 
> Signed-off-by: Lynn Lei <lynnl.wit@gmail.com>
> ---
>  drivers/video/backlight/pwm_bl.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Acked-by: Thierry Reding <treding@nvidia.com>

Patch

diff --git a/drivers/video/backlight/pwm_bl.c b/drivers/video/backlight/pwm_bl.c
index 002f1ce22bd0..9bd17682655a 100644
--- a/drivers/video/backlight/pwm_bl.c
+++ b/drivers/video/backlight/pwm_bl.c
@@ -178,7 +178,7 @@  static int pwm_backlight_parse_dt(struct device *dev,
 	return 0;
 }
 
-static struct of_device_id pwm_backlight_of_match[] = {
+static const struct of_device_id pwm_backlight_of_match[] = {
 	{ .compatible = "pwm-backlight" },
 	{ }
 };