summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZiyuan Xu <xzy.xu@rock-chips.com>2017-05-15 09:07:07 +0300
committerKever Yang <kever.yang@rock-chips.com>2017-07-18 17:05:01 +0300
commitf042f77657fecd1a5055c0eb6094fcf6c2aa9745 (patch)
tree9a393f39c4217a61f015e095e1cb7f1bd6b28dcb
parent119a7134bfe85ef6fdb2e2a1910185545de41c45 (diff)
downloadu-boot-f042f77657fecd1a5055c0eb6094fcf6c2aa9745.tar.xz
cmd: mmc: show the current speed mode
So far mmc framework had support speed mode switch, it good to show the current speed mode from 'mmc info'. Signed-off-by: Ziyuan Xu <xzy.xu@rock-chips.com>
-rw-r--r--cmd/mmc.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/cmd/mmc.c b/cmd/mmc.c
index 6ead27ae2a..832eeb07dc 100644
--- a/cmd/mmc.c
+++ b/cmd/mmc.c
@@ -15,6 +15,10 @@ static int curr_device = -1;
static void print_mmcinfo(struct mmc *mmc)
{
int i;
+ const char *timing[] = {
+ "Legacy", "High Speed", "High Speed", "SDR12",
+ "SDR25", "SDR50", "SDR104", "DDR50",
+ "DDR52", "HS200", "HS400", "HS400 Enhanced Strobe"};
printf("Device: %s\n", mmc->cfg->name);
printf("Manufacturer ID: %x\n", mmc->cid[0] >> 24);
@@ -23,6 +27,7 @@ static void print_mmcinfo(struct mmc *mmc)
(mmc->cid[1] >> 24), (mmc->cid[1] >> 16) & 0xff,
(mmc->cid[1] >> 8) & 0xff, mmc->cid[1] & 0xff);
+ printf("Timing Interface: %s\n", timing[mmc->timing]);
printf("Tran Speed: %d\n", mmc->clock);
printf("Rd Block Len: %d\n", mmc->read_bl_len);