Re: [PATCH] PCI: fix incorrect error return in pci_enable_wake

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thursday, 11 of December 2008, Alan Stern wrote:
> This patch (as1186) fixes a minor mistake in pci_enable_wake().  When
> the routine is asked to disable remote wakeup, it should not return an
> error merely because the device is not allowed to do wakeups!
> 
> Signed-off-by: Alan Stern <stern@xxxxxxxxxxxxxxxxxxx>

Acked-by: Rafael J. Wysocki <rjw@xxxxxxx>

[This should go to Jesse, BTW, already CCed.]
> ---
> 
> Index: usb-2.6/drivers/pci/pci.c
> ===================================================================
> --- usb-2.6.orig/drivers/pci/pci.c
> +++ usb-2.6/drivers/pci/pci.c
> @@ -1107,7 +1107,7 @@ int pci_enable_wake(struct pci_dev *dev,
>  	int error = 0;
>  	bool pme_done = false;
>  
> -	if (!device_may_wakeup(&dev->dev))
> +	if (enable && !device_may_wakeup(&dev->dev))
>  		return -EINVAL;
>  
>  	/*
_______________________________________________
linux-pm mailing list
linux-pm@xxxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linux-foundation.org/mailman/listinfo/linux-pm

[Index of Archives]     [Linux ACPI]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [CPU Freq]     [Kernel Newbies]     [Fedora Kernel]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux