[PATCH 8/9] drm/amdgpu: init mc base address for zfb

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Hawking Zhang <Hawking.Zhang@xxxxxxx>

Change-Id: I89b9ff36b62eb685a9e2d87e2058d200b92f5034
Signed-off-by: Hawking Zhang <Hawking.Zhang at amd.com>
Acked-by: John Bridgman <john.bridgman at amd.com>
Reviewed-by: Alex Deucher <alexander.deucher at amd.com>
---
 drivers/gpu/drm/amd/amdgpu/mmhub_v1_0.c | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/mmhub_v1_0.c b/drivers/gpu/drm/amd/amdgpu/mmhub_v1_0.c
index b539fd1..c56ab47 100644
--- a/drivers/gpu/drm/amd/amdgpu/mmhub_v1_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/mmhub_v1_0.c
@@ -38,9 +38,12 @@
 u64 mmhub_v1_0_get_fb_location(struct amdgpu_device *adev)
 {
 	u64 base = RREG32_SOC15(MMHUB, 0, mmMC_VM_FB_LOCATION_BASE);
-
-	base &= MC_VM_FB_LOCATION_BASE__FB_BASE_MASK;
-	base <<= 24;
+	if (adev->gmc.enable_zfb) {
+		base = 0xF400000000ULL;
+	} else {
+		base &= MC_VM_FB_LOCATION_BASE__FB_BASE_MASK;
+		base <<= 24;
+	}
 
 	return base;
 }
-- 
2.7.4



[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux