[lkml]   [2019]   [Jun]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH 2/2] PCI: PM: Replace pci_dev_keep_suspended() with two functions
On Fri, Jun 07, 2019 at 12:32:31AM +0200, Rafael J. Wysocki wrote:
> From: Rafael J. Wysocki <>
> The code in pci_dev_keep_suspended() is relatively hard to follow due
> to the negative checks in it and in its callers and the function has
> a possible side-effect (disabling the PME) which doesn't really match
> its role.
> For this reason, move the PME disablig from pci_dev_keep_suspended()

> to a separate function and change the semantics (and name) of the
> rest of it, so that 'true' is returned when the device needs to be
> resumed (and not the other way around). Change the callers of
> pci_dev_keep_suspended() accordingly.
> While at it, make the code flow in pci_pm_poweroff() reflect the
> pci_pm_suspend() more closely to avoid arbitrary differences between
> them.
> This is a cosmetic change with no intention to alter behavior.
> Signed-off-by: Rafael J. Wysocki <>

Reviewed-by: Mika Westerberg <>

 \ /
  Last update: 2019-06-07 13:21    [W:0.038 / U:2.516 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site