From 619c1ff5778b9bc1cd88a63baaaa20d5886fdcf5 Mon Sep 17 00:00:00 2001 From: Andy Ross Date: Wed, 18 Dec 2024 12:59:35 -0800 Subject: [PATCH] soc/mediatek: Don't scan SRAM for winstream in mtk_adsp_load.py For the same reason that this script can't zero the SRAM region (it spontaneously reboots my 8186 device) we can't scan the SRAM for the winstream header. It's never there anyway, it lives in .rodata. This is likely a hardware bug, but as it's an older platform and this is test code it's probably best to just keep it as a workaround. Signed-off-by: Andy Ross --- soc/mediatek/mt8xxx/mtk_adsp_load.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/soc/mediatek/mt8xxx/mtk_adsp_load.py b/soc/mediatek/mt8xxx/mtk_adsp_load.py index aa4b45f4b87..03efcd2f1cc 100755 --- a/soc/mediatek/mt8xxx/mtk_adsp_load.py +++ b/soc/mediatek/mt8xxx/mtk_adsp_load.py @@ -276,7 +276,7 @@ class Winstream: def find_winstream(maps): magic = b'\x74\x5f\x6a\xd0\x79\xe2\x4f\x00\xcd\xb8\xbd\xf9' for m in maps: - if "ram" in m: + if "dram" in m: magoff = maps[m].find(magic) if magoff >= 0: addr = le4(maps[m][magoff + 12 : magoff + 16])