Skip to contentSkip to conversation

powerpc/mpc8xxx: SECURE BOOT- Disable law 0 for non PBL platforms

PATCH New Aneesh Bansal 2 participants 2 messages Mar 11, 2014 – Apr 23, 2014 PowerPC

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 powerpc/mpc8xxx: SECURE BOOT- Disable law 0 for non PBL platforms

ISBC creates a LAW 0 entry for non PBL platforms, which is not disabled before transferring the control to uboot. The LAW 0 entry has to be disabled.

---
 arch/powerpc/cpu/mpc8xxx/law.c | 10 ++++++++++
 1 file changed, 10 insertions(+)

Changes from v1:
The LAW was being disabled in start.S in v1. As per discussion, it is moved out of start.S and done when U-boot initializes other LAW's.

arch/powerpc/cpu/mpc8xxx/law.c +10 -0
index a401083..55ee125 100644
@@ -233,6 +233,16 @@ void init_laws(void)
 #error FSL_HW_NUM_LAWS can not be greater than 32 w/o code changes
 #endif
 
+#if defined(CONFIG_SECURE_BOOT) && defined(CONFIG_E500) && \
+						!defined(CONFIG_E500MC)
+	/* ISBC (Boot ROM) creates a LAW 0 entry for non PBL platforms,
+	 * which is not disabled before transferring the control to uboot.
+	 * Disable the LAW 0 entry here.
+	 */
+	disable_law(0);
+#endif
+
+
 	/*
 	 * Any LAWs that were set up before we booted assume they are meant to
 	 * be around and mark them used.
Signature · 1 line
1.8.1.4
#1 lore raw

PATCH v2 1/1 powerpc/mpc8xxx: SECURE BOOT- Disable law 0 for non PBL platforms

Quoted 6 lines · Aneesh Bansal

ISBC creates a LAW 0 entry for non PBL platforms, which is not disabled before transferring the control to uboot. The LAW 0 entry has to be disabled.

---

Applied to u-boot-mpc85xx/master, thanks.

York