summaryrefslogtreecommitdiffstats
path: root/common
diff options
context:
space:
mode:
authorPaul Kocialkowski <contact@paulk.fr>2015-06-03 18:48:51 +0200
committerTom Rini <trini@konsulko.com>2015-06-18 16:11:42 -0400
commit1ec264695f746dd033a14762344aefff0aa3e3b5 (patch)
treee97e7ebe1d17bfd108daaa146a2b351167cd5a6b /common
parent0b367380a52ac36b552d40ed1b10064d894e35a9 (diff)
downloadtalos-obmc-uboot-1ec264695f746dd033a14762344aefff0aa3e3b5.tar.gz
talos-obmc-uboot-1ec264695f746dd033a14762344aefff0aa3e3b5.zip
spl: spl_mmc: Minor cosmetics
This switches some printf calls to puts and avoids a test repetition. Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
Diffstat (limited to 'common')
-rw-r--r--common/spl/spl_mmc.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/common/spl/spl_mmc.c b/common/spl/spl_mmc.c
index de495c0dc4..f5ac844c0a 100644
--- a/common/spl/spl_mmc.c
+++ b/common/spl/spl_mmc.c
@@ -43,13 +43,12 @@ static int mmc_load_image_raw_sector(struct mmc *mmc, unsigned long sector)
(void *) spl_image.load_addr);
end:
+ if (count == 0) {
#ifdef CONFIG_SPL_LIBCOMMON_SUPPORT
- if (count == 0)
- printf("spl: mmc block read error\n");
+ puts("spl: mmc block read error\n");
#endif
-
- if (count == 0)
return -1;
+ }
return 0;
}
@@ -63,7 +62,7 @@ static int mmc_load_image_raw_partition(struct mmc *mmc, int partition)
err = get_partition_info(&mmc->block_dev, partition, &info);
if (err) {
#ifdef CONFIG_SPL_LIBCOMMON_SUPPORT
- printf("spl: partition error\n");
+ puts("spl: partition error\n");
#endif
return -1;
}
@@ -83,7 +82,7 @@ static int mmc_load_image_raw_os(struct mmc *mmc)
(void *) CONFIG_SYS_SPL_ARGS_ADDR);
if (count == 0) {
#ifdef CONFIG_SPL_LIBCOMMON_SUPPORT
- printf("spl: mmc block read error\n");
+ puts("spl: mmc block read error\n");
#endif
return -1;
}
OpenPOWER on IntegriCloud