• C
    drm/i915: Disable pagefaults along execbuffer relocation fast path · d4aeee77
    Chris Wilson 提交于
    Along the fast path for relocation handling, we attempt to copy directly
    from the user data structures whilst holding our mutex. This causes
    lockdep to warn about circular lock dependencies if we need to pagefault
    the user pages. [Since when handling a page fault on a mmapped bo, we
    need to acquire the struct mutex whilst already holding the mm
    semaphore, it is then verboten to acquire the mm semaphore when already
    holding the struct mutex. The likelihood of the user passing in the
    relocations contained in a GTT mmaped bo is low, but conceivable for
    extreme pathology.] In order to force the mm to return EFAULT rather
    than handle the pagefault, we therefore need to disable pagefaults
    across the relocation fast path.
    Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
    Cc: stable@kernel.org
    Reviewed-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
    d4aeee77
i915_gem_execbuffer.c 35.6 KB