diff options
| author | David Lechner <[email protected]> | 2026-03-19 15:00:09 -0500 |
|---|---|---|
| committer | David Lechner <[email protected]> | 2026-04-06 18:39:10 -0500 |
| commit | 34fb6b7ba772f97bac798b7cf0dc468274d91bbd (patch) | |
| tree | 33bfddab752b44b7c4a54d5f030d5dd5e036e43a /arch | |
| parent | b3467e51e92b37d3f4c07c599864a06fb7cd90f9 (diff) | |
arm: mediatek: mt8188: check return value of fdtdec_setup_mem_size_base()
Check and propagate the return value of fdtdec_setup_mem_size_base() in
dram_init() for mt8188. This function could fail if the device tree is
malformed.
Reviewed-by: Julien Stephan <[email protected]>
Tested-by: Julien Stephan <[email protected]>
Link: https://patch.msgid.link/[email protected]
Signed-off-by: David Lechner <[email protected]>
Diffstat (limited to 'arch')
| -rw-r--r-- | arch/arm/mach-mediatek/mt8188/init.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/arm/mach-mediatek/mt8188/init.c b/arch/arm/mach-mediatek/mt8188/init.c index 61676e8437a..8f0db7455ed 100644 --- a/arch/arm/mach-mediatek/mt8188/init.c +++ b/arch/arm/mach-mediatek/mt8188/init.c @@ -22,7 +22,9 @@ int dram_init(void) if (ret) return ret; - fdtdec_setup_mem_size_base(); + ret = fdtdec_setup_mem_size_base(); + if (ret) + return ret; /* * Limit gd->ram_top not exceeding SZ_4G. Some periphals like mmc |
