[Intel-gfx] [PATCH] drm/i915: paper over missed irq issues with force wake vodoo

Keith Packard keithp at keithp.com
Sun Jan 15 07:35:44 CET 2012


On Sat, 14 Jan 2012 13:12:07 +0100, Daniel Vetter <daniel at ffwll.ch> wrote:

> I think that race is air-tight with your patch to rework the reset code
> already. But better safe than sorry. And as I've said a good cleanup
> anyway.

Sounds good. I like clearer code, especially when it doesn't cost
performance. I think I'd like my version in -fixes so that we don't
change anything with -next; no reason to have two slightly different
versions out there in case one (or the other) is broken?

> One of the reasons Chris originally shot down Ben's forcewake patches
> which protected everything with a spinlock (i.e. also writes) is the
> overhead. And writes to advance the ring are actually rather common. Iirc
> Chris even wrote a patch to cut down on the overhead by caching the fifo
> count. So I think we actually want this asymmetry in locking for
> performance reasons.

Ah, that's a good reason to use different locking for each path
then. Suitable documentation, and a WARN_ON in the write path to check
for the struct_mutex should suffice to prevent mistakes in the future.

-- 
keith.packard at intel.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 827 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/intel-gfx/attachments/20120114/4cbcfc00/attachment.sig>


More information about the Intel-gfx mailing list