From: Peter Chen Date: Fri, 18 Sep 2020 13:17:47 +0000 (+0300) Subject: usb: host: xhci-plat: add wakeup entry at sysfs X-Git-Tag: baikal/aarch64/sdk6.1~8162^2~68 X-Git-Url: https://git.baikalelectronics.ru/sdk/?a=commitdiff_plain;h=15ca650729a5e41e3ab2f9b1bc7382f92191b6d4;p=kernel.git usb: host: xhci-plat: add wakeup entry at sysfs With this change, there will be a wakeup entry at /sys/../power/wakeup, and the user could use this entry to choose whether enable xhci wakeup features (wake up system from suspend) or not. Tested-by: Matthias Kaehlcke Reviewed-by: Matthias Kaehlcke Signed-off-by: Peter Chen Signed-off-by: Mathias Nyman Link: https://lore.kernel.org/r/20200918131752.16488-6-mathias.nyman@linux.intel.com Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/usb/host/xhci-plat.c b/drivers/usb/host/xhci-plat.c index 14ff65a387e80..cfca6fc8947c1 100644 --- a/drivers/usb/host/xhci-plat.c +++ b/drivers/usb/host/xhci-plat.c @@ -287,7 +287,7 @@ static int xhci_plat_probe(struct platform_device *pdev) *priv = *priv_match; } - device_wakeup_enable(hcd->self.controller); + device_set_wakeup_capable(&pdev->dev, true); xhci->main_hcd = hcd; xhci->shared_hcd = __usb_create_hcd(driver, sysdev, &pdev->dev,