forked from Minki/linux
mmc: of_mmc_spi: fix unused warning
drivers/mmc/host/of_mmc_spi.c: In function 'mmc_spi_get_pdata': drivers/mmc/host/of_mmc_spi.c:77:6: warning: variable 'ret' set but not used [-Wunused-but-set-variable] int ret = -EINVAL; ^ Signed-off-by: Brian Norris <computersforpeace@gmail.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
This commit is contained in:
parent
91aa366109
commit
96466fcb6c
@ -74,7 +74,6 @@ struct mmc_spi_platform_data *mmc_spi_get_pdata(struct spi_device *spi)
|
|||||||
const u32 *voltage_ranges;
|
const u32 *voltage_ranges;
|
||||||
int num_ranges;
|
int num_ranges;
|
||||||
int i;
|
int i;
|
||||||
int ret = -EINVAL;
|
|
||||||
|
|
||||||
if (dev->platform_data || !np)
|
if (dev->platform_data || !np)
|
||||||
return dev->platform_data;
|
return dev->platform_data;
|
||||||
@ -97,7 +96,6 @@ struct mmc_spi_platform_data *mmc_spi_get_pdata(struct spi_device *spi)
|
|||||||
mask = mmc_vddrange_to_ocrmask(be32_to_cpu(voltage_ranges[j]),
|
mask = mmc_vddrange_to_ocrmask(be32_to_cpu(voltage_ranges[j]),
|
||||||
be32_to_cpu(voltage_ranges[j + 1]));
|
be32_to_cpu(voltage_ranges[j + 1]));
|
||||||
if (!mask) {
|
if (!mask) {
|
||||||
ret = -EINVAL;
|
|
||||||
dev_err(dev, "OF: voltage-range #%d is invalid\n", i);
|
dev_err(dev, "OF: voltage-range #%d is invalid\n", i);
|
||||||
goto err_ocr;
|
goto err_ocr;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user