mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-09 12:17:12 +09:00
osd: osd ext leaked buf when viu2 displaymode is NULL. [1/1]
PD#TV-7713 Problem: osd buffer leaked dma buffer when switch display pipe. Solution: when viu is NULL, osd need still release correct display file. Verify: verified on macroni Change-Id: Ib2df6b022b6fd654430eedae08e351ae53701fc1 Signed-off-by: sky zhou <sky.zhou@amlogic.com>
This commit is contained in:
@@ -4804,15 +4804,6 @@ static void _osd_pan_display_layers_fence(
|
||||
/* osd_count need -1 when VIU2 enable */
|
||||
struct layer_fence_map_s *layer_map = NULL;
|
||||
|
||||
if (!vinfo || (!strcmp(vinfo->name, "invalid") ||
|
||||
!strcmp(vinfo->name, "null")))
|
||||
/* vout is null, release fence */
|
||||
goto out;
|
||||
|
||||
osd_hw.vinfo_width[output_index] = vinfo->width;
|
||||
osd_hw.vinfo_height[output_index] = vinfo->field_height;
|
||||
memcpy(&osd_hw.disp_info[output_index], &fence_map->disp_info,
|
||||
sizeof(struct display_flip_info_s));
|
||||
if (output_index == VIU1) {
|
||||
osd_count = osd_hw.osd_meson_dev.viu1_osd_count;
|
||||
if (osd_hw.osd_meson_dev.osd_ver <= OSD_NORMAL)
|
||||
@@ -4828,6 +4819,16 @@ static void _osd_pan_display_layers_fence(
|
||||
return;
|
||||
}
|
||||
|
||||
if (!vinfo || (!strcmp(vinfo->name, "invalid") ||
|
||||
!strcmp(vinfo->name, "null")))
|
||||
/* vout is null, release fence & buf file. */
|
||||
goto out;
|
||||
|
||||
osd_hw.vinfo_width[output_index] = vinfo->width;
|
||||
osd_hw.vinfo_height[output_index] = vinfo->field_height;
|
||||
memcpy(&osd_hw.disp_info[output_index], &fence_map->disp_info,
|
||||
sizeof(struct display_flip_info_s));
|
||||
|
||||
if (osd_hw.osd_fps_start[output_index])
|
||||
osd_hw.osd_fps[output_index]++;
|
||||
if (backup_en)
|
||||
|
||||
Reference in New Issue
Block a user