"Das U-Boot" Source Tree
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

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>

authored by

Simon Glass and committed by
Tom Rini
8369dd05 337bfdce

+4 -2
+4 -2
common/spl/spl_mmc.c
··· 81 81 struct uclass *uc; 82 82 83 83 log_debug("Selecting MMC dev %d; seqs:\n", mmc_dev); 84 - uclass_id_foreach_dev(UCLASS_MMC, dev, uc) 85 - log_debug("%d: %s\n", dev_seq(dev), dev->name); 84 + if (_LOG_DEBUG) { 85 + uclass_id_foreach_dev(UCLASS_MMC, dev, uc) 86 + log_debug("%d: %s\n", dev_seq(dev), dev->name); 87 + } 86 88 ret = mmc_init_device(mmc_dev); 87 89 #else 88 90 ret = mmc_initialize(NULL);