Skip to content

Commit 0d530c9

Browse files
Pengcheng Chenakiernan
authored andcommitted
osd: osd display error when work in 1080i and cvbs
PD#151305: osd: osd display error when work in 1080i and cvbs Change-Id: I75dbc06ceddf724210f3a2a858bc10685c829fcf Signed-off-by: Pengcheng Chen <pengcheng.chen@amlogic.com>
1 parent 954031d commit 0d530c9

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

drivers/amlogic/media/osd/osd_hw.c

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1084,7 +1084,7 @@ int osd_set_scan_mode(u32 index)
10841084
}
10851085
if (osd_hw.free_scale_enable[index])
10861086
osd_hw.scan_mode[index] = SCAN_MODE_PROGRESSIVE;
1087-
if (osd_hw.osd_afbcd[OSD1].enable)
1087+
if (osd_hw.osd_afbcd[index].enable)
10881088
osd_hw.scan_mode[index] = SCAN_MODE_PROGRESSIVE;
10891089
if (index == OSD2) {
10901090
if (osd_hw.scan_mode[OSD2] == SCAN_MODE_INTERLACE)
@@ -1745,7 +1745,11 @@ void osd_get_flush_rate_hw(u32 *break_rate)
17451745

17461746
void osd_set_antiflicker_hw(u32 index, struct vinfo_s *vinfo, u32 yres)
17471747
{
1748-
if (is_interlaced(vinfo)) {
1748+
bool osd_need_antiflicker = false;
1749+
1750+
if (is_interlaced(vinfo))
1751+
osd_need_antiflicker = false;
1752+
if (osd_need_antiflicker) {
17491753
osd_hw.antiflicker_mode = 1;
17501754
osd_antiflicker_task_start();
17511755
osd_antiflicker_enable(1);
@@ -3749,7 +3753,8 @@ static void osd2_update_disp_geometry(void)
37493753
data32 = (osd_hw.dispdata[OSD2].x_start & 0xfff)
37503754
| (osd_hw.dispdata[OSD2].x_end & 0xfff) << 16;
37513755
VSYNCOSD_WR_MPEG_REG(VIU_OSD2_BLK0_CFG_W3, data32);
3752-
if (osd_hw.scan_mode[OSD2] == SCAN_MODE_INTERLACE)
3756+
if ((osd_hw.scan_mode[OSD2] == SCAN_MODE_INTERLACE) &&
3757+
osd_hw.dispdata[OSD2].y_start > 0)
37533758
data32 = (osd_hw.dispdata[OSD2].y_start & 0xfff)
37543759
| ((((osd_hw.dispdata[OSD2].y_end + 1
37553760
- osd_hw.dispdata[OSD2].y_start) >> 1)

0 commit comments

Comments
 (0)