[U-Boot] [PATCH 11/11] DM: switch sandbox to DM blockdev
Pavel Herrmann
morpheus.ibis at gmail.com
Thu Sep 20 21:37:47 CEST 2012
add CONFIG_DM_BLOCK to include/configs/sandbox.h to enable it all
Signed-off-by: Pavel Herrmann <morpheus.ibis at gmail.com>
---
arch/sandbox/lib/board.c | 8 ++++++++
include/configs/sandbox.h | 4 ++++
2 files changed, 12 insertions(+)
diff --git a/arch/sandbox/lib/board.c b/arch/sandbox/lib/board.c
index c79cc62..a6fc67d 100644
--- a/arch/sandbox/lib/board.c
+++ b/arch/sandbox/lib/board.c
@@ -243,6 +243,10 @@ void board_init_r(gd_t *id, ulong dest_addr)
.name = "gpio_sandbox",
.platform_data = NULL
};
+ static const struct driver_info sata_info = {
+ .name = "sata_legacy",
+ .platform_data = NULL
+ };
struct instance *root = get_root_instance();
struct instance *demo1, *demo2, *demo3;
@@ -254,8 +258,12 @@ void board_init_r(gd_t *id, ulong dest_addr)
demo3 = driver_bind(demo2, &info);
driver_bind(demo2, &info);
driver_bind(root, &gs_info);
+ driver_bind(root, &sata_info);
demo_hello(demo2);
+ void *startram = os_malloc(1024*1024*16);
+ void *endram = startram + (1024*1024*16);
+ printf("scratch memory from %p to %p\n", startram, endram);
/* initialize environment */
env_relocate();
diff --git a/include/configs/sandbox.h b/include/configs/sandbox.h
index a713430..70ae37b 100644
--- a/include/configs/sandbox.h
+++ b/include/configs/sandbox.h
@@ -99,6 +99,10 @@
#define CONFIG_SYS_SATA_MAX_DEVICE 2
#define CONFIG_DOS_PARTITION
#define CONFIG_CMD_FAT
+#define CONFIG_FAT_WRITE
#define CONFIG_CMD_EXT2
+#define CONFIG_DM_BLOCK
+#define CONFIG_BLOCK_SATA_LEGACY
+
#endif
--
1.7.12
More information about the U-Boot
mailing list