]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
drm/xe/svm: Serialize migration to device if racing
authorThomas Hellström <thomas.hellstrom@linux.intel.com>
Fri, 19 Dec 2025 11:33:20 +0000 (12:33 +0100)
committerThomas Hellström <thomas.hellstrom@linux.intel.com>
Tue, 23 Dec 2025 09:00:49 +0000 (10:00 +0100)
commit0620837490e0401cb4e9965a1e0c462dbff1c97b
tree7d48d67bdc3a5796b4ebc8d86346f735c1a3fde7
parentec265e1f1cfcce6b03167868cadebf2d831e52b5
drm/xe/svm: Serialize migration to device if racing

Introduce an rw-semaphore to serialize migration to device if
it's likely that migration races with another device migration
of the same CPU address space range.
This is a temporary fix to attempt to mitigate a livelock that
might happen if many devices try to migrate a range at the same
time, and it affects only devices using the xe driver.
A longer term fix is probably improvements in the core mm
migration layer.

Suggested-by: Matthew Brost <matthew.brost@intel.com>
Signed-off-by: Thomas Hellström <thomas.hellstrom@linux.intel.com>
Reviewed-by: Matthew Brost <matthew.brost@intel.com>
Link: https://patch.msgid.link/20251219113320.183860-25-thomas.hellstrom@linux.intel.com
drivers/gpu/drm/xe/xe_svm.c