diff options
author | Jason Chen <b02280@freescale.com> | 2010-01-25 10:38:07 +0800 |
---|---|---|
committer | Jason Chen <b02280@freescale.com> | 2010-01-25 10:38:07 +0800 |
commit | cc4fe714041805997b601fe8e5dd585d8a99297f (patch) | |
tree | 6975a9772f19333b571d65c387af85b2d5dbc7f5 /drivers/media/video/mxc | |
parent | de8fe8bda1cf7af84327e10b2eeaca0eb215e679 (diff) |
ENGR00120370 v4l2 output: fix display fail for blank fb during video playrel_imx_2.6.31_10.02.00
1. Blank BG during video play on FG:
./mxc_v4l2_output.out -iw 320 -ih 240 -ow 1024 -oh 768 -d 3 qvga.yuv
echo 1 > /sys/class/graphics/fb0/blank
echo 0 > /sys/class/graphics/fb0/blank
2. The same input and output (ic_bypass):
./mxc_v4l2_output.out -iw 320 -ih 240 -ow 320 -oh 240 -d 3 qvga.yuv
echo 1 > /sys/class/graphics/fb0/blank
echo 0 > /sys/class/graphics/fb0/blank
Signed-off-by: Jason Chen <b02280@freescale.com>
Diffstat (limited to 'drivers/media/video/mxc')
-rw-r--r-- | drivers/media/video/mxc/output/mxc_v4l2_output.c | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/drivers/media/video/mxc/output/mxc_v4l2_output.c b/drivers/media/video/mxc/output/mxc_v4l2_output.c index 320deeb485d9..521275ce7635 100644 --- a/drivers/media/video/mxc/output/mxc_v4l2_output.c +++ b/drivers/media/video/mxc/output/mxc_v4l2_output.c @@ -273,19 +273,22 @@ static void setup_next_buf_timer(vout_data *vout, int index) "timer handler next schedule: %lu\n", timeout); } -static void wait_for_disp_vsync(vout_data *vout) +static int wait_for_disp_vsync(vout_data *vout) { struct fb_info *fbi = registered_fb[vout->output_fb_num[vout->cur_disp_output]]; mm_segment_t old_fs; + int ret = 0; /* wait for display frame finish */ if (fbi->fbops->fb_ioctl) { old_fs = get_fs(); set_fs(KERNEL_DS); - fbi->fbops->fb_ioctl(fbi, MXCFB_WAIT_FOR_VSYNC, (unsigned int)NULL); + ret = fbi->fbops->fb_ioctl(fbi, MXCFB_WAIT_FOR_VSYNC, + (unsigned int)NULL); set_fs(old_fs); } + return ret; } static void timer_work_func(struct work_struct *work) @@ -323,7 +326,11 @@ static void timer_work_func(struct work_struct *work) return; } - wait_for_disp_vsync(vout); + if (wait_for_disp_vsync(vout) < 0) { + /* ic_bypass need clear display buffer ready for next update*/ + ipu_clear_buffer_ready(vout->display_ch, IPU_INPUT_BUFFER, + !vout->next_done_ipu_buf); + } spin_lock_irqsave(&g_lock, lock_flags); |