drm/radeon: hold reference to fences in radeon_sa_bo_new
Orabug:
23330856
[ Upstream commit
f6ff4f67cdf8455d0a4226eeeaf5af17c37d05eb ]
An arbitrary amount of time can pass between spin_unlock and
radeon_fence_wait_any, so we need to ensure that nobody frees the
fences from under us.
Based on the analogous fix for amdgpu.
Signed-off-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Cc: stable@vger.kernel.org
Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
(cherry picked from commit
7071cc9b4f9d4fd6dee20bb8dd760a8f9e1ceec7)
Signed-off-by: Dan Duval <dan.duval@oracle.com>