drm/amdgpu: fix amdgpu_bo_pin_restricted VRAM placing v2
authorChristian König <christian.koenig@amd.com>
Tue, 19 Jan 2016 11:48:14 +0000 (12:48 +0100)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 22 Jan 2016 15:47:48 +0000 (10:47 -0500)
commit78d0e182b6c1f5336f6e8cbb197f403276dabc7f
tree2b875c6bdd68c46ac9f2f97eba2e48975d57d04b
parent4b5ece24ce564176f8ad786ad02b681a373bc615
drm/amdgpu: fix amdgpu_bo_pin_restricted VRAM placing v2

We could pin BOs into invisible VRAM otherwise.

v2: make logic more readable as suggested by Michel

Cc: stable@vger.kernel.org
Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com> (v1)
Reviewed-by: Rex Zhu <Rex.Zhu@amd.com> (v1)
Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_object.c