summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSjoerd Simons <sjoerd.simons@collabora.co.uk>2015-12-04 23:27:40 +0100
committerSimon Glass <sjg@chromium.org>2015-12-13 17:07:31 -0700
commitfc011f6402d3d63fe826260fcc5940d7b7fb138e (patch)
treed9d470124b9606e6a87f90881d149895517a12c9
parente4c5383e4d46ef196d022b481cab364bd3b9c877 (diff)
downloadu-boot-imx-fc011f6402d3d63fe826260fcc5940d7b7fb138e.zip
u-boot-imx-fc011f6402d3d63fe826260fcc5940d7b7fb138e.tar.gz
u-boot-imx-fc011f6402d3d63fe826260fcc5940d7b7fb138e.tar.bz2
mmc: mmc: Don't use sprintf when using tiny-printf
There is no sprintf implementation in tiny-printf, so don't try to use it when tiny-printf if used. Signed-off-by: Sjoerd Simons <sjoerd.simons@collabora.co.uk>
-rw-r--r--drivers/mmc/mmc.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/mmc/mmc.c b/drivers/mmc/mmc.c
index 2a58702..3a34028 100644
--- a/drivers/mmc/mmc.c
+++ b/drivers/mmc/mmc.c
@@ -1469,7 +1469,9 @@ static int mmc_startup(struct mmc *mmc)
mmc->block_dev.blksz = mmc->read_bl_len;
mmc->block_dev.log2blksz = LOG2(mmc->block_dev.blksz);
mmc->block_dev.lba = lldiv(mmc->capacity, mmc->read_bl_len);
-#if !defined(CONFIG_SPL_BUILD) || defined(CONFIG_SPL_LIBCOMMON_SUPPORT)
+#if !defined(CONFIG_SPL_BUILD) || \
+ (defined(CONFIG_SPL_LIBCOMMON_SUPPORT) && \
+ !defined(CONFIG_USE_TINY_PRINTF))
sprintf(mmc->block_dev.vendor, "Man %06x Snr %04x%04x",
mmc->cid[0] >> 24, (mmc->cid[2] & 0xffff),
(mmc->cid[3] >> 16) & 0xffff);