summaryrefslogtreecommitdiff
path: root/drivers/video/sh_mobile_lcdcfb.c
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2012-07-19 02:29:52 +0200
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2012-07-19 12:15:26 +0200
commit8be7c66995bf06769dc4c5f7a62f3cd62a627e7e (patch)
tree04853955f14f76f99cfd44cbec54a967f7d4d266 /drivers/video/sh_mobile_lcdcfb.c
parent15dede882e564601947f2ce4b647742c0351be6d (diff)
fbdev: sh_mobile_lcdc: Fix overlay registers update during pan operation
Updating overlay registers require switching to overlay update mode. This was correctly done when configuring the overlay format and size, but not when updating the base address registers during pan operation. Fix it. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Diffstat (limited to 'drivers/video/sh_mobile_lcdcfb.c')
-rw-r--r--drivers/video/sh_mobile_lcdcfb.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/video/sh_mobile_lcdcfb.c b/drivers/video/sh_mobile_lcdcfb.c
index d82c1dedc467..a5027099fb4c 100644
--- a/drivers/video/sh_mobile_lcdcfb.c
+++ b/drivers/video/sh_mobile_lcdcfb.c
@@ -1539,9 +1539,14 @@ static int sh_mobile_lcdc_overlay_pan(struct fb_var_screeninfo *var,
ovl->base_addr_c = base_addr_c;
}
+ lcdc_write(ovl->channel->lcdc, LDBCR, LDBCR_UPC(ovl->index));
+
lcdc_write_overlay(ovl, LDBnBSAYR(ovl->index), ovl->base_addr_y);
lcdc_write_overlay(ovl, LDBnBSACR(ovl->index), ovl->base_addr_c);
+ lcdc_write(ovl->channel->lcdc, LDBCR,
+ LDBCR_UPF(ovl->index) | LDBCR_UPD(ovl->index));
+
ovl->pan_offset = pan_offset;
return 0;