summaryrefslogtreecommitdiff
path: root/drivers/video/mxc/mxc_epdc_fb.c
diff options
context:
space:
mode:
authorJack Lee <jack.lee@freescale.com>2012-10-30 12:32:50 +0800
committerJack Lee <jack.lee@freescale.com>2012-10-30 12:32:50 +0800
commitaaf9d00bf48472e7c21705665beb48169947e6a9 (patch)
tree2283f5ac774264df2b21539d984197dcfa16d763 /drivers/video/mxc/mxc_epdc_fb.c
parent6ece2da0d75746fad5ddf93efd6d323ab3c4414c (diff)
parent94689e1fed43ece131451a90f1716893a418cba0 (diff)
Merge commit 'rel_imx_3.0.35_12.10.02_RC2' into imx_3.0.35_android_r13.5-ga
Conflicts: arch/arm/mach-mx6/pm.c Signed-off-by: Jack Lee <jack.lee@freescale.com>
Diffstat (limited to 'drivers/video/mxc/mxc_epdc_fb.c')
-rw-r--r--drivers/video/mxc/mxc_epdc_fb.c24
1 files changed, 19 insertions, 5 deletions
diff --git a/drivers/video/mxc/mxc_epdc_fb.c b/drivers/video/mxc/mxc_epdc_fb.c
index b702788ae823..2df44041e65c 100644
--- a/drivers/video/mxc/mxc_epdc_fb.c
+++ b/drivers/video/mxc/mxc_epdc_fb.c
@@ -735,18 +735,24 @@ static int epdc_choose_next_lut(int rev, int *next_lut)
{
u64 luts_status, unprocessed_luts;
bool next_lut_found = false;
+ /* Available LUTs are reduced to 16 in 5-bit waveform mode */
+ u32 format_p5n = __raw_readl(EPDC_FORMAT) &
+ EPDC_FORMAT_BUF_PIXEL_FORMAT_P5N;
luts_status = __raw_readl(EPDC_STATUS_LUTS);
- if (rev < 20)
+ if ((rev < 20) || format_p5n)
luts_status &= 0xFFFF;
else
luts_status |= ((u64)__raw_readl(EPDC_STATUS_LUTS2) << 32);
- if (rev < 20)
+ if (rev < 20) {
unprocessed_luts = __raw_readl(EPDC_IRQ) & 0xFFFF;
- else
+ } else {
unprocessed_luts = __raw_readl(EPDC_IRQ1) |
((u64)__raw_readl(EPDC_IRQ2) << 32);
+ if (format_p5n)
+ unprocessed_luts &= 0xFFFF;
+ }
while (!next_lut_found) {
/*
@@ -762,7 +768,7 @@ static int epdc_choose_next_lut(int rev, int *next_lut)
*/
*next_lut = fls64(luts_status);
- if (rev < 20) {
+ if ((rev < 20) || format_p5n) {
if (*next_lut > 15)
*next_lut = ffz(luts_status);
} else {
@@ -1160,6 +1166,8 @@ static void epdc_init_sequence(struct mxc_epdc_fb_data *fb_data)
fb_data->in_init = true;
epdc_powerup(fb_data);
draw_mode0(fb_data);
+ /* Force power down event */
+ fb_data->powering_down = true;
epdc_powerdown(fb_data);
fb_data->updates_active = false;
}
@@ -3694,7 +3702,13 @@ static void epdc_intr_work_func(struct work_struct *work)
next_marker->update_marker);
complete(&next_marker->update_completion);
}
- } else if (epdc_lut_cancelled) {
+ } else if (epdc_lut_cancelled && !epdc_collision) {
+ /*
+ * Note: The update may be cancelled (void) if all
+ * pixels collided. In that case we handle it as a
+ * collision, not a cancel.
+ */
+
/* Clear LUT status (might be set if no AUTOWV used) */
/*