1
0
mirror of https://github.com/libretro/Lakka-LibreELEC.git synced 2024-11-24 10:16:18 +00:00
Lakka-LibreELEC/projects/Amlogic/devices/AMLGX/patches/linux/amlogic-0011-LOCAL-of-partial-revert-of-fdt.c-changes.patch
2023-03-14 11:10:30 +00:00

39 lines
1.3 KiB
Diff

From 012c3d681e1370c701cc666027871817bfc0ec6d Mon Sep 17 00:00:00 2001
From: Stefan Agner <stefan@agner.ch>
Date: Wed, 15 Sep 2021 05:00:45 +0000
Subject: [PATCH 011/120] LOCAL: of: partial revert of fdt.c changes
This resolves reports similar to the below which are present in dmesg
since Linux 5.10; which are also causing crashes in some distros:
[ 0.000000] OF: fdt: Reserved memory: failed to reserve memory for node 'secmon@5000000': base 0x0000000005000000, size 3 MiB
Signed-off-by: Christian Hewitt <christianshewitt@gmail.com>
---
drivers/of/fdt.c | 9 ---------
1 file changed, 9 deletions(-)
diff --git a/drivers/of/fdt.c b/drivers/of/fdt.c
index d1a68b6d03b3..81508e8b34d2 100644
--- a/drivers/of/fdt.c
+++ b/drivers/of/fdt.c
@@ -480,15 +480,6 @@ static int __init early_init_dt_reserve_memory(phys_addr_t base,
phys_addr_t size, bool nomap)
{
if (nomap) {
- /*
- * If the memory is already reserved (by another region), we
- * should not allow it to be marked nomap, but don't worry
- * if the region isn't memory as it won't be mapped.
- */
- if (memblock_overlaps_region(&memblock.memory, base, size) &&
- memblock_is_region_reserved(base, size))
- return -EBUSY;
-
return memblock_mark_nomap(base, size);
}
return memblock_reserve(base, size);
--
2.34.1