diff options
author | Daniel Vetter <daniel.vetter@ffwll.ch> | 2021-06-11 21:15:08 +0200 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2024-01-08 14:01:49 +0100 |
commit | 4587f1482eeb54fb0c7f2092da0440d3912c939c (patch) | |
tree | d5fa44d21a719538ef025ed2bc812cf7eb31ebc5 | |
parent | dd7839641f51618aad86327bcadaf7ebcea47fa5 (diff) |
drm/i915/eb: Replace user_access_begin by user_write_access_begin
Similar to
commit b44f687386875b714dae2afa768e73401e45c21c
Author: Christophe Leroy <christophe.leroy@c-s.fr>
Date: Fri Apr 3 07:20:52 2020 +0000
drm/i915/gem: Replace user_access_begin by user_write_access_begin
We only do unsafe_put_user, so no read access needed.
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
Cc: Jon Bloomfield <jon.bloomfield@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: "Thomas Hellström" <thomas.hellstrom@linux.intel.com>
Cc: Matthew Auld <matthew.auld@intel.com>
Cc: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Cc: Dave Airlie <airlied@redhat.com>
Cc: Jason Ekstrand <jason@jlekstrand.net>
Cc: Christophe Leroy <christophe.leroy@c-s.fr>
Cc: Kees Cook <keescook@chromium.org>
Cc: Michael Ellerman <mpe@ellerman.id.au>
-rw-r--r-- | drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c b/drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c index bc6b5eec3f31..3753b9661f32 100644 --- a/drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c +++ b/drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c @@ -1709,14 +1709,14 @@ static int eb_copy_relocations(const struct i915_execbuffer *eb) * happened we would make the mistake of assuming that the * relocations were valid. */ - if (!user_access_begin(urelocs, size)) + if (!user_write_access_begin(urelocs, size)) goto end; for (copied = 0; copied < nreloc; copied++) unsafe_put_user(-1, &urelocs[copied].presumed_offset, end_user); - user_access_end(); + user_write_access_end(); eb->exec[i].relocs_ptr = (uintptr_t)relocs; } |