diff options
author | Simon Glass <sjg@chromium.org> | 2015-12-02 10:59:11 -0700 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2015-12-05 18:22:33 -0500 |
commit | d773a008ee3135b28becc5ebce050c931767fed8 (patch) | |
tree | 148552012bda50c9353049d35349ad074e4766d7 /common/cmd_sf.c | |
parent | 9cb05a8f9f87297820a5ff6a487f100cb1cd69c1 (diff) | |
download | blackbird-obmc-uboot-d773a008ee3135b28becc5ebce050c931767fed8.tar.gz blackbird-obmc-uboot-d773a008ee3135b28becc5ebce050c931767fed8.zip |
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>
Diffstat (limited to 'common/cmd_sf.c')
0 files changed, 0 insertions, 0 deletions