u-boot/common/spl
Simon Glass d773a008ee spl: mmc: Fix compiler warning with CONFIG_DM_MMC
Since commit 4188ba3 we get the following warning on rockchip boards:

common/spl/spl_mmc.c:31:24: warning: ‘mmc’ may be used uninitialized in this function [-Wmaybe-uninitialized]
  count = mmc->block_dev.block_read(0, sector, 1, header);
                        ^
common/spl/spl_mmc.c:251:14: note: ‘mmc’ was declared here
  struct mmc *mmc;

Correct this by move the variable init earlier.

Signed-off-by: Simon Glass <sjg@chromium.org>
Tested-by: Michal Simek <michal.simek@xilinx.com>
Acked-by: Nikita Kiryanov <nikita@compulab.co.il>
2015-12-05 18:22:33 -05:00
..
Makefile spl: Add EXT support to SPL 2014-10-27 17:54:03 -04:00
spl.c spl: mmc: add support for BOOT_DEVICE_MMC2 2015-11-18 14:50:05 -05:00
spl_ext.c spl: mmc: remove #ifdef CONFIG_SPL_OS_BOOT check 2015-11-18 14:50:00 -05:00
spl_fat.c spl: mmc: remove #ifdef CONFIG_SPL_OS_BOOT check 2015-11-18 14:50:00 -05:00
spl_mmc.c spl: mmc: Fix compiler warning with CONFIG_DM_MMC 2015-12-05 18:22:33 -05:00
spl_nand.c spl: change return values of spl_*_load_image() 2015-11-18 14:50:02 -05:00
spl_net.c spl: change return values of spl_*_load_image() 2015-11-18 14:50:02 -05:00
spl_nor.c spl: change return values of spl_*_load_image() 2015-11-18 14:50:02 -05:00
spl_onenand.c spl: change return values of spl_*_load_image() 2015-11-18 14:50:02 -05:00
spl_sata.c spl: change return values of spl_*_load_image() 2015-11-18 14:50:02 -05:00
spl_usb.c spl: change return values of spl_*_load_image() 2015-11-18 14:50:02 -05:00
spl_ymodem.c spl: change return values of spl_*_load_image() 2015-11-18 14:50:02 -05:00