Re: [PATCH] PM / core: Clear the direct_complete flag on errors

2018-10-04 Thread Ulf Hansson
On 4 October 2018 at 22:57, Rafael J. Wysocki wrote: > On Thu, Oct 4, 2018 at 8:48 PM Ulf Hansson wrote: >> >> On 4 October 2018 at 19:47, Rafael J. Wysocki wrote: >> > On Thu, Oct 4, 2018 at 3:23 PM Ulf Hansson wrote: >> >> >> >> On 4 October 2018 at 11:08, Rafael J. Wysocki wrote: >> >> >

Re: [PATCH] PM / core: Clear the direct_complete flag on errors

2018-10-04 Thread Ulf Hansson
On 4 October 2018 at 22:57, Rafael J. Wysocki wrote: > On Thu, Oct 4, 2018 at 8:48 PM Ulf Hansson wrote: >> >> On 4 October 2018 at 19:47, Rafael J. Wysocki wrote: >> > On Thu, Oct 4, 2018 at 3:23 PM Ulf Hansson wrote: >> >> >> >> On 4 October 2018 at 11:08, Rafael J. Wysocki wrote: >> >> >

Re: [PATCH] PM / core: Clear the direct_complete flag on errors

2018-10-04 Thread Rafael J. Wysocki
On Thu, Oct 4, 2018 at 8:48 PM Ulf Hansson wrote: > > On 4 October 2018 at 19:47, Rafael J. Wysocki wrote: > > On Thu, Oct 4, 2018 at 3:23 PM Ulf Hansson wrote: > >> > >> On 4 October 2018 at 11:08, Rafael J. Wysocki wrote: > >> > From: Rafael J. Wysocki > >> > > >> > If __device_suspend()

Re: [PATCH] PM / core: Clear the direct_complete flag on errors

2018-10-04 Thread Rafael J. Wysocki
On Thu, Oct 4, 2018 at 8:48 PM Ulf Hansson wrote: > > On 4 October 2018 at 19:47, Rafael J. Wysocki wrote: > > On Thu, Oct 4, 2018 at 3:23 PM Ulf Hansson wrote: > >> > >> On 4 October 2018 at 11:08, Rafael J. Wysocki wrote: > >> > From: Rafael J. Wysocki > >> > > >> > If __device_suspend()

Re: [PATCH] PM / core: Clear the direct_complete flag on errors

2018-10-04 Thread Ulf Hansson
On 4 October 2018 at 19:47, Rafael J. Wysocki wrote: > On Thu, Oct 4, 2018 at 3:23 PM Ulf Hansson wrote: >> >> On 4 October 2018 at 11:08, Rafael J. Wysocki wrote: >> > From: Rafael J. Wysocki >> > >> > If __device_suspend() returns early on an error or pending wakeup >> > and the

Re: [PATCH] PM / core: Clear the direct_complete flag on errors

2018-10-04 Thread Ulf Hansson
On 4 October 2018 at 19:47, Rafael J. Wysocki wrote: > On Thu, Oct 4, 2018 at 3:23 PM Ulf Hansson wrote: >> >> On 4 October 2018 at 11:08, Rafael J. Wysocki wrote: >> > From: Rafael J. Wysocki >> > >> > If __device_suspend() returns early on an error or pending wakeup >> > and the

Re: [PATCH] PM / core: Clear the direct_complete flag on errors

2018-10-04 Thread Rafael J. Wysocki
On Thu, Oct 4, 2018 at 3:23 PM Ulf Hansson wrote: > > On 4 October 2018 at 11:08, Rafael J. Wysocki wrote: > > From: Rafael J. Wysocki > > > > If __device_suspend() returns early on an error or pending wakeup > > and the power.direct_complete flag has been set for the device > > already, the

Re: [PATCH] PM / core: Clear the direct_complete flag on errors

2018-10-04 Thread Rafael J. Wysocki
On Thu, Oct 4, 2018 at 3:23 PM Ulf Hansson wrote: > > On 4 October 2018 at 11:08, Rafael J. Wysocki wrote: > > From: Rafael J. Wysocki > > > > If __device_suspend() returns early on an error or pending wakeup > > and the power.direct_complete flag has been set for the device > > already, the

Re: [PATCH] PM / core: Clear the direct_complete flag on errors

2018-10-04 Thread Ulf Hansson
On 4 October 2018 at 15:59, Alan Cooper wrote: >> On 4 October 2018 at 11:08, Rafael J. Wysocki wrote: >> > From: Rafael J. Wysocki >> > >> > If __device_suspend() returns early on an error or pending wakeup >> > and the power.direct_complete flag has been set for the device >> > already, the

Re: [PATCH] PM / core: Clear the direct_complete flag on errors

2018-10-04 Thread Ulf Hansson
On 4 October 2018 at 15:59, Alan Cooper wrote: >> On 4 October 2018 at 11:08, Rafael J. Wysocki wrote: >> > From: Rafael J. Wysocki >> > >> > If __device_suspend() returns early on an error or pending wakeup >> > and the power.direct_complete flag has been set for the device >> > already, the

Re: [PATCH] PM / core: Clear the direct_complete flag on errors

2018-10-04 Thread Alan Cooper
> On 4 October 2018 at 11:08, Rafael J. Wysocki wrote: > > From: Rafael J. Wysocki > > > > If __device_suspend() returns early on an error or pending wakeup > > and the power.direct_complete flag has been set for the device > > already, the subsequent device_resume() will be confused by it > >

Re: [PATCH] PM / core: Clear the direct_complete flag on errors

2018-10-04 Thread Alan Cooper
> On 4 October 2018 at 11:08, Rafael J. Wysocki wrote: > > From: Rafael J. Wysocki > > > > If __device_suspend() returns early on an error or pending wakeup > > and the power.direct_complete flag has been set for the device > > already, the subsequent device_resume() will be confused by it > >

Re: [PATCH] PM / core: Clear the direct_complete flag on errors

2018-10-04 Thread Ulf Hansson
On 4 October 2018 at 11:08, Rafael J. Wysocki wrote: > From: Rafael J. Wysocki > > If __device_suspend() returns early on an error or pending wakeup > and the power.direct_complete flag has been set for the device > already, the subsequent device_resume() will be confused by it > and it will

Re: [PATCH] PM / core: Clear the direct_complete flag on errors

2018-10-04 Thread Ulf Hansson
On 4 October 2018 at 11:08, Rafael J. Wysocki wrote: > From: Rafael J. Wysocki > > If __device_suspend() returns early on an error or pending wakeup > and the power.direct_complete flag has been set for the device > already, the subsequent device_resume() will be confused by it > and it will

[PATCH] PM / core: Clear the direct_complete flag on errors

2018-10-04 Thread Rafael J. Wysocki
From: Rafael J. Wysocki If __device_suspend() returns early on an error or pending wakeup and the power.direct_complete flag has been set for the device already, the subsequent device_resume() will be confused by it and it will call pm_runtime_enable() incorrectly, as runtime PM has not been

[PATCH] PM / core: Clear the direct_complete flag on errors

2018-10-04 Thread Rafael J. Wysocki
From: Rafael J. Wysocki If __device_suspend() returns early on an error or pending wakeup and the power.direct_complete flag has been set for the device already, the subsequent device_resume() will be confused by it and it will call pm_runtime_enable() incorrectly, as runtime PM has not been