* [PATCH -next] MMC: meson: remove redundant return value check of platform_get_resource()
@ 2016-08-20 15:30 Wei Yongjun
0 siblings, 0 replies; only message in thread
From: Wei Yongjun @ 2016-08-20 15:30 UTC (permalink / raw)
To: linux-arm-kernel
Remove unneeded error handling on the result of a call
to platform_get_resource() when the value is passed to
devm_ioremap_resource().
Signed-off-by: Wei Yongjun <weiyj.lk@gmail.com>
---
drivers/mmc/host/meson-gxbb.c | 4 ----
1 file changed, 4 deletions(-)
diff --git a/drivers/mmc/host/meson-gxbb.c b/drivers/mmc/host/meson-gxbb.c
index 10eac41..96cd883 100644
--- a/drivers/mmc/host/meson-gxbb.c
+++ b/drivers/mmc/host/meson-gxbb.c
@@ -811,10 +811,6 @@ static int meson_mmc_probe(struct platform_device *pdev)
}
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
- if (!res) {
- ret = -ENODEV;
- goto free_host;
- }
host->regs = devm_ioremap_resource(&pdev->dev, res);
if (IS_ERR(host->regs)) {
ret = PTR_ERR(host->regs);
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2016-08-20 15:30 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-08-20 15:30 [PATCH -next] MMC: meson: remove redundant return value check of platform_get_resource() Wei Yongjun
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).