usb: xhci: plat: Enable async suspend/resume
authorAndrew Bresticker <abrestic@chromium.org>
Fri, 7 Apr 2017 14:56:49 +0000 (17:56 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 8 Apr 2017 10:04:42 +0000 (12:04 +0200)
USB host controllers can take a significant amount of time to suspend
and resume, adding several hundred miliseconds to the kernel resume
time. Since the XHCI controller has no outside dependencies (other than
clocks, which are suspended late/resumed early), allow it to suspend and
resume asynchronously.

Signed-off-by: Andrew Bresticker <abrestic@chromium.org>
Tested-by: Andrew Bresticker <abrestic@chromium.org>
Tested-by: Robert Foss <robert.foss@collabora.com>
Signed-off-by: Robert Foss <robert.foss@collabora.com>
Reviewed-by: Baolin Wang <baolin.wang@linaro.org>
Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/host/xhci-plat.c

index f31b9dcdaf5bd44d4cee7a59086011106cadef19..62e71b8a8b5553f592f6759d5461daf2fd1cfb56 100644 (file)
@@ -277,6 +277,8 @@ static int xhci_plat_probe(struct platform_device *pdev)
        if (ret)
                goto dealloc_usb2_hcd;
 
+       device_enable_async_suspend(&pdev->dev);
+
        return 0;