diff options
author | Jason Chen <b02280@freescale.com> | 2010-01-25 10:38:07 +0800 |
---|---|---|
committer | Alejandro Gonzalez <alex.gonzalez@digi.com> | 2010-05-24 11:50:04 +0200 |
commit | 7d44eab45fe7273d06a4d24d9673e4ffd875e399 (patch) | |
tree | 11472acb2b7b8e42b3881520fb932852a72232e0 /drivers/media | |
parent | 27cfd0b5b1c622d97cac18262bf315a8d094f0f9 (diff) |
ENGR00120370 v4l2 output: fix display fail for blank fb during video play
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>
Signed-off-by: Alejandro Gonzalez <alex.gonzalez@digi.com>
Diffstat (limited to 'drivers/media')
-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); |