summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLubomir Popov <lpopov@mm-sol.com>2014-11-11 12:25:42 +0200
committerPantelis Antoniou <pantelis.antoniou@konsulko.com>2014-12-12 20:08:47 +0200
commite75eaf100bdf01b94757e2b40365b46a7d380275 (patch)
tree5e295fa7d09dec1b5f4a5a3203566ffa83b9c3cf
parentfc9b0b80435cda721fbdbe507c9e4f388b0ea62b (diff)
downloadu-boot-imx-e75eaf100bdf01b94757e2b40365b46a7d380275.zip
u-boot-imx-e75eaf100bdf01b94757e2b40365b46a7d380275.tar.gz
u-boot-imx-e75eaf100bdf01b94757e2b40365b46a7d380275.tar.bz2
mmc: Cosmetic fix for nicer, aligned device list printout
If print_mmc_devices() was called with a '\n' separator (as done for example by the "mmc list" command), it offset the 2-nd and all subsequent lines by one space. Fixing this. Signed-off-by: Lubomir Popov <l-popov@ti.com>
-rw-r--r--drivers/mmc/mmc.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/mmc/mmc.c b/drivers/mmc/mmc.c
index 8436bc7..9dc924c 100644
--- a/drivers/mmc/mmc.c
+++ b/drivers/mmc/mmc.c
@@ -1408,8 +1408,11 @@ void print_mmc_devices(char separator)
printf("%s: %d", m->cfg->name, m->block_dev.dev);
- if (entry->next != &mmc_devices)
- printf("%c ", separator);
+ if (entry->next != &mmc_devices) {
+ printf("%c", separator);
+ if (separator != '\n')
+ puts (" ");
+ }
}
printf("\n");