]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915: reference counted forcewake
authorBen Widawsky <ben@bwidawsk.net>
Mon, 25 Apr 2011 18:23:07 +0000 (11:23 -0700)
committerKeith Packard <keithp@keithp.com>
Tue, 10 May 2011 20:56:46 +0000 (13:56 -0700)
commit9031f4c604b5b3b2398cd4e6d55e2680d8e26bc1
tree3d3961db5e3d1821bd68c3c09365f9e557e61d55
parentec78d5ba10f7965fb0daa3fdf0cb67f6b3004f9b
drm/i915: reference counted forcewake

Provide a reference count to track the forcewake state of the GPU and
give a safe mechanism for userspace to wake the GT. This also potentially
saves a UC read if the GT is known to be awake already.

The reference count is atomic, but the register access and hardware wake
sequence is protected by struct_mutex.

Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
drivers/gpu/drm/i915/i915_debugfs.c
drivers/gpu/drm/i915/i915_drv.c
drivers/gpu/drm/i915/i915_drv.h
drivers/gpu/drm/i915/i915_irq.c
drivers/gpu/drm/i915/intel_display.c