All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/7] common: spl: move armv7m-specific code to spl_perform_fixups()
@ 2021-10-30  6:51 Ovidiu Panait
  2021-10-30  6:51 ` [PATCH 2/7] common: board_r: move bedbug_init() to common code Ovidiu Panait
                   ` (5 more replies)
  0 siblings, 6 replies; 9+ messages in thread
From: Ovidiu Panait @ 2021-10-30  6:51 UTC (permalink / raw)
  To: u-boot
  Cc: Ovidiu Panait, Alexandru Gagniuc, Bin Meng, Harald Seiler,
	Pali Rohár, Patrick Delaunay, Ricardo Salveti, Simon Glass

Factor out armv7m fragment to spl_perform_fixups(), which is an arch/board
specific function designed for this purpose.

Signed-off-by: Ovidiu Panait <ovidiu.panait@windriver.com>
---

 arch/arm/cpu/armv7m/cpu.c | 6 ++++++
 common/spl/spl.c          | 3 ---
 2 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/arch/arm/cpu/armv7m/cpu.c b/arch/arm/cpu/armv7m/cpu.c
index 63721018c1..65427b5312 100644
--- a/arch/arm/cpu/armv7m/cpu.c
+++ b/arch/arm/cpu/armv7m/cpu.c
@@ -12,6 +12,7 @@
 #include <irq_func.h>
 #include <asm/io.h>
 #include <asm/armv7m.h>
+#include <spl.h>
 
 /*
  * This is called right before passing control to
@@ -56,3 +57,8 @@ void reset_cpu(void)
 		| (V7M_SCB->aircr & V7M_AIRCR_PRIGROUP_MSK)
 		| V7M_AIRCR_SYSRESET, &V7M_SCB->aircr);
 }
+
+void spl_perform_fixups(struct spl_image_info *spl_image)
+{
+	spl_image->entry_point |= 0x1;
+}
diff --git a/common/spl/spl.c b/common/spl/spl.c
index 0c08da06e8..63556f35bd 100644
--- a/common/spl/spl.c
+++ b/common/spl/spl.c
@@ -770,9 +770,6 @@ void board_init_r(gd_t *dummy1, ulong dummy2)
 			       ret);
 	}
 
-#ifdef CONFIG_CPU_V7M
-	spl_image.entry_point |= 0x1;
-#endif
 	switch (spl_image.os) {
 	case IH_OS_U_BOOT:
 		debug("Jumping to %s...\n", spl_phase_name(spl_next_phase()));
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2021-11-05  2:05 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-30  6:51 [PATCH 1/7] common: spl: move armv7m-specific code to spl_perform_fixups() Ovidiu Panait
2021-10-30  6:51 ` [PATCH 2/7] common: board_r: move bedbug_init() to common code Ovidiu Panait
2021-10-30  6:51 ` [PATCH 3/7] common: board_r: drop initr_kgdb wrapper Ovidiu Panait
2021-10-30  6:51 ` [PATCH 4/7] common: board_r: drop initr_addr_map wrapper Ovidiu Panait
2021-11-03 12:15   ` Matthias Brugger
2021-11-05  2:02   ` Simon Glass
2021-10-30  6:51 ` [PATCH 5/7] common: board_r: move init_addr_map() to init.h Ovidiu Panait
2021-10-30  6:51 ` [PATCH 6/7] common: board_r: include asm-generic/gpio.h Ovidiu Panait
2021-10-30  6:51 ` [PATCH 7/7] common: board_r: drop ifdefs around header includes Ovidiu Panait

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.