usb: hcd: move controller wakeup setting initialization to individual driver
[firefly-linux-kernel-4.4.55.git] / drivers / usb / host / ehci-mv.c
index 417c10da945078e37ddf20e7be290e996936074e..bd61612a725146ac24ed1c9ae4499633d58541eb 100644 (file)
@@ -178,7 +178,7 @@ static int mv_ehci_probe(struct platform_device *pdev)
 
        ehci_mv->phy_regs = devm_ioremap(&pdev->dev, r->start,
                                         resource_size(r));
-       if (ehci_mv->phy_regs == 0) {
+       if (!ehci_mv->phy_regs) {
                dev_err(&pdev->dev, "failed to map phy I/O memory\n");
                retval = -EFAULT;
                goto err_put_hcd;
@@ -257,6 +257,7 @@ static int mv_ehci_probe(struct platform_device *pdev)
                                "failed to add hcd with err %d\n", retval);
                        goto err_set_vbus;
                }
+               device_wakeup_enable(hcd->self.controller);
        }
 
        if (pdata->private_init)