[PATCH v1 3/6] rockchip: rk3066: add Rockchip IDB block device as boot action
Johan Jonker
jbx6244 at gmail.com
Tue Jul 5 15:04:37 CEST 2022
From: Johan Jonker <jbx6244 at gmail.com>
Add Rockchip IDB block device as boot action for rk3066.
When a key is pressed the NAND IDB blocks can be accessed
by a USB gadget like rockusb.
Signed-off-by: Johan Jonker <jbx6244 at gmail.com>
---
This patch comes on top of a serie called:
[PATCH v1 00/17] Add rk3066 ADC and USB support
https://lore.kernel.org/u-boot/20220508150825.21711-1-jbx6244@gmail.com/
---
arch/arm/mach-rockchip/rk3066/rk3066.c | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/arch/arm/mach-rockchip/rk3066/rk3066.c b/arch/arm/mach-rockchip/rk3066/rk3066.c
index be19400c..c2058369 100644
--- a/arch/arm/mach-rockchip/rk3066/rk3066.c
+++ b/arch/arm/mach-rockchip/rk3066/rk3066.c
@@ -32,6 +32,8 @@ void board_debug_uart_init(void)
GPIO1B0_UART2_SIN << GPIO1B0_SHIFT);
}
+int rk_idb_start(void);
+
__weak void do_spl(void)
{
if (CONFIG_IS_ENABLED(OF_PLATDATA))
@@ -43,6 +45,15 @@ __weak void do_spl(void)
int ret;
switch (spl_boot_device()) {
+#if IS_ENABLED(CONFIG_SPL_ROCKCHIP_IDB)
+ case BOOT_DEVICE_NAND:
+ dev_type = "idb";
+ dev_index = 0;
+ ret = rk_idb_start();
+ if (ret)
+ return;
+ break;
+#endif
case BOOT_DEVICE_MMC1:
dev_type = "mmc";
dev_index = 0;
--
2.20.1
More information about the U-Boot
mailing list