diff options
author | Jason Chen <b02280@freescale.com> | 2011-11-21 10:11:42 +0800 |
---|---|---|
committer | Eric Miao <eric.miao@linaro.org> | 2011-11-29 16:43:16 +0800 |
commit | fab73e9de75aaf8020127fba972a8e4c48a77c67 (patch) | |
tree | a3b0240772d055f875457ab1592f754403780f8c | |
parent | 3fccb81b3ccf44b809d116156a00d8a6704b87b8 (diff) |
ENGR00162663 ipuv3 fb: add vertical flip support
support vertical flip for fb.
just set it by:
echo 1 > /sys/class/graphics/fb0/rotate
Signed-off-by: Jason Chen <b02280@freescale.com>
-rw-r--r-- | drivers/video/mxc/mxc_ipuv3_fb.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/video/mxc/mxc_ipuv3_fb.c b/drivers/video/mxc/mxc_ipuv3_fb.c index 26725818bc1..f2861bcd563 100644 --- a/drivers/video/mxc/mxc_ipuv3_fb.c +++ b/drivers/video/mxc/mxc_ipuv3_fb.c @@ -241,7 +241,7 @@ static int _setup_disp_channel2(struct fb_info *fbi) bpp_to_pixfmt(fbi), fbi->var.xres, fbi->var.yres, fb_stride, - IPU_ROTATE_NONE, + fbi->var.rotate, base, base, fbi->var.accel_flags & @@ -259,7 +259,7 @@ static int _setup_disp_channel2(struct fb_info *fbi) IPU_PIX_FMT_GENERIC, fbi->var.xres, fbi->var.yres, fbi->var.xres, - IPU_ROTATE_NONE, + fbi->var.rotate, mxc_fbi->alpha_phy_addr1, mxc_fbi->alpha_phy_addr0, 0, @@ -574,6 +574,9 @@ static int mxcfb_check_var(struct fb_var_screeninfo *var, struct fb_info *info) var->yres = bg_yres - pos_y; } + if (var->rotate > IPU_ROTATE_VERT_FLIP) + var->rotate = IPU_ROTATE_NONE; + if (var->xres_virtual < var->xres) var->xres_virtual = var->xres; |