odroid_go: Move flash partition table to a separate file

Move flash partition table to a separate file

Signed-off-by: Yannis Damigos <giannis.damigos@gmail.com>
This commit is contained in:
Yannis Damigos 2024-09-02 15:14:29 +03:00 committed by Fabio Baltieri
commit 9637071114
3 changed files with 41 additions and 80 deletions

View file

@ -0,0 +1,39 @@
/*
* Copyright (c) 2024 Yannis Damigos
*
* SPDX-License-Identifier: Apache-2.0
*/
&flash0 {
status = "okay";
partitions {
compatible = "fixed-partitions";
#address-cells = <1>;
#size-cells = <1>;
/* Reserve 60kB for the bootloader */
boot_partition: partition@1000 {
label = "mcuboot";
reg = <0x00001000 0x0000F000>;
read-only;
};
/* Reserve 2048kB for the application in slot 0 */
slot0_partition: partition@10000 {
label = "image-0";
reg = <0x00010000 0x00200000>;
};
/* Reserve 2048kB for the application in slot 1 */
slot1_partition: partition@210000 {
label = "image-1";
reg = <0x00210000 0x00200000>;
};
/* Reserve the remaining 12224kB for the storage partition */
storage_partition: partition@410000 {
label = "storage";
reg = <0x00410000 0x00BF0000>;
};
};
};

View file

@ -6,6 +6,7 @@
/dts-v1/; /dts-v1/;
#include <espressif/esp32/esp32_appcpu.dtsi> #include <espressif/esp32/esp32_appcpu.dtsi>
#include "odroid_go-flash_partition_table.dtsi"
/ { / {
model = "ODROID-GO Game Kit APPCPU"; model = "ODROID-GO Game Kit APPCPU";
@ -25,43 +26,3 @@
&trng0 { &trng0 {
status = "okay"; status = "okay";
}; };
&flash0 {
status = "okay";
partitions {
compatible = "fixed-partitions";
#address-cells = <1>;
#size-cells = <1>;
/* Reserve 60kB for the bootloader */
boot_partition: partition@1000 {
label = "mcuboot";
reg = <0x00001000 0x0000F000>;
read-only;
};
/* Reserve 2048kB for the application in slot 0 */
slot0_partition: partition@10000 {
label = "image-0";
reg = <0x00010000 0x00200000>;
};
/* Reserve 2048kB for the application in slot 1 */
slot1_partition: partition@210000 {
label = "image-1";
reg = <0x00210000 0x00200000>;
};
/* Reserve 64kB for the scratch partition */
scratch_partition: partition@410000 {
label = "image-scratch";
reg = <0x00410000 0x00010000>;
};
/* Reserve the remaining 12160kB for the storage partition */
storage_partition: partition@420000 {
label = "storage";
reg = <0x00420000 0x00BE0000>;
};
};
};

View file

@ -7,6 +7,7 @@
#include <espressif/esp32/esp32_wrover_e_n16r4.dtsi> #include <espressif/esp32/esp32_wrover_e_n16r4.dtsi>
#include "odroid_go-pinctrl.dtsi" #include "odroid_go-pinctrl.dtsi"
#include "odroid_go-flash_partition_table.dtsi"
#include <zephyr/dt-bindings/input/input-event-codes.h> #include <zephyr/dt-bindings/input/input-event-codes.h>
/ { / {
@ -169,46 +170,6 @@
status = "okay"; status = "okay";
}; };
&flash0 {
status = "okay";
partitions {
compatible = "fixed-partitions";
#address-cells = <1>;
#size-cells = <1>;
/* Reserve 60kB for the bootloader */
boot_partition: partition@1000 {
label = "mcuboot";
reg = <0x00001000 0x0000F000>;
read-only;
};
/* Reserve 2048kB for the application in slot 0 */
slot0_partition: partition@10000 {
label = "image-0";
reg = <0x00010000 0x00200000>;
};
/* Reserve 2048kB for the application in slot 1 */
slot1_partition: partition@210000 {
label = "image-1";
reg = <0x00210000 0x00200000>;
};
/* Reserve 64kB for the scratch partition */
scratch_partition: partition@410000 {
label = "image-scratch";
reg = <0x00410000 0x00010000>;
};
/* Reserve the remaining 12160kB for the storage partition */
storage_partition: partition@420000 {
label = "storage";
reg = <0x00420000 0x00BE0000>;
};
};
};
&esp32_bt_hci { &esp32_bt_hci {
status = "okay"; status = "okay";
}; };