Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3478b1cd authored by Laurent Pinchart's avatar Laurent Pinchart Committed by Paul Mundt
Browse files

vt8500lcdfb: use display information in info not in var for panning



We must not use any information in the passed var besides xoffset,
yoffset and vmode as otherwise applications might abuse it.

Signed-off-by: default avatarLaurent Pinchart <laurent.pinchart@ideasonboard.com>
Acked-by: default avatarAlexey Charkov <alchark@gmail.com>
Signed-off-by: default avatarPaul Mundt <lethal@linux-sh.org>
parent 83f0e27c
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -210,7 +210,7 @@ static int vt8500lcd_pan_display(struct fb_var_screeninfo *var,
	struct vt8500lcd_info *fbi = to_vt8500lcd_info(info);

	writel((1 << 31)
		| (((var->xres_virtual - var->xres) * pixlen / 4) << 20)
	     | (((info->var.xres_virtual - info->var.xres) * pixlen / 4) << 20)
	     | (off >> 2), fbi->regbase + 0x20);
	return 0;
}