summaryrefslogtreecommitdiffstats
path: root/drivers/usb/host
diff options
context:
space:
mode:
authorVarka Bhadram <varkab@cdac.in>2014-11-04 07:51:09 +0530
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-11-07 09:01:49 -0800
commit54891d7404267ac7a89a464752feba6a851d18fd (patch)
treeb3468ea2ae57a9b97b2dd0b4bf7489d6d62685e4 /drivers/usb/host
parent0fb5f700e984d6e5c035d241ffab1900d0f1ebd2 (diff)
downloadblackbird-obmc-linux-54891d7404267ac7a89a464752feba6a851d18fd.tar.gz
blackbird-obmc-linux-54891d7404267ac7a89a464752feba6a851d18fd.zip
host: ohci-da8xx: remove duplicate check on resource
Sanity check on resource happening with devm_ioremap_resource(). Signed-off-by: Varka Bhadram <varkab@cdac.in> Acked-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/host')
-rw-r--r--drivers/usb/host/ohci-da8xx.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/drivers/usb/host/ohci-da8xx.c b/drivers/usb/host/ohci-da8xx.c
index df06be6b47f5..1c76999b2184 100644
--- a/drivers/usb/host/ohci-da8xx.c
+++ b/drivers/usb/host/ohci-da8xx.c
@@ -313,16 +313,13 @@ static int usb_hcd_da8xx_probe(const struct hc_driver *driver,
return -ENOMEM;
mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
- if (!mem)
- return -ENODEV;
- hcd->rsrc_start = mem->start;
- hcd->rsrc_len = resource_size(mem);
-
hcd->regs = devm_ioremap_resource(&pdev->dev, mem);
if (IS_ERR(hcd->regs)) {
error = PTR_ERR(hcd->regs);
goto err;
}
+ hcd->rsrc_start = mem->start;
+ hcd->rsrc_len = resource_size(mem);
ohci_hcd_init(hcd_to_ohci(hcd));
OpenPOWER on IntegriCloud