summaryrefslogtreecommitdiffstats
path: root/arch/arm/boards
diff options
context:
space:
mode:
authorAhmad Fatoum <a.fatoum@pengutronix.de>2022-02-21 11:36:25 +0100
committerSascha Hauer <s.hauer@pengutronix.de>2022-03-08 09:59:59 +0100
commitc7bb31362687174027660c2d393e7686523be856 (patch)
treea6f4aa936c066bbe5da4d28a81f304ba59dbb496 /arch/arm/boards
parentba35a497d411468fe3b920ad42628fa8b9b479b4 (diff)
downloadbarebox-c7bb31362687174027660c2d393e7686523be856.tar.gz
barebox-c7bb31362687174027660c2d393e7686523be856.tar.xz
ARM: stm32mp: add board support for STM32MP135F-DK
We already have the needed drivers in place to support the upcoming STM32MP131. Linux already has a basic DT for the DK board. Add a barebox board that leverages it. To try it out modify the existing FIP with: fiptool update --nt-fw build/images/barebox-stm32mp-generic-bl33.img \ --hw-config build/arch/arm/dts/stm32mp135f-dk.dtb \ mmcblk0p3 Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220221103625.3728055-2-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch/arm/boards')
-rw-r--r--arch/arm/boards/Makefile1
-rw-r--r--arch/arm/boards/stm32mp13xx-dk/Makefile2
-rw-r--r--arch/arm/boards/stm32mp13xx-dk/lowlevel.c19
3 files changed, 22 insertions, 0 deletions
diff --git a/arch/arm/boards/Makefile b/arch/arm/boards/Makefile
index a15963c775..8557e1dca8 100644
--- a/arch/arm/boards/Makefile
+++ b/arch/arm/boards/Makefile
@@ -139,6 +139,7 @@ obj-$(CONFIG_MACH_SOCFPGA_TERASIC_SOCKIT) += terasic-sockit/
obj-$(CONFIG_MACH_SOLIDRUN_CUBOX) += solidrun-cubox/
obj-$(CONFIG_MACH_SOLIDRUN_MICROSOM) += solidrun-microsom/
obj-$(CONFIG_MACH_STM32MP15XX_DKX) += stm32mp15xx-dkx/
+obj-$(CONFIG_MACH_STM32MP13XX_DK) += stm32mp13xx-dk/
obj-$(CONFIG_MACH_LXA_MC1) += lxa-mc1/
obj-$(CONFIG_MACH_STM32MP15X_EV1) += stm32mp15x-ev1/
obj-$(CONFIG_MACH_TECHNEXION_PICO_HOBBIT) += technexion-pico-hobbit/
diff --git a/arch/arm/boards/stm32mp13xx-dk/Makefile b/arch/arm/boards/stm32mp13xx-dk/Makefile
new file mode 100644
index 0000000000..9961af02a3
--- /dev/null
+++ b/arch/arm/boards/stm32mp13xx-dk/Makefile
@@ -0,0 +1,2 @@
+# SPDX-License-Identifier: GPL-2.0-only
+lwl-y += lowlevel.o
diff --git a/arch/arm/boards/stm32mp13xx-dk/lowlevel.c b/arch/arm/boards/stm32mp13xx-dk/lowlevel.c
new file mode 100644
index 0000000000..ac4fa40e19
--- /dev/null
+++ b/arch/arm/boards/stm32mp13xx-dk/lowlevel.c
@@ -0,0 +1,19 @@
+// SPDX-License-Identifier: GPL-2.0+
+
+#include <mach/entry.h>
+#include <debug_ll.h>
+
+extern char __dtb_z_stm32mp135f_dk_start[];
+
+ENTRY_FUNCTION(start_stm32mp13xx_dk, r0, r1, r2)
+{
+ void *fdt;
+
+ stm32mp_cpu_lowlevel_init();
+
+ putc_ll('>');
+
+ fdt = __dtb_z_stm32mp135f_dk_start + get_runtime_offset();
+
+ stm32mp1_barebox_entry(fdt);
+}