]> git.ipfire.org Git - thirdparty/linux.git/commit
drm/amdkfd: Check for pdd drm file first in CRIU restore path
authorDavid Francis <David.Francis@amd.com>
Thu, 14 May 2026 14:31:20 +0000 (10:31 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 27 May 2026 15:59:24 +0000 (11:59 -0400)
commit6842b6a4b72da9b2906ffc5ca9d846ace2c54c14
treef6cf5fa7301924295869d1bac0081454e752ef37
parent0fb4a8e64a9db74eeda8da7d0b78985392ae483b
drm/amdkfd: Check for pdd drm file first in CRIU restore path

CRIU restore ioctls are meant to be called by CRIU with no
existing drm file. There's an error path
for if the drm file unexpectedly exists. It was positioned so
it was missing a fput(drm_file).

Do that check earlier, as soon as we have the pdd.

Signed-off-by: David Francis <David.Francis@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
(cherry picked from commit 2bab781dac78916c5cc8de76345a4102449267d7)
Cc: stable@vger.kernel.org
drivers/gpu/drm/amd/amdkfd/kfd_chardev.c