mirror of
https://source.denx.de/u-boot/u-boot.git
synced 2025-08-17 20:57:01 +02:00
spl: mmc: Avoid size growth in spl_mmc_find_device() debug
The for() loop ends up being in the code even if the log_debug() does nothing. Add a condition to fix this. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Jaehoon Chung <jh80.chung@samsung.com>
This commit is contained in:
parent
62224280d9
commit
a2c90dc371
@ -81,8 +81,10 @@ static int spl_mmc_find_device(struct mmc **mmcp, int mmc_dev)
|
|||||||
struct uclass *uc;
|
struct uclass *uc;
|
||||||
|
|
||||||
log_debug("Selecting MMC dev %d; seqs:\n", mmc_dev);
|
log_debug("Selecting MMC dev %d; seqs:\n", mmc_dev);
|
||||||
uclass_id_foreach_dev(UCLASS_MMC, dev, uc)
|
if (_LOG_DEBUG) {
|
||||||
log_debug("%d: %s\n", dev_seq(dev), dev->name);
|
uclass_id_foreach_dev(UCLASS_MMC, dev, uc)
|
||||||
|
log_debug("%d: %s\n", dev_seq(dev), dev->name);
|
||||||
|
}
|
||||||
ret = mmc_init_device(mmc_dev);
|
ret = mmc_init_device(mmc_dev);
|
||||||
#else
|
#else
|
||||||
ret = mmc_initialize(NULL);
|
ret = mmc_initialize(NULL);
|
||||||
|
Loading…
Reference in New Issue
Block a user