[Intel-gfx] enabling forcewake from userspace

Ben Widawsky ben at bwidawsk.net
Sat Mar 26 20:27:17 CET 2011


On Sat, Mar 26, 2011 at 05:18:57PM +0000, Chris Wilson wrote:
> 
> The GPU is definitely allowed to be powered down whilst the CPU is
> servicing an interrupt. ;-) I take your point though that the current
> method is not interrupt safe. However, we should not be doing such work
> from an interrupt handler - if need be all the actual work is kicked off
> from a workqueue.
> 
> Something we need to keep an eye on, but not a problem today. *touch wood*

Efficiency aside, workqueue suffers from the same hazard. Unless the
assumption is struct_mutex (or something similar) is protecting all
register access which are in the power wells that can get disabled. My
quick inspection of the code shows this is probably true, but in this
case I'd suggest a WARN_ON or something in force_wake_get(), because
this would be a really hard bug to track down.

By the way, I think we currently have potential problem with
kick_ring().  Although given when this occurs it is probably a DON'T
CARE.

> -Chris
> 
Ben



More information about the Intel-gfx mailing list