diff options
-rwxr-xr-x | common/Makefile | 2 | ||||
-rw-r--r-- | common/cmd_toc.c | 7 | ||||
-rw-r--r-- | include/configs/u8500.h | 2 |
3 files changed, 10 insertions, 1 deletions
diff --git a/common/Makefile b/common/Makefile index 0945735f7..226ae720f 100755 --- a/common/Makefile +++ b/common/Makefile @@ -153,7 +153,7 @@ endif COBJS-$(CONFIG_CMD_XIMG) += cmd_ximg.o COBJS-$(CONFIG_YAFFS2) += cmd_yaffs2.o COBJS-$(CONFIG_VFD) += cmd_vfd.o -COBJS-$(CONFIG_TOC_PARTITION) += cmd_toc.o +COBJS-$(CONFIG_CMD_TOC) += cmd_toc.o # others COBJS-$(CONFIG_DDR_SPD) += ddr_spd.o diff --git a/common/cmd_toc.c b/common/cmd_toc.c index e7312df63..25cfd83c4 100644 --- a/common/cmd_toc.c +++ b/common/cmd_toc.c @@ -58,6 +58,8 @@ int do_toc_entry_load(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]) u32 size; u32 addr; char loadaddr[16]; + char size_buf[16]; + char offset_buf[16]; block_dev_desc_t *dev_desc; int blks; char *ep; @@ -99,6 +101,11 @@ int do_toc_entry_load(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]) sprintf(loadaddr, "0x%x", addr); setenv("loadaddr", loadaddr); + sprintf(size_buf, "0x%x", size); + setenv("tocentrysize", size_buf); + + sprintf(offset_buf, "0x%x", offset); + setenv("tocentryoffset", offset_buf); return 0; } else printf("Failed to get TOC entry!\n"); diff --git a/include/configs/u8500.h b/include/configs/u8500.h index d33b39951..2c259bd41 100644 --- a/include/configs/u8500.h +++ b/include/configs/u8500.h @@ -84,6 +84,7 @@ #define CONFIG_MMC 1 #define CONFIG_GENERIC_MMC 1 #define CONFIG_DOS_PARTITION 1 +#define CONFIG_TOC_PARTITION 1 #define CONFIG_ROCKBOX_FAT 1 #define CONFIG_U_BOOT 1 /* needed by Rockbox code */ #define CONFIG_SUPPORT_VFAT 1 /* Rockbox */ @@ -108,6 +109,7 @@ #define CONFIG_CMD_EMMC #define CONFIG_CMD_SOURCE #define CONFIG_CMD_I2C +#define CONFIG_CMD_TOC #ifdef CONFIG_USB_TTY #define CONFIG_BOOTDELAY -1 /* disable autoboot */ |