Skip to contentSkip to conversation

powerpc/85xx: enable some P1/P2 boards mtdparts for nor flash

PATCH New Yangbo Lu 2 participants 2 messages Oct 16, 2014 – Nov 14, 2014

lore
Share & tools
lore

Yangbo Lu

author
#0 lore raw

PATCH v4 1/1 powerpc/85xx: enable some P1/P2 boards mtdparts for nor flash

Enable these boards mtdparts for nor flash:
p1020rdb-pd, p1021rdb-pc, p1022ds, p1025twr, and p2020rdb-pc.

---
Changes for v2:
- changed commit message
- fixed max line length problem in code
Changes for v3:
- added a Cc to York Sun
Changes for v4
- added 36-bit physical address support

---
 include/configs/P1022DS.h      | 19 ++++++++++++++++++
 include/configs/p1_p2_rdb_pc.h | 44 ++++++++++++++++++++++++++++++++++++++++++
 include/configs/p1_twr.h       | 12 ++++++++++++
 3 files changed, 75 insertions(+)
include/configs/P1022DS.h +19 -0
index 139d4fe..5828ecf 100644
@@ -620,6 +620,25 @@
 #endif
 
 /*
+ * Dynamic MTD Partition support with mtdparts
+ */
+#define CONFIG_MTD_DEVICE
+#define CONFIG_MTD_PARTITIONS
+#define CONFIG_CMD_MTDPARTS
+#define CONFIG_FLASH_CFI_MTD
+#ifdef CONFIG_PHYS_64BIT
+#define MTDIDS_DEFAULT "nor0=fe8000000.nor"
+#define MTDPARTS_DEFAULT "mtdparts=fe8000000.nor:48m(ramdisk)," \
+			"14m(diagnostic),2m(dink),6m(kernel),58112k(fs)," \
+			"512k(dtb),768k(u-boot)"
+#else
+#define MTDIDS_DEFAULT "nor0=e8000000.nor"
+#define MTDPARTS_DEFAULT "mtdparts=e8000000.nor:48m(ramdisk)," \
+			"14m(diagnostic),2m(dink),6m(kernel),58112k(fs)," \
+			"512k(dtb),768k(u-boot)"
+#endif
+
+/*
  * Environment
  */
 #ifdef CONFIG_SPIFLASH
include/configs/p1_p2_rdb_pc.h +44 -0

62 lines not on this page · raw message

include/configs/p1_twr.h +12 -0
index c296a07..d3093f5 100644
@@ -389,6 +389,18 @@ extern unsigned long get_board_sys_clk(unsigned long dummy);
 #endif /* CONFIG_TWR-P1025 */
 
 /*
+ * Dynamic MTD Partition support with mtdparts
+ */
+#define CONFIG_MTD_DEVICE
+#define CONFIG_MTD_PARTITIONS
+#define CONFIG_CMD_MTDPARTS
+#define CONFIG_FLASH_CFI_MTD
+#define MTDIDS_DEFAULT "nor0=ec000000.nor"
+#define MTDPARTS_DEFAULT "mtdparts=ec000000.nor:256k(vsc7385-firmware)," \
+			"256k(dtb),5632k(kernel),57856k(fs)," \
+			"256k(qe-ucode-firmware),1280k(u-boot)"
+
+/*
  * Environment
  */
 #ifdef CONFIG_SYS_RAMBOOT
Signature · 1 line
2.1.0.27.g96db324
#1 lore raw

PATCH v4 1/1 powerpc/85xx: enable some P1/P2 boards mtdparts for nor flash

Quoted 7 lines · Yangbo Lu

Enable these boards mtdparts for nor flash:
p1020rdb-pd, p1021rdb-pc, p1022ds, p1025twr, and p2020rdb-pc.

Quoted 9 lines

---
Changes for v2:
- changed commit message
- fixed max line length problem in code
Changes for v3:
- added a Cc to York Sun
Changes for v4
- added 36-bit physical address support
---

Applied to u-boot-mpc85xx master. Thanks.

York