Contrary to the discussion on IRC, I have decided not to add config.mutex as part of the warning criteria. Upon further thought, it just seemed incorrect to me. This patch series implies that all register reads which may require a forcewake must now hold struct_mutex, ie. make struct_mutex more global. The alternative is to invent a new lock for forcewake which must be acquired prior to said register reads.
I know, that sucks. It has implications on non-SNB platforms, and that is exactly what I was hoping to avoid. The current code is dangerous. If two threads need register reads requiring forcewake but aren't protected by the same mutex, it will lead to unpredictable register reads (I can't think of a case where it will actually work correctly). So once again, I expect this patch to potentially generate a lot of warnings, but I consider all of those warnings to be serious bugs for SNB. If anyone has clever ideas on how to handle this outside of what I've already mentioned, please let me know. I expect ongoing patches to fix these issues as they come up. Ben _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/intel-gfx