]> www.infradead.org Git - linux.git/commit
drm/xe/ufence: Prefetch ufence addr to catch bogus address
authorNirmoy Das <nirmoy.das@intel.com>
Wed, 16 Oct 2024 08:23:03 +0000 (10:23 +0200)
committerLucas De Marchi <lucas.demarchi@intel.com>
Thu, 24 Oct 2024 17:42:52 +0000 (12:42 -0500)
commit9c1813b3253480b30604c680026c7dc721ce86d1
tree83c3878d118b69da74ad2adb1c22048b755d900b
parent69418db678567bdf9a4992c83d448da462ffa78c
drm/xe/ufence: Prefetch ufence addr to catch bogus address

access_ok() only checks for addr overflow so also try to read the addr
to catch invalid addr sent from userspace.

Link: https://gitlab.freedesktop.org/drm/xe/kernel/-/issues/1630
Cc: Francois Dugast <francois.dugast@intel.com>
Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Cc: Matthew Auld <matthew.auld@intel.com>
Cc: Matthew Brost <matthew.brost@intel.com>
Reviewed-by: Matthew Brost <matthew.brost@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20241016082304.66009-2-nirmoy.das@intel.com
Signed-off-by: Nirmoy Das <nirmoy.das@intel.com>
(cherry picked from commit 9408c4508483ffc60811e910a93d6425b8e63928)
Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com>
drivers/gpu/drm/xe/xe_sync.c