On Tue, 2009-02-03 at 22:33 -0800, Eric Anholt wrote: > The basic problem was > mmap_sem (do_mmap()) -> struct_mutex (drm_gem_mmap()) > struct_mutex (i915_gem_execbuffer()) -> mmap_sem (copy_from/to_user()) > > We have plenty of places where we want to hold device state the same > (struct_mutex) while we move a non-trivial amount of data > (copy_from/to_user()), such as i915_gem_pwrite(). Solve this by moving the > one thing that needed struct_mutex with mmap_sem held to using a lock to cover > just those data structures (offset hash and offset manager).
Sadly, this does not eliminate this warning: lt-cairo-perf/2456 is trying to acquire lock: (&dev->struct_mutex){--..}, at: [<c02485ed>] i915_gem_fault+0x48/0x128 but task is already holding lock: (&mm->mmap_sem){----}, at: [<c010f693>] do_page_fault+0x1a4/0x595 which appears to be due to a page fault whilst copying the user relocations in i915_gem_object_pin_and_relocate(). -ickle ------------------------------------------------------------------------------ Create and Deploy Rich Internet Apps outside the browser with Adobe(R)AIR(TM) software. With Adobe AIR, Ajax developers can use existing skills and code to build responsive, highly engaging applications that combine the power of local resources and data with the reach of the web. Download the Adobe AIR SDK and Ajax docs to start building applications today-http://p.sf.net/sfu/adobe-com -- _______________________________________________ Dri-devel mailing list Dri-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/dri-devel