All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] powerpc: fix regression in arch_initr_trap()
@ 2021-05-17 17:32 Matt Merhar
  2021-05-18  5:50 ` Stefan Roese
  2021-05-27 11:42 ` [PATCH] powerpc: fix regression in arch_initr_trap() Tom Rini
  0 siblings, 2 replies; 22+ messages in thread
From: Matt Merhar @ 2021-05-17 17:32 UTC (permalink / raw)
  To: u-boot

The assembly output of the arch_initr_trap() function differed by a
single byte after common.h was removed from traps.c:

 fff49a18 <arch_initr_trap>:
 fff49a18:      94 21 ff f0     stwu    r1,-16(r1)
 fff49a1c:      7c 08 02 a6     mflr    r0
 fff49a20:      90 01 00 14     stw     r0,20(r1)
-fff49a24:      80 62 00 44     lwz     r3,68(r2)
+fff49a24:      80 62 00 38     lwz     r3,56(r2)
 fff49a28:      4b ff 76 19     bl      fff41040 <trap_init>
 fff49a2c:      80 01 00 14     lwz     r0,20(r1)
 fff49a30:      38 60 00 00     li      r3,0
 fff49a34:      38 21 00 10     addi    r1,r1,16
 fff49a38:      7c 08 03 a6     mtlr    r0

This was causing a consistent hard lockup during the MMC read / loading
of the QoriQ FMan firmware on a P2041RDB board.

Re-adding the header causes identical assembly to be emitted and allows
the firmware loading and subsequent boot to succeed.

Fixes: 401d1c4f5d ("common: Drop asm/global_data.h from common header")
Signed-off-by: Matt Merhar <mattmerhar@protonmail.com>
---

 arch/powerpc/lib/traps.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/powerpc/lib/traps.c b/arch/powerpc/lib/traps.c
index c7bce82a44..ab8ca269a5 100644
--- a/arch/powerpc/lib/traps.c
+++ b/arch/powerpc/lib/traps.c
@@ -4,6 +4,7 @@
  * Wolfgang Denk, DENX Software Engineering, wd at denx.de.
  */
 
+#include <common.h>
 #include <init.h>
 #include <asm/global_data.h>
 
-- 
2.25.1

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

end of thread, other threads:[~2021-07-01 21:55 UTC | newest]

Thread overview: 22+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-17 17:32 [PATCH] powerpc: fix regression in arch_initr_trap() Matt Merhar
2021-05-18  5:50 ` Stefan Roese
2021-05-18  7:04   ` Rasmus Villemoes
2021-05-18  9:19     ` [RFC PATCH 0/2] sizeof(gd_t) sanity checking Rasmus Villemoes
2021-05-18  9:19       ` [RFC PATCH 1/2] build_bug.h: add wrapper for _Static_assert Rasmus Villemoes
2021-05-19 15:34         ` Simon Glass
2021-07-01 21:54         ` Tom Rini
2021-05-18  9:19       ` [RFC PATCH 2/2] global-data.h: add build-time sanity check of sizeof(struct global_data) Rasmus Villemoes
2021-05-19 15:34         ` Simon Glass
2021-07-01 21:54         ` Tom Rini
2021-06-03 13:38       ` [PATCH 1/4] powerpc: Don't use relative include for config.h in global_data.h Tom Rini
2021-06-03 13:39         ` [PATCH 2/4] Revert "powerpc: fix regression in arch_initr_trap()" Tom Rini
2021-06-24 13:15           ` Tom Rini
2021-06-03 13:39         ` [PATCH 3/4] socfpga64: Do not define CONFIG_SYS_MEM_RESERVE_SECURE to 0 Tom Rini
2021-06-03 15:07           ` Rasmus Villemoes
2021-06-03 15:14             ` Tom Rini
2021-06-24 13:15           ` Tom Rini
2021-06-03 13:39         ` [PATCH 4/4] global_data: Ensure we have <config.h> when symbols are not in Kconfig yet Tom Rini
2021-06-24 13:15           ` Tom Rini
2021-06-05 19:18         ` [PATCH 1/4] powerpc: Don't use relative include for config.h in global_data.h Matt Merhar
2021-06-24 13:15         ` Tom Rini
2021-05-27 11:42 ` [PATCH] powerpc: fix regression in arch_initr_trap() Tom Rini

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.