Add patches for initial support for the Beagle Bone Black
This commit is contained in:
parent
1b14295881
commit
4e669294f7
@ -0,0 +1,27 @@
|
||||
From d4b58fe48083ee98dd86af5b0ec9e831433c98e3 Mon Sep 17 00:00:00 2001
|
||||
From: Koen Kooi <koen@dominion.thruhere.net>
|
||||
Date: Wed, 3 Apr 2013 08:22:53 +0200
|
||||
Subject: [PATCH 01/14] beaglebone: default to beaglebone black for unknown
|
||||
EEPROMs
|
||||
|
||||
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
|
||||
---
|
||||
include/configs/am335x_evm.h | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h
|
||||
index ef00306..2ac89af 100644
|
||||
--- a/include/configs/am335x_evm.h
|
||||
+++ b/include/configs/am335x_evm.h
|
||||
@@ -59,7 +59,7 @@
|
||||
"rdaddr=0x81000000\0" \
|
||||
"bootdir=/boot\0" \
|
||||
"bootfile=uImage\0" \
|
||||
- "fdtfile=\0" \
|
||||
+ "fdtfile=am335x-boneblack.dtb\0" \
|
||||
"console=ttyO0,115200n8\0" \
|
||||
"optargs=\0" \
|
||||
"mtdids=" MTDIDS_DEFAULT "\0" \
|
||||
--
|
||||
1.8.1.4
|
||||
|
@ -0,0 +1,32 @@
|
||||
From fbce545279c4f1e882431fa7d08130e1bc25cd93 Mon Sep 17 00:00:00 2001
|
||||
From: Koen Kooi <koen@dominion.thruhere.net>
|
||||
Date: Wed, 3 Apr 2013 08:32:19 +0200
|
||||
Subject: [PATCH 02/14] am335x mux: don't hang on unknown EEPROMs, assume
|
||||
BeagleBone Black
|
||||
|
||||
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
|
||||
---
|
||||
board/ti/am335x/mux.c | 8 ++++++--
|
||||
1 file changed, 6 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/board/ti/am335x/mux.c b/board/ti/am335x/mux.c
|
||||
index 0283708..ab42011 100644
|
||||
--- a/board/ti/am335x/mux.c
|
||||
+++ b/board/ti/am335x/mux.c
|
||||
@@ -305,7 +305,11 @@ void enable_board_pin_mux(struct am335x_baseboard_id *header)
|
||||
configure_module_pin_mux(mmc0_pin_mux);
|
||||
configure_module_pin_mux(mmc1_pin_mux);
|
||||
} else {
|
||||
- puts("Unknown board, cannot configure pinmux.");
|
||||
- hang();
|
||||
+ puts("Unknown board, assuming Beaglebone LT/Black.");
|
||||
+ /* Beaglebone LT pinmux */
|
||||
+ configure_module_pin_mux(i2c1_pin_mux);
|
||||
+ configure_module_pin_mux(mii1_pin_mux);
|
||||
+ configure_module_pin_mux(mmc0_pin_mux);
|
||||
+ configure_module_pin_mux(mmc1_pin_mux);
|
||||
}
|
||||
}
|
||||
--
|
||||
1.8.1.4
|
||||
|
38
0003-beaglebone-HACK-always-return-1-for-is_bone_lt.patch
Normal file
38
0003-beaglebone-HACK-always-return-1-for-is_bone_lt.patch
Normal file
@ -0,0 +1,38 @@
|
||||
From d73f1f024a8f179e38ce15dc66938ee40325e5b3 Mon Sep 17 00:00:00 2001
|
||||
From: Koen Kooi <koen@dominion.thruhere.net>
|
||||
Date: Wed, 3 Apr 2013 08:33:28 +0200
|
||||
Subject: [PATCH 03/14] beaglebone: HACK: always return 1 for is_bone_lt
|
||||
|
||||
This is to make the eMMC flasher work, the EEPROM hasn't been populated yet
|
||||
|
||||
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
|
||||
---
|
||||
board/ti/am335x/board.c | 5 +++--
|
||||
1 file changed, 3 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/board/ti/am335x/board.c b/board/ti/am335x/board.c
|
||||
index b371376..c92e1e9 100644
|
||||
--- a/board/ti/am335x/board.c
|
||||
+++ b/board/ti/am335x/board.c
|
||||
@@ -60,7 +60,8 @@ static inline int board_is_bone(void)
|
||||
|
||||
static inline int board_is_bone_lt(void)
|
||||
{
|
||||
- return !strncmp(header.name, "A335BNLT", HDR_NAME_LEN);
|
||||
+ //return !strncmp(header.name, "A335BNLT", HDR_NAME_LEN);
|
||||
+ return 1;
|
||||
}
|
||||
|
||||
static inline int board_is_evm_sk(void)
|
||||
@@ -378,7 +379,7 @@ void s_init(void)
|
||||
if (board_is_evm_sk())
|
||||
config_ddr(303, MT41J128MJT125_IOCTRL_VALUE, &ddr3_data,
|
||||
&ddr3_cmd_ctrl_data, &ddr3_emif_reg_data, 0);
|
||||
- else if (board_is_bone_lt())
|
||||
+ else if (board_is_bone_lt() && !board_is_bone())
|
||||
config_ddr(400, MT41K256M16HA125E_IOCTRL_VALUE,
|
||||
&ddr3_beagleblack_data,
|
||||
&ddr3_beagleblack_cmd_ctrl_data,
|
||||
--
|
||||
1.8.1.4
|
||||
|
25
0004-beaglebone-HACK-raise-USB-current-limit.patch
Normal file
25
0004-beaglebone-HACK-raise-USB-current-limit.patch
Normal file
@ -0,0 +1,25 @@
|
||||
From 713fb639c8d4920ae7581908de8da9fbbe83f3ae Mon Sep 17 00:00:00 2001
|
||||
From: Koen Kooi <koen@dominion.thruhere.net>
|
||||
Date: Wed, 3 Apr 2013 08:27:09 +0200
|
||||
Subject: [PATCH 04/14] beaglebone: HACK: raise USB current limit
|
||||
|
||||
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
|
||||
---
|
||||
include/configs/am335x_evm.h | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h
|
||||
index 2ac89af..8de4cc9 100644
|
||||
--- a/include/configs/am335x_evm.h
|
||||
+++ b/include/configs/am335x_evm.h
|
||||
@@ -149,6 +149,7 @@
|
||||
#endif
|
||||
|
||||
#define CONFIG_BOOTCOMMAND \
|
||||
+ "i2c mw 0x24 1 0x3e; " \
|
||||
"run findfdt; " \
|
||||
"mmc dev ${mmcdev}; if mmc rescan; then " \
|
||||
"echo SD/MMC found on device ${mmcdev};" \
|
||||
--
|
||||
1.8.1.4
|
||||
|
@ -0,0 +1,40 @@
|
||||
From a8861624e48f2ecf0f39da3827211c485ed2f0cb Mon Sep 17 00:00:00 2001
|
||||
From: Koen Kooi <koen@dominion.thruhere.net>
|
||||
Date: Wed, 3 Apr 2013 08:25:04 +0200
|
||||
Subject: [PATCH 05/14] beaglebone: use kloadaddr to avoid copying the kernel
|
||||
around
|
||||
|
||||
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
|
||||
---
|
||||
include/configs/am335x_evm.h | 5 +++--
|
||||
1 file changed, 3 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h
|
||||
index 8de4cc9..14b0a08 100644
|
||||
--- a/include/configs/am335x_evm.h
|
||||
+++ b/include/configs/am335x_evm.h
|
||||
@@ -54,6 +54,7 @@
|
||||
#ifndef CONFIG_SPL_BUILD
|
||||
#define CONFIG_EXTRA_ENV_SETTINGS \
|
||||
"loadaddr=0x80200000\0" \
|
||||
+ "kloadaddr=0x80007fc0\0" \
|
||||
"fdtaddr=0x80F80000\0" \
|
||||
"fdt_high=0xffffffff\0" \
|
||||
"rdaddr=0x81000000\0" \
|
||||
@@ -112,11 +113,11 @@
|
||||
"root=${ramroot} " \
|
||||
"rootfstype=${ramrootfstype}\0" \
|
||||
"loadramdisk=load mmc ${mmcdev} ${rdaddr} ramdisk.gz\0" \
|
||||
- "loaduimage=load mmc ${bootpart} ${loadaddr} ${bootdir}/${bootfile}\0" \
|
||||
+ "loaduimage=load mmc ${bootpart} ${kloadaddr} ${bootdir}/${bootfile}\0" \
|
||||
"loadfdt=load mmc ${bootpart} ${fdtaddr} ${bootdir}/${fdtfile}\0" \
|
||||
"mmcboot=echo Booting from mmc ...; " \
|
||||
"run mmcargs; " \
|
||||
- "bootm ${loadaddr} - ${fdtaddr}\0" \
|
||||
+ "bootm ${kloadaddr} - ${fdtaddr}\0" \
|
||||
"nandboot=echo Booting from nand ...; " \
|
||||
"run nandargs; " \
|
||||
"nand read ${loadaddr} ${nandsrcaddr} ${nandimgsize}; " \
|
||||
--
|
||||
1.8.1.4
|
||||
|
@ -0,0 +1,44 @@
|
||||
From 987104bc6bf3c2ddbf023b524c486ffdf583f001 Mon Sep 17 00:00:00 2001
|
||||
From: Koen Kooi <koen@dominion.thruhere.net>
|
||||
Date: Wed, 3 Apr 2013 08:44:03 +0200
|
||||
Subject: [PATCH 06/14] beaglebone: try to load uEnv/uImage from eMMC first
|
||||
|
||||
If u-boot detects the eMMC, try to load from there, if that fails fall back to uSD. Due to linux "features" rootdev can remain mmcblk0p1.
|
||||
|
||||
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
|
||||
---
|
||||
include/configs/am335x_evm.h | 18 ++++++++++++++++++
|
||||
1 file changed, 18 insertions(+)
|
||||
|
||||
diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h
|
||||
index 14b0a08..a21fe8e 100644
|
||||
--- a/include/configs/am335x_evm.h
|
||||
+++ b/include/configs/am335x_evm.h
|
||||
@@ -152,6 +152,24 @@
|
||||
#define CONFIG_BOOTCOMMAND \
|
||||
"i2c mw 0x24 1 0x3e; " \
|
||||
"run findfdt; " \
|
||||
+ "mmc dev 1; if mmc rescan; then " \
|
||||
+ "echo SD/MMC found on device ${mmcdev};" \
|
||||
+ "setenv mmcdev 1;"\
|
||||
+ "if run loadbootenv; then " \
|
||||
+ "echo Loaded environment from ${bootenv};" \
|
||||
+ "run importbootenv;" \
|
||||
+ "fi;" \
|
||||
+ "if test -n $uenvcmd; then " \
|
||||
+ "echo Running uenvcmd ...;" \
|
||||
+ "run uenvcmd;" \
|
||||
+ "fi;" \
|
||||
+ "if run loaduimage; then " \
|
||||
+ "run loadfdt;" \
|
||||
+ "run mmcboot;" \
|
||||
+ "fi;" \
|
||||
+ "else " \
|
||||
+ "echo No SD/MMC found on device ${mmcdev};" \
|
||||
+ "fi;" \
|
||||
"mmc dev ${mmcdev}; if mmc rescan; then " \
|
||||
"echo SD/MMC found on device ${mmcdev};" \
|
||||
"if run loadbootenv; then " \
|
||||
--
|
||||
1.8.1.4
|
||||
|
@ -0,0 +1,53 @@
|
||||
From 2bb3b2b5b50dc70af4ef6686642350cbd5ec870a Mon Sep 17 00:00:00 2001
|
||||
From: Koen Kooi <koen@dominion.thruhere.net>
|
||||
Date: Wed, 3 Apr 2013 11:39:16 +0200
|
||||
Subject: [PATCH 07/14] beaglebone: Don't trigger uboot variable lenght limit
|
||||
|
||||
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
|
||||
---
|
||||
include/configs/am335x_evm.h | 20 +++-----------------
|
||||
1 file changed, 3 insertions(+), 17 deletions(-)
|
||||
|
||||
diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h
|
||||
index a21fe8e..9051249 100644
|
||||
--- a/include/configs/am335x_evm.h
|
||||
+++ b/include/configs/am335x_evm.h
|
||||
@@ -152,23 +152,11 @@
|
||||
#define CONFIG_BOOTCOMMAND \
|
||||
"i2c mw 0x24 1 0x3e; " \
|
||||
"run findfdt; " \
|
||||
- "mmc dev 1; if mmc rescan; then " \
|
||||
- "echo SD/MMC found on device ${mmcdev};" \
|
||||
+ "if mmc dev 1; then " \
|
||||
+ "echo eMMC found;" \
|
||||
"setenv mmcdev 1;"\
|
||||
- "if run loadbootenv; then " \
|
||||
- "echo Loaded environment from ${bootenv};" \
|
||||
- "run importbootenv;" \
|
||||
- "fi;" \
|
||||
- "if test -n $uenvcmd; then " \
|
||||
- "echo Running uenvcmd ...;" \
|
||||
- "run uenvcmd;" \
|
||||
- "fi;" \
|
||||
- "if run loaduimage; then " \
|
||||
- "run loadfdt;" \
|
||||
- "run mmcboot;" \
|
||||
- "fi;" \
|
||||
"else " \
|
||||
- "echo No SD/MMC found on device ${mmcdev};" \
|
||||
+ "echo No eMMC found;" \
|
||||
"fi;" \
|
||||
"mmc dev ${mmcdev}; if mmc rescan; then " \
|
||||
"echo SD/MMC found on device ${mmcdev};" \
|
||||
@@ -184,8 +172,6 @@
|
||||
"run loadfdt;" \
|
||||
"run mmcboot;" \
|
||||
"fi;" \
|
||||
- "else " \
|
||||
- "run nandboot;" \
|
||||
"fi;" \
|
||||
|
||||
/* Clock Defines */
|
||||
--
|
||||
1.8.1.4
|
||||
|
@ -0,0 +1,35 @@
|
||||
From 8ef64f73b14e5e5657b740ecae8cf62db1511138 Mon Sep 17 00:00:00 2001
|
||||
From: Koen Kooi <koen@dominion.thruhere.net>
|
||||
Date: Wed, 3 Apr 2013 11:47:14 +0200
|
||||
Subject: [PATCH 08/14] beaglebone: HACK: change mmc order to avoid u-boot
|
||||
crashing
|
||||
|
||||
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
|
||||
---
|
||||
include/configs/am335x_evm.h | 9 +++++----
|
||||
1 file changed, 5 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h
|
||||
index 9051249..8dc3a8a 100644
|
||||
--- a/include/configs/am335x_evm.h
|
||||
+++ b/include/configs/am335x_evm.h
|
||||
@@ -152,11 +152,12 @@
|
||||
#define CONFIG_BOOTCOMMAND \
|
||||
"i2c mw 0x24 1 0x3e; " \
|
||||
"run findfdt; " \
|
||||
- "if mmc dev 1; then " \
|
||||
- "echo eMMC found;" \
|
||||
- "setenv mmcdev 1;"\
|
||||
+ "mmc dev 0; if mmc rescan ; then " \
|
||||
+ "echo micro SD card found;" \
|
||||
+ "setenv mmcdev 0;"\
|
||||
"else " \
|
||||
- "echo No eMMC found;" \
|
||||
+ "echo No micro SD card found, setting mmcdev to 1;" \
|
||||
+ "setenv mmcdev 1;"\
|
||||
"fi;" \
|
||||
"mmc dev ${mmcdev}; if mmc rescan; then " \
|
||||
"echo SD/MMC found on device ${mmcdev};" \
|
||||
--
|
||||
1.8.1.4
|
||||
|
@ -0,0 +1,25 @@
|
||||
From 59af9f65dd21d9a4e0c78478c5c0bd83e7d2da7e Mon Sep 17 00:00:00 2001
|
||||
From: Koen Kooi <koen@dominion.thruhere.net>
|
||||
Date: Wed, 3 Apr 2013 12:04:17 +0200
|
||||
Subject: [PATCH 09/14] beaglebone: update bootpart variable after mmc scan
|
||||
|
||||
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
|
||||
---
|
||||
include/configs/am335x_evm.h | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h
|
||||
index 8dc3a8a..489f882 100644
|
||||
--- a/include/configs/am335x_evm.h
|
||||
+++ b/include/configs/am335x_evm.h
|
||||
@@ -159,6 +159,7 @@
|
||||
"echo No micro SD card found, setting mmcdev to 1;" \
|
||||
"setenv mmcdev 1;"\
|
||||
"fi;" \
|
||||
+ "setenv bootpart ${mmcdev}:2;" \
|
||||
"mmc dev ${mmcdev}; if mmc rescan; then " \
|
||||
"echo SD/MMC found on device ${mmcdev};" \
|
||||
"if run loadbootenv; then " \
|
||||
--
|
||||
1.8.1.4
|
||||
|
25
0010-am335x_evm-enable-gpio-command.patch
Normal file
25
0010-am335x_evm-enable-gpio-command.patch
Normal file
@ -0,0 +1,25 @@
|
||||
From 88c09ce2919919d1943a85e9f9475d17b347702e Mon Sep 17 00:00:00 2001
|
||||
From: Jason Kridner <jdk@ti.com>
|
||||
Date: Thu, 4 Apr 2013 05:57:00 +0000
|
||||
Subject: [PATCH 10/14] am335x_evm: enable gpio command
|
||||
|
||||
---
|
||||
include/configs/am335x_evm.h | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h
|
||||
index 489f882..f2838ac 100644
|
||||
--- a/include/configs/am335x_evm.h
|
||||
+++ b/include/configs/am335x_evm.h
|
||||
@@ -43,7 +43,7 @@
|
||||
|
||||
/* commands to include */
|
||||
#include <config_cmd_default.h>
|
||||
-
|
||||
+#define CONFIG_CMD_GPIO
|
||||
#define CONFIG_CMD_ASKENV
|
||||
#define CONFIG_VERSION_VARIABLE
|
||||
|
||||
--
|
||||
1.8.1.4
|
||||
|
43
0011-am335x_evm-HACK-to-turn-on-BeagleBone-LEDs.patch
Normal file
43
0011-am335x_evm-HACK-to-turn-on-BeagleBone-LEDs.patch
Normal file
@ -0,0 +1,43 @@
|
||||
From bcfde7885d6adbf067db5dd54cd4d9cea7426870 Mon Sep 17 00:00:00 2001
|
||||
From: Jason Kridner <jdk@ti.com>
|
||||
Date: Thu, 4 Apr 2013 07:16:41 +0000
|
||||
Subject: [PATCH 11/14] am335x_evm: HACK to turn on BeagleBone LEDs
|
||||
|
||||
* This might break non-BeagleBone platforms
|
||||
---
|
||||
include/configs/am335x_evm.h | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h
|
||||
index f2838ac..9e39d00 100644
|
||||
--- a/include/configs/am335x_evm.h
|
||||
+++ b/include/configs/am335x_evm.h
|
||||
@@ -150,6 +150,7 @@
|
||||
#endif
|
||||
|
||||
#define CONFIG_BOOTCOMMAND \
|
||||
+ "gpio set 53; " \
|
||||
"i2c mw 0x24 1 0x3e; " \
|
||||
"run findfdt; " \
|
||||
"mmc dev 0; if mmc rescan ; then " \
|
||||
@@ -161,6 +162,7 @@
|
||||
"fi;" \
|
||||
"setenv bootpart ${mmcdev}:2;" \
|
||||
"mmc dev ${mmcdev}; if mmc rescan; then " \
|
||||
+ "gpio set 54; " \
|
||||
"echo SD/MMC found on device ${mmcdev};" \
|
||||
"if run loadbootenv; then " \
|
||||
"echo Loaded environment from ${bootenv};" \
|
||||
@@ -170,7 +172,9 @@
|
||||
"echo Running uenvcmd ...;" \
|
||||
"run uenvcmd;" \
|
||||
"fi;" \
|
||||
+ "gpio set 55; " \
|
||||
"if run loaduimage; then " \
|
||||
+ "gpio set 56; " \
|
||||
"run loadfdt;" \
|
||||
"run mmcboot;" \
|
||||
"fi;" \
|
||||
--
|
||||
1.8.1.4
|
||||
|
@ -0,0 +1,44 @@
|
||||
From 1e04086fc3b0d00222904472af56a14fba9bcd28 Mon Sep 17 00:00:00 2001
|
||||
From: Darren Etheridge <detheridge@ti.com>
|
||||
Date: Tue, 9 Apr 2013 16:49:38 -0500
|
||||
Subject: [PATCH 12/14] Fix for screen rolling when video played back in
|
||||
browser on BeagleBone Black This value might need some tweaking, but it
|
||||
effectively allows the LCDC and the ARM to play fairer in memory, so the LCDC
|
||||
does not get starved causing the screen to roll See Page 439 in spruh73g
|
||||
(AM33xx TRM) for details
|
||||
|
||||
---
|
||||
arch/arm/cpu/armv7/am33xx/ddr.c | 10 ++++++++++
|
||||
1 file changed, 10 insertions(+)
|
||||
|
||||
diff --git a/arch/arm/cpu/armv7/am33xx/ddr.c b/arch/arm/cpu/armv7/am33xx/ddr.c
|
||||
index d1e2fd3..3a93db1 100644
|
||||
--- a/arch/arm/cpu/armv7/am33xx/ddr.c
|
||||
+++ b/arch/arm/cpu/armv7/am33xx/ddr.c
|
||||
@@ -21,6 +21,12 @@ http://www.ti.com/
|
||||
#include <asm/io.h>
|
||||
#include <asm/emif.h>
|
||||
|
||||
+/* This value might need some tweaking, but it effectively allows the LCDC */
|
||||
+/* and the ARM to play fairer in memory, so the LCDC does not get starved causing */
|
||||
+/* the screen to roll */
|
||||
+/* See Page 439 in spruh73g (AM33xx TRM) for details */
|
||||
+#define AM33XX_INT_CONFIG_COUNT 0x00303030
|
||||
+
|
||||
/**
|
||||
* Base address for EMIF instances
|
||||
*/
|
||||
@@ -79,6 +85,10 @@ void set_sdram_timings(const struct emif_regs *regs, int nr)
|
||||
writel(regs->sdram_tim2, &emif_reg[nr]->emif_sdram_tim_2_shdw);
|
||||
writel(regs->sdram_tim3, &emif_reg[nr]->emif_sdram_tim_3);
|
||||
writel(regs->sdram_tim3, &emif_reg[nr]->emif_sdram_tim_3_shdw);
|
||||
+
|
||||
+ /* Configure INT_CONFIG value so that LCDC does not get stalled */
|
||||
+ /* for a long time if ARM is accessing memory */
|
||||
+ writel(AM33XX_INT_CONFIG_COUNT, &emif_reg[nr]->emif_l3_config);
|
||||
}
|
||||
|
||||
/**
|
||||
--
|
||||
1.8.1.4
|
||||
|
@ -0,0 +1,25 @@
|
||||
From 1886ba872060e54cb4b5732ffa24fcc3eb6172e8 Mon Sep 17 00:00:00 2001
|
||||
From: Robert Nelson <robertcnelson@gmail.com>
|
||||
Date: Thu, 25 Apr 2013 13:50:35 -0500
|
||||
Subject: [PATCH 13/14] beaglebone: enable CONFIG_SUPPORT_RAW_INITRD option
|
||||
|
||||
Signed-off-by: Robert Nelson <robertcnelson@gmail.com>
|
||||
---
|
||||
include/configs/am335x_evm.h | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h
|
||||
index 9e39d00..04eaa8b 100644
|
||||
--- a/include/configs/am335x_evm.h
|
||||
+++ b/include/configs/am335x_evm.h
|
||||
@@ -35,6 +35,7 @@
|
||||
|
||||
#define CONFIG_OF_LIBFDT
|
||||
#define CONFIG_CMD_BOOTZ
|
||||
+#define CONFIG_SUPPORT_RAW_INITRD
|
||||
#define CONFIG_CMDLINE_TAG /* enable passing of ATAGs */
|
||||
#define CONFIG_SETUP_MEMORY_TAGS
|
||||
#define CONFIG_INITRD_TAG
|
||||
--
|
||||
1.8.1.4
|
||||
|
130
0014-mmc-Add-RSTN-enable-for-emmc.patch
Normal file
130
0014-mmc-Add-RSTN-enable-for-emmc.patch
Normal file
@ -0,0 +1,130 @@
|
||||
From 6d70e6f0a9fbb9dc6ec2429292619f7cbc4d6a5b Mon Sep 17 00:00:00 2001
|
||||
From: Pantelis Antoniou <panto@antoniou-consulting.com>
|
||||
Date: Fri, 10 May 2013 17:48:20 +0300
|
||||
Subject: [PATCH 14/14] mmc: Add RSTN enable for emmc
|
||||
|
||||
eMMC has the capability of using an external RSTn line.
|
||||
It has to be enabled via an access to the ECSD so add a command to do so.
|
||||
|
||||
Signed-off-by: Pantelis Antoniou <panto@antoniou-consulting.com>
|
||||
---
|
||||
common/cmd_mmc.c | 26 +++++++++++++++++++++++++-
|
||||
drivers/mmc/mmc.c | 32 ++++++++++++++++++++++++++++++++
|
||||
include/mmc.h | 4 ++++
|
||||
3 files changed, 61 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/common/cmd_mmc.c b/common/cmd_mmc.c
|
||||
index 7d82469..dcfbf19 100644
|
||||
--- a/common/cmd_mmc.c
|
||||
+++ b/common/cmd_mmc.c
|
||||
@@ -208,6 +208,29 @@ static int do_mmcops(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
|
||||
return CMD_RET_USAGE;
|
||||
print_mmc_devices('\n');
|
||||
return 0;
|
||||
+ } else if (strncmp(argv[1], "rstn", 4) == 0) {
|
||||
+ struct mmc *mmc;
|
||||
+ u8 val;
|
||||
+ int err;
|
||||
+
|
||||
+ if (argc != 3)
|
||||
+ return CMD_RET_USAGE;
|
||||
+
|
||||
+ val = simple_strtol(argv[2], NULL, 10);
|
||||
+
|
||||
+ mmc = find_mmc_device(curr_device);
|
||||
+ if (!mmc) {
|
||||
+ printf("no mmc device at slot %x\n", curr_device);
|
||||
+ return 1;
|
||||
+ }
|
||||
+ err = mmc_set_rst_n(mmc, val);
|
||||
+ if (err != 0) {
|
||||
+ printf("failed to set RST_N to 0x%02x\n",
|
||||
+ (unsigned int)val & 0xff);
|
||||
+ return 1;
|
||||
+ }
|
||||
+
|
||||
+ return 0;
|
||||
} else if (strcmp(argv[1], "dev") == 0) {
|
||||
int dev, part = -1;
|
||||
struct mmc *mmc;
|
||||
@@ -334,5 +357,6 @@ U_BOOT_CMD(
|
||||
"mmc rescan\n"
|
||||
"mmc part - lists available partition on current mmc device\n"
|
||||
"mmc dev [dev] [part] - show or set current mmc device [partition]\n"
|
||||
- "mmc list - lists available devices");
|
||||
+ "mmc list - lists available devices\n"
|
||||
+ "mmc rstn - enable hardware reset of emmc");
|
||||
#endif
|
||||
diff --git a/drivers/mmc/mmc.c b/drivers/mmc/mmc.c
|
||||
index f65a7b0..4fffc87 100644
|
||||
--- a/drivers/mmc/mmc.c
|
||||
+++ b/drivers/mmc/mmc.c
|
||||
@@ -1360,6 +1360,38 @@ int get_mmc_num(void)
|
||||
return cur_dev_num;
|
||||
}
|
||||
|
||||
+/* enable hardware reset signal */
|
||||
+int mmc_set_rst_n(struct mmc *mmc, u8 val)
|
||||
+{
|
||||
+ ALLOC_CACHE_ALIGN_BUFFER(u8, ext_csd, 512);
|
||||
+ int err;
|
||||
+
|
||||
+ memset(ext_csd, 0, 512);
|
||||
+ err = mmc_send_ext_csd(mmc, ext_csd);
|
||||
+ if (err)
|
||||
+ return err;
|
||||
+
|
||||
+ printf("before: RST_N=0x%02x\n",
|
||||
+ (unsigned int)ext_csd[EXT_CSD_RST_N_FUNCTION] & 0xff);
|
||||
+
|
||||
+ printf("setting rstn to 0x%02x\n", (unsigned int)val & 0xff);
|
||||
+
|
||||
+ err = mmc_switch(mmc, EXT_CSD_CMD_SET_NORMAL,
|
||||
+ EXT_CSD_RST_N_FUNCTION, val);
|
||||
+ if (err)
|
||||
+ return err;
|
||||
+
|
||||
+ memset(ext_csd, 0, 512);
|
||||
+ err = mmc_send_ext_csd(mmc, ext_csd);
|
||||
+ if (err)
|
||||
+ return err;
|
||||
+
|
||||
+ printf("after: RST_N=0x%02x\n",
|
||||
+ (unsigned int)ext_csd[EXT_CSD_RST_N_FUNCTION] & 0xff);
|
||||
+
|
||||
+ return 0;
|
||||
+}
|
||||
+
|
||||
int mmc_initialize(bd_t *bis)
|
||||
{
|
||||
INIT_LIST_HEAD (&mmc_devices);
|
||||
diff --git a/include/mmc.h b/include/mmc.h
|
||||
index f0d4820..a1fc8c0 100644
|
||||
--- a/include/mmc.h
|
||||
+++ b/include/mmc.h
|
||||
@@ -158,6 +158,7 @@
|
||||
* EXT_CSD fields
|
||||
*/
|
||||
#define EXT_CSD_PARTITIONING_SUPPORT 160 /* RO */
|
||||
+#define EXT_CSD_RST_N_FUNCTION 162 /* R/W */
|
||||
#define EXT_CSD_ERASE_GROUP_DEF 175 /* R/W */
|
||||
#define EXT_CSD_PART_CONF 179 /* R/W */
|
||||
#define EXT_CSD_BUS_WIDTH 183 /* R/W */
|
||||
@@ -168,6 +169,7 @@
|
||||
#define EXT_CSD_HC_ERASE_GRP_SIZE 224 /* RO */
|
||||
#define EXT_CSD_BOOT_MULT 226 /* RO */
|
||||
|
||||
+
|
||||
/*
|
||||
* EXT_CSD field definitions
|
||||
*/
|
||||
@@ -291,4 +293,6 @@ struct mmc *mmc_spi_init(uint bus, uint cs, uint speed, uint mode);
|
||||
int mmc_legacy_init(int verbose);
|
||||
#endif
|
||||
|
||||
+int mmc_set_rst_n(struct mmc *mmc, u8 val);
|
||||
+
|
||||
#endif /* _MMC_H_ */
|
||||
--
|
||||
1.8.1.4
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
Name: uboot-tools
|
||||
Version: 2013.04
|
||||
Release: 1%{?candidate:.%{candidate}}%{?dist}
|
||||
Release: 2%{?candidate:.%{candidate}}%{?dist}
|
||||
Summary: U-Boot utilities
|
||||
|
||||
Group: Development/Tools
|
||||
@ -12,6 +12,22 @@ Source0: ftp://ftp.denx.de/pub/u-boot/u-boot-%{version}%{?candidate:-%{ca
|
||||
Patch1: u-boot-fat.patch
|
||||
Patch2: uboot-omap-fit.patch
|
||||
|
||||
# Beagle Bone Black support
|
||||
Patch10: 0001-beaglebone-default-to-beaglebone-black-for-unknown-E.patch
|
||||
Patch11: 0002-am335x-mux-don-t-hang-on-unknown-EEPROMs-assume-Beag.patch
|
||||
Patch12: 0003-beaglebone-HACK-always-return-1-for-is_bone_lt.patch
|
||||
Patch13: 0004-beaglebone-HACK-raise-USB-current-limit.patch
|
||||
Patch14: 0005-beaglebone-use-kloadaddr-to-avoid-copying-the-kernel.patch
|
||||
Patch15: 0006-beaglebone-try-to-load-uEnv-uImage-from-eMMC-first.patch
|
||||
Patch16: 0007-beaglebone-Don-t-trigger-uboot-variable-lenght-limit.patch
|
||||
Patch17: 0008-beaglebone-HACK-change-mmc-order-to-avoid-u-boot-cra.patch
|
||||
Patch18: 0009-beaglebone-update-bootpart-variable-after-mmc-scan.patch
|
||||
Patch19: 0010-am335x_evm-enable-gpio-command.patch
|
||||
Patch20: 0011-am335x_evm-HACK-to-turn-on-BeagleBone-LEDs.patch
|
||||
Patch21: 0012-Fix-for-screen-rolling-when-video-played-back-in-bro.patch
|
||||
Patch22: 0013-beaglebone-enable-CONFIG_SUPPORT_RAW_INITRD-option.patch
|
||||
Patch23: 0014-mmc-Add-RSTN-enable-for-emmc.patch
|
||||
|
||||
Requires: dtc
|
||||
|
||||
|
||||
@ -80,6 +96,23 @@ u-boot bootloader binaries for Wandboard i.MX6 Solo
|
||||
%setup -q -n u-boot-%{version}%{?candidate:-%{candidate}}
|
||||
%patch1 -p1
|
||||
%patch2 -p1
|
||||
|
||||
# Beagle Bone Black support
|
||||
%patch10 -p1
|
||||
%patch11 -p1
|
||||
%patch12 -p1
|
||||
%patch13 -p1
|
||||
%patch14 -p1
|
||||
%patch15 -p1
|
||||
%patch16 -p1
|
||||
%patch17 -p1
|
||||
%patch18 -p1
|
||||
%patch19 -p1
|
||||
%patch20 -p1
|
||||
%patch21 -p1
|
||||
%patch22 -p1
|
||||
%patch23 -p1
|
||||
|
||||
mkdir builds
|
||||
|
||||
%build
|
||||
@ -220,6 +253,9 @@ rm -rf $RPM_BUILD_ROOT
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Mon May 13 2013 Peter Robinson <pbrobinson@fedoraproject.org> 2013.04-2
|
||||
- Add patches for initial support for the Beagle Bone Black
|
||||
|
||||
* Sun Apr 21 2013 Peter Robinson <pbrobinson@fedoraproject.org> 2013.04-1
|
||||
- Update to 2013.04 release
|
||||
- Build i.MX6 Wandboard Dual Lite and Solo Boards
|
||||
|
Loading…
x
Reference in New Issue
Block a user