提交 fdfaa483 编写于 作者: Y York Sun 提交者: Linus Torvalds

freescale DIU: bug fix: add sanity check for AOI position

AOI position cannot be negative.
Signed-off-by: NYork Sun <yorksun@freescale.com>
Cc: Kumar Gala <galak@gate.crashing.org>
Cc: "Antonino A. Daplas" <adaplas@pol.net>
Cc: Krzysztof Helt <krzysztof.h1@poczta.fm>
Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
上级 ae5591e3
...@@ -479,6 +479,10 @@ static void adjust_aoi_size_position(struct fb_var_screeninfo *var, ...@@ -479,6 +479,10 @@ static void adjust_aoi_size_position(struct fb_var_screeninfo *var,
base_plane_width = machine_data->fsl_diu_info[0]->var.xres; base_plane_width = machine_data->fsl_diu_info[0]->var.xres;
base_plane_height = machine_data->fsl_diu_info[0]->var.yres; base_plane_height = machine_data->fsl_diu_info[0]->var.yres;
if (mfbi->x_aoi_d < 0)
mfbi->x_aoi_d = 0;
if (mfbi->y_aoi_d < 0)
mfbi->y_aoi_d = 0;
switch (index) { switch (index) {
case 0: case 0:
if (mfbi->x_aoi_d != 0) if (mfbi->x_aoi_d != 0)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册