[PATCH 6.12 121/189] drm/amdgpu: Add a lock when accessing the buddy trim function