From: Daniel Vetter Date: Tue, 28 May 2019 09:03:04 +0000 (+0200) Subject: backlight: simplify lcd notifier X-Git-Tag: v5.4-rc1~645^2~6^2~2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=1dcff4ae65185e8c0300972f6d8d39d9a9db2bda;p=platform%2Fkernel%2Flinux-rpi.git backlight: simplify lcd notifier With all the work I've done on replacing fb notifier calls with direct calls into fbcon the backlight/lcd notifier is the only user left. It will only receive events now that it cares about, hence we can remove this check. Signed-off-by: Daniel Vetter Reviewed-by: Sam Ravnborg Reviewed-by: Maarten Lankhorst Acked-by: Daniel Thompson Cc: Lee Jones Cc: Daniel Thompson Cc: Jingoo Han Link: https://patchwork.freedesktop.org/patch/msgid/20190528090304.9388-34-daniel.vetter@ffwll.ch --- diff --git a/drivers/video/backlight/lcd.c b/drivers/video/backlight/lcd.c index ecdda06..d6b653a 100644 --- a/drivers/video/backlight/lcd.c +++ b/drivers/video/backlight/lcd.c @@ -30,17 +30,6 @@ static int fb_notifier_callback(struct notifier_block *self, struct lcd_device *ld; struct fb_event *evdata = data; - /* If we aren't interested in this event, skip it immediately ... */ - switch (event) { - case FB_EVENT_BLANK: - case FB_EVENT_MODE_CHANGE: - case FB_EARLY_EVENT_BLANK: - case FB_R_EARLY_EVENT_BLANK: - break; - default: - return 0; - } - ld = container_of(self, struct lcd_device, fb_notif); if (!ld->ops) return 0;