[Intel-gfx] [PATCH v4 29/61] drm/i915: Fix pread/pwrite to work with new locking rules.

Thomas Hellström thomas.hellstrom at linux.intel.com
Mon Nov 2 10:00:19 UTC 2020


On 10/16/20 12:44 PM, Maarten Lankhorst wrote:
> We are removing obj->mm.lock, and need to take the reservation lock
> before we can pin pages. Move the pinning pages into the helper, and
> merge gtt pwrite/pread preparation and cleanup paths.
>
> The fence lock is also removed; it will conflict with fence annotations,
> because of memory allocations done when pagefaulting inside copy_*_user.
>
> Signed-off-by: Maarten Lankhorst <maarten.lankhorst at linux.intel.com>

Reviewed-by: Thomas Hellström <thomas.hellstrom at linux.intel.com>

If needed, in the future we might want to look at a way to keep the 
object lock around the short-term pinning. At least for the 
non-page-faulting case.

/Thomas




More information about the Intel-gfx mailing list