summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorVarka Bhadram <varkabhadram@gmail.com>2014-11-04 07:51:28 +0530
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-11-07 09:01:51 -0800
commit972b98344beca6ca2f1de84141005a2ce2f8ffe5 (patch)
treec91cbc66a4e61d7f4ba1653656159796289b2bed /drivers
parente7020f193a3d135e5dda476452e3372e27cc1789 (diff)
downloadlinux-972b98344beca6ca2f1de84141005a2ce2f8ffe5.tar.bz2
musb: musb_core: remove duplicate check on resource
Sanity check on resource happening with devm_ioremap_resource(). Signed-off-by: Varka Bhadram <varkab@cdac.in> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/usb/musb/musb_core.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/musb/musb_core.c b/drivers/usb/musb/musb_core.c
index b841ee0bff06..55ebd4b1daac 100644
--- a/drivers/usb/musb/musb_core.c
+++ b/drivers/usb/musb/musb_core.c
@@ -2080,10 +2080,10 @@ static int musb_probe(struct platform_device *pdev)
struct resource *iomem;
void __iomem *base;
- iomem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
- if (!iomem || irq <= 0)
+ if (irq <= 0)
return -ENODEV;
+ iomem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
base = devm_ioremap_resource(dev, iomem);
if (IS_ERR(base))
return PTR_ERR(base);