[PATCH 6.11 235/558] drm/amdgpu: add list empty check to avoid null pointer issue