[Intel-gfx] [RFC 10/14] drm/i915/pxp: Enable PXP power management
Daniele Ceraolo Spurio
daniele.ceraolospurio at intel.com
Mon Feb 8 18:33:33 UTC 2021
On 2/6/2021 5:08 AM, Chris Wilson wrote:
> Quoting Chris Wilson (2021-02-06 13:06:05)
>> Quoting Daniele Ceraolo Spurio (2021-02-06 02:09:21)
>>> + if (!ret) {
>>> + ret = wait_for(!pxp->termination_in_progress, 10);
>> This only works by chance. The compiler doesn't even have to reload the
>> variable. See struct completion.
This was a last minute addition when I was told that waiting on the
in_play state change was not enough to guarantee full invalidation and I
admit I didn't fully think it through because I want to get the RFC out.
> It appears we already have a ready made one with the termination
> i915_request. But that will require RCU pointer management...
> -Chris
I've tried to keep this decoupled from the request because after the
request completion there is an MMIO write and only after that we start
waiting for the interrupt. I'll go with a struct completion.
Daniele
More information about the Intel-gfx
mailing list