From 6607e59ff941fd03fad4afc3d4d5a36c9737f9ae Mon Sep 17 00:00:00 2001 From: hanwckf Date: Sun, 6 Nov 2022 01:02:04 +0800 Subject: [PATCH] mt798x: reserve memory for pstore --- mt7981_360t7_build.sh | 1 + uboot-mtk-20220606/arch/arm/dts/mt7981.dtsi | 17 +++++++++++++++++ uboot-mtk-20220606/arch/arm/dts/mt7986.dtsi | 17 +++++++++++++++++ 3 files changed, 35 insertions(+) diff --git a/mt7981_360t7_build.sh b/mt7981_360t7_build.sh index b15b291f2..4f8f80f82 100755 --- a/mt7981_360t7_build.sh +++ b/mt7981_360t7_build.sh @@ -19,6 +19,7 @@ echo "build u-boot..." cp -f $UBOOT_DIR/configs/$UBOOT_CFG $UBOOT_DIR/.config if [ "$1" = "fixedparts" ]; then echo "CONFIG_MEDIATEK_UBI_FIXED_MTDPARTS=y" >> $UBOOT_DIR/.config + echo "Build uboot with fixed-mtdparts!" fi make -C $UBOOT_DIR olddefconfig all diff --git a/uboot-mtk-20220606/arch/arm/dts/mt7981.dtsi b/uboot-mtk-20220606/arch/arm/dts/mt7981.dtsi index efe1ed620..9a7e58361 100644 --- a/uboot-mtk-20220606/arch/arm/dts/mt7981.dtsi +++ b/uboot-mtk-20220606/arch/arm/dts/mt7981.dtsi @@ -30,6 +30,23 @@ }; }; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; + + ramoops@42ff0000 { + compatible = "ramoops"; + reg = <0x42ff0000 0x10000>; + record-size = <0x1000>; + }; + + secmon_reserved: secmon@43000000 { + reg = <0x43000000 0x30000>; + no-map; + }; + }; + gpt_clk: gpt_dummy20m { compatible = "fixed-clock"; clock-frequency = <13000000>; diff --git a/uboot-mtk-20220606/arch/arm/dts/mt7986.dtsi b/uboot-mtk-20220606/arch/arm/dts/mt7986.dtsi index 2e87599f0..d04eb16dc 100644 --- a/uboot-mtk-20220606/arch/arm/dts/mt7986.dtsi +++ b/uboot-mtk-20220606/arch/arm/dts/mt7986.dtsi @@ -46,6 +46,23 @@ }; }; + reserved-memory { + #address-cells = <1>; + #size-cells = <1>; + ranges; + + ramoops@42ff0000 { + compatible = "ramoops"; + reg = <0x42ff0000 0x10000>; + record-size = <0x1000>; + }; + + secmon_reserved: secmon@43000000 { + reg = <0x43000000 0x30000>; + no-map; + }; + }; + dummy_clk: dummy12m { compatible = "fixed-clock"; clock-frequency = <12000000>;