linux/drivers/video
Yizhuo Zhai 68e8cc2a23 fbdev: fbmem: Fix the implicit type casting
In function do_fb_ioctl(), the "arg" is the type of unsigned long,
and in "case FBIOBLANK:" this argument is casted into an int before
passig to fb_blank(). In fb_blank(), the comparision
if (blank > FB_BLANK_POWERDOWN) would be bypass if the original
"arg" is a large number, which is possible because it comes from
the user input. Fix this by adding the check before the function
call.

Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Reviewed-by: Sam Ravnborg <sam@ravnborg.org>
Acked-by: Helge Deller <deller@gmx.de>
Signed-off-by: Yizhuo Zhai <yzhai003@ucr.edu>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: https://patchwork.freedesktop.org/patch/msgid/20220202235811.1621017-1-yzhai003@ucr.edu
2022-02-03 13:52:03 +01:00
..
backlight backlight: qcom-wled: Respect enabled-strings in set_brightness 2021-12-22 11:18:46 +00:00
console fbcon: Add option to enable legacy hardware acceleration 2022-02-02 15:16:26 +01:00
fbdev fbdev: fbmem: Fix the implicit type casting 2022-02-03 13:52:03 +01:00
logo .gitignore: add SPDX License Identifier 2020-03-25 11:50:48 +01:00
display_timing.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 428 2019-06-05 17:37:16 +02:00
hdmi.c video: fix some kernel-doc markups 2020-11-16 18:23:16 +01:00
Kconfig
Makefile
of_display_timing.c video: Fix kernel-doc warnings in of_display_timing + of_videomode 2020-11-29 22:42:17 +01:00
of_videomode.c video: Fix kernel-doc warnings in of_display_timing + of_videomode 2020-11-29 22:42:17 +01:00
vgastate.c
videomode.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 428 2019-06-05 17:37:16 +02:00