Skip to contentSkip to conversation

*** Add fixed-paritions to phyCORE-AM62x and phyCORE-AM64x ***

PATCH In review Nathan Morrisson 2 participants 6 messages Dec 15, 2023 – Dec 18, 2023

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

cover *** Add fixed-paritions to phyCORE-AM62x and phyCORE-AM64x ***

Add a fixed-partitions node to the NOR flash of the phyCORE-AM62x and phyCORE-AM64x to enable the bootloader to fixup the partitions during boot.

Nathan Morrisson (2):
arm64: dts: ti: k3-am62-phycore-som: Add fixed-partitions to NOR Flash
arm64: dts: ti: k3-am64-phycore-som: Add fixed-partitions to NOR Flash

 arch/arm64/boot/dts/ti/k3-am62-phycore-som.dtsi | 6 ++++++
 arch/arm64/boot/dts/ti/k3-am64-phycore-som.dtsi | 6 ++++++
 2 files changed, 12 insertions(+)
Signature · 1 line
2.25.1
#1 lore raw

PATCH 1/2 arm64: dts: ti: k3-am62-phycore-som: Add fixed-partitions to NOR Flash

Provide a fixed-partitions dummy node so bootladers can fixup paritions.

---
 arch/arm64/boot/dts/ti/k3-am62-phycore-som.dtsi | 6 ++++++
 1 file changed, 6 insertions(+)
arch/arm64/boot/dts/ti/k3-am62-phycore-som.dtsi +6 -0
index aa43e7407eee..681ac03cef40 100644
@@ -311,6 +311,12 @@ serial_flash: flash@0 {
 		cdns,tchsh-ns = <60>;
 		cdns,tslch-ns = <60>;
 		cdns,read-delay = <0>;
+
+		partitions {
+			compatible = "fixed-partitions";
+			#address-cells = <1>;
+			#size-cells = <1>;
+		};
 	};
 };
 
Signature · 1 line
2.25.1
#2 lore raw

PATCH 2/2 arm64: dts: ti: k3-am64-phycore-som: Add fixed-partitions to NOR Flash

In reply to Nathan Morrisson

Provide a fixed-partitions dummy node so bootladers can fixup paritions.

---
 arch/arm64/boot/dts/ti/k3-am64-phycore-som.dtsi | 6 ++++++
 1 file changed, 6 insertions(+)
arch/arm64/boot/dts/ti/k3-am64-phycore-som.dtsi +6 -0
index f87f09d83c95..a25ff4cf9373 100644
@@ -207,6 +207,12 @@ flash@0 {
 		cdns,tchsh-ns = <60>;
 		cdns,tslch-ns = <60>;
 		cdns,read-delay = <0>;
+
+		partitions{
+			compatible = "fixed-partitions";
+			#address-cells = <1>;
+			#size-cells = <1>;
+		};
 	};
 };
 
Signature · 1 line
2.25.1
#3 lore raw
In reply to Nathan Morrisson
Quoted 4 lines · Nathan Morrisson

Add a fixed-partitions node to the NOR flash of the phyCORE-AM62x and phyCORE-AM64x to enable the bootloader to fixup the partitions during boot.

Why can't your bootloader add these nodes?

Andrew

Quoted 8 lines

Nathan Morrisson (2):
arm64: dts: ti: k3-am62-phycore-som: Add fixed-partitions to NOR Flash
arm64: dts: ti: k3-am64-phycore-som: Add fixed-partitions to NOR Flash

  arch/arm64/boot/dts/ti/k3-am62-phycore-som.dtsi | 6 ++++++
  arch/arm64/boot/dts/ti/k3-am64-phycore-som.dtsi | 6 ++++++
  2 files changed, 12 insertions(+)
#4 lore raw

Hi Andrew,

We are adding the nodes directly to the device tree to match what is done in other device trees, for example: k3-am642-tqma64xxl.dtsi. You are correct that this could be done by the bootloader instead though. Why do you prefer having the bootloader add the nodes?

Regards,

Nathan

Quoted 18 lines · Andrew Davis
Quoted 4 lines · Nathan Morrisson

Add a fixed-partitions node to the NOR flash of the phyCORE-AM62x and phyCORE-AM64x to enable the bootloader to fixup the partitions during boot.

Why can't your bootloader add these nodes?

Andrew

Quoted 8 lines

Nathan Morrisson (2):
   arm64: dts: ti: k3-am62-phycore-som: Add fixed-partitions to NOR Flash
   arm64: dts: ti: k3-am64-phycore-som: Add fixed-partitions to NOR Flash

  arch/arm64/boot/dts/ti/k3-am62-phycore-som.dtsi | 6 ++++++ arch/arm64/boot/dts/ti/k3-am64-phycore-som.dtsi | 6 ++++++

  2 files changed, 12 insertions(+)
#5 lore raw
Quoted 4 lines · Nathan Morrisson

Hi Andrew,

We are adding the nodes directly to the device tree to match what is done in other device trees, for example: k3-am642-tqma64xxl.dtsi. You are correct that this could be done by the bootloader instead though. Why do you prefer having the bootloader add the nodes?

k3-am642-tqma64xxl.dtsi should be fixed, it slipped past me and shouldn't be used as a reference.

The bootloader might not fill it out at all, what if we start using the new MTD GPT partitions? Then the new bootloaders will have to start *removing* these stale half-nodes.

If the bootloader is going to add fixed partitions it should do the whole job. There is no good reason to have a half complete nodes here.

Andrew

Quoted 23 lines

Regards,

Nathan

Quoted 18 lines · Andrew Davis
Quoted 4 lines · Nathan Morrisson

Add a fixed-partitions node to the NOR flash of the phyCORE-AM62x and phyCORE-AM64x to enable the bootloader to fixup the partitions during boot.

Why can't your bootloader add these nodes?

Andrew

Quoted 8 lines

Nathan Morrisson (2):
   arm64: dts: ti: k3-am62-phycore-som: Add fixed-partitions to NOR Flash
   arm64: dts: ti: k3-am64-phycore-som: Add fixed-partitions to NOR Flash

  arch/arm64/boot/dts/ti/k3-am62-phycore-som.dtsi | 6 ++++++ arch/arm64/boot/dts/ti/k3-am64-phycore-som.dtsi | 6 ++++++

  2 files changed, 12 insertions(+)