osd: mali afbcd memory out of bound [1/1]

PD#TV-6683

Problem:
DMC error log as "ID:VPU READ1, sub: 7"

Solution:
make afbc disable, if afbc phy addr is 0

Verify:
verified on TL1-X301

Change-Id: I111c8e2e922877904dd8b8d1f276f79ca4f68e94
Signed-off-by: Jian Cao <jian.cao@amlogic.com>
This commit is contained in:
Jian Cao
2019-06-06 19:19:50 +08:00
committed by Chris KIM
parent ab989433a4
commit 50cbabf2a5

View File

@@ -5440,13 +5440,16 @@ static void osd_update_enable(u32 index)
if ((osd_hw.osd_afbcd[index].enable == ENABLE)
&& (osd_hw.enable[index] == ENABLE)
&& !osd_hw.dim_layer[index]) {
/* enable mali afbc */
VSYNCOSD_WR_MPEG_REG(
VPU_MAFBC_IRQ_MASK, 0xf);
VSYNCOSD_WR_MPEG_REG_BITS(
VPU_MAFBC_SURFACE_CFG,
1, index, 1);
osd_hw.osd_afbcd[index].afbc_start = 1;
if (!osd_hw.osd_afbcd[index].afbc_start &&
osd_hw.osd_afbcd[index].phy_addr != 0) {
/* enable mali afbc */
VSYNCOSD_WR_MPEG_REG(
VPU_MAFBC_IRQ_MASK, 0xf);
VSYNCOSD_WR_MPEG_REG_BITS(
VPU_MAFBC_SURFACE_CFG,
1, index, 1);
osd_hw.osd_afbcd[index].afbc_start = 1;
}
} else {
/* disable mali afbc */
VSYNCOSD_WR_MPEG_REG_BITS(