]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
MLK-10248 video: ipuv3-fb: fix hang up with cmdline option for CLAA WVGA
authorRobby Cai <r63905@freescale.com>
Sun, 15 Feb 2015 06:00:14 +0000 (14:00 +0800)
committerRobby Cai <r63905@freescale.com>
Sun, 15 Feb 2015 08:04:28 +0000 (16:04 +0800)
commit6b4144acdbc63f0161cdc30e9c8d23d738e0ff12
tree887c3343ef0c1bee37d7d99e43db398775d41510
parenta95e6f53b8c4e24b34352555bda69d311358ecaa
MLK-10248 video: ipuv3-fb: fix hang up with cmdline option for CLAA WVGA

The kernel boot stops at "Starting kernel ..." if assign cmdline
"video=mxcfb0:dev=lcd,if=RGB565".

The cause is that there's no 'mode_str' property for mxcfb0 in DTS file,
so of_property_read_string() does not touch it and 'mode_str' could be used
uninitialized in mxcfb_get_of_property(), where it's assigned to
plat_data->mode_str and then used uninitialized in fb_find_mode().
This may cause buffer overflow. This patch initializes 'mode_str' to NULL
to fix it.

Signed-off-by: Robby Cai <r63905@freescale.com>
(cherry picked from commit 115d11804b7b56d058ee6be8496b13f57869be93)
drivers/video/mxc/mxc_ipuv3_fb.c