drm/xe: Don't unnecessarily invoke the OOM killer on multiple binds
Multiple single-ioctl binds can be split up into multiple bind
ioctls, reducing the memory required to hold the bind array.
So rather than allowing the OOM killer to be invoked, return
-ENOMEM or -ENOBUFS to user-space to take corrective action.
v2:
- Add __GFP_NOWARN to __GFP_RETRY_MAYFAIL allocations to avoid
spamming the kernel log if a recoverable allocation fails.
Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Link: https://gitlab.freedesktop.org/drm/xe/kernel/-/issues/2701
Signed-off-by: Thomas Hellström <thomas.hellstrom@linux.intel.com>
Reviewed-by: Matthew Brost <matthew.brost@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20241031153732.164995-3-thomas.hellstrom@linux.intel.com