aboutsummaryrefslogtreecommitdiff
path: root/drivers/hid
diff options
context:
space:
mode:
authorGravatar Krzysztof Kozlowski <krzk@kernel.org> 2024-04-24 08:33:41 +0200
committerGravatar Lee Jones <lee@kernel.org> 2024-05-03 10:45:34 +0100
commitb8beae949433ab03de0ddfc97bc56db956a04662 (patch)
tree7b7632416030e19182fd6586c467617e4f08834e /drivers/hid
parentbacklight: tdo24m: Constify lcd_ops (diff)
downloadlinux-b8beae949433ab03de0ddfc97bc56db956a04662.tar.gz
linux-b8beae949433ab03de0ddfc97bc56db956a04662.tar.bz2
linux-b8beae949433ab03de0ddfc97bc56db956a04662.zip
HID: picoLCD: Constify lcd_ops
'struct lcd_ops' is not modified by core backlight code, so it can be made const for increased code safety. Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org> Reviewed-by: Bruno Prémont <bonbons@linux-vserver.org> Link: https://lore.kernel.org/r/20240424-video-backlight-lcd-ops-v2-15-1aaa82b07bc6@kernel.org Signed-off-by: Lee Jones <lee@kernel.org>
Diffstat (limited to 'drivers/hid')
-rw-r--r--drivers/hid/hid-picolcd_lcd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/hid/hid-picolcd_lcd.c b/drivers/hid/hid-picolcd_lcd.c
index 0c4b76de8ae5..061a33ba7b1d 100644
--- a/drivers/hid/hid-picolcd_lcd.c
+++ b/drivers/hid/hid-picolcd_lcd.c
@@ -46,7 +46,7 @@ static int picolcd_check_lcd_fb(struct lcd_device *ldev, struct fb_info *fb)
return fb && fb == picolcd_fbinfo((struct picolcd_data *)lcd_get_data(ldev));
}
-static struct lcd_ops picolcd_lcdops = {
+static const struct lcd_ops picolcd_lcdops = {
.get_contrast = picolcd_get_contrast,
.set_contrast = picolcd_set_contrast,
.check_fb = picolcd_check_lcd_fb,