Re: [PATCH v2] PM / Runtime: Introduce pm_runtime_get_noidle

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

 



On Thu, 2015-12-10 at 01:58 +0100, Rafael J. Wysocki wrote:
> On Wednesday, December 09, 2015 06:22:19 PM Joonas Lahtinen wrote:
> > Introduce pm_runtime_get_noidle to for situations where it is not
> > desireable to touch an idling device. One use scenario is periodic
> > hangchecks performed by the drm/i915 driver which can be omitted
> > on a device in a runtime idle state.
> > 
> > v2:
> > - Fix inconsistent return value when !CONFIG_PM.
> > - Update documentation for bool return value
> > 
> > Signed-off-by: Joonas Lahtinen <joonas.lahtinen@xxxxxxxxxxxxxxx>
> > Reported-by: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx>
> > Cc: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx>
> > Cc: "Rafael J. Wysocki" <rjw@xxxxxxxxxxxxx>
> > Cc: linux-pm@xxxxxxxxxxxxxxx
> 
> Well, I don't quite see how this can be used in a non-racy way
> without doing an additional pm_runtime_resume() or something like
> that in the same code path.

We don't want to resume, that would be the whole point. We'd like to
ensure that we hold a reference _and_ the device is already active. So
AFAICS we'd need to check runtime_status == RPM_ACTIVE in addition
after taking the reference.

--Imre
_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux