aboutsummaryrefslogtreecommitdiffstats
path: root/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/3563-drm-amdgpu-set-adev-num_vmhubs-for-gmc6-7-8.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/3563-drm-amdgpu-set-adev-num_vmhubs-for-gmc6-7-8.patch')
-rw-r--r--meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/3563-drm-amdgpu-set-adev-num_vmhubs-for-gmc6-7-8.patch58
1 files changed, 58 insertions, 0 deletions
diff --git a/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/3563-drm-amdgpu-set-adev-num_vmhubs-for-gmc6-7-8.patch b/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/3563-drm-amdgpu-set-adev-num_vmhubs-for-gmc6-7-8.patch
new file mode 100644
index 00000000..cc163afa
--- /dev/null
+++ b/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/3563-drm-amdgpu-set-adev-num_vmhubs-for-gmc6-7-8.patch
@@ -0,0 +1,58 @@
+From 1a4d6534b2c2625d93548988ce7354ce71e832c8 Mon Sep 17 00:00:00 2001
+From: Alex Deucher <alexander.deucher@amd.com>
+Date: Fri, 23 Aug 2019 09:42:33 -0500
+Subject: [PATCH 3563/4256] drm/amdgpu: set adev->num_vmhubs for gmc6,7,8
+
+So that we properly handle them on older asics.
+
+Fixes: 3ff985485b29 ("drm/amdgpu: Export function to flush TLB of specific vm hub")
+Reviewed-by: Xiaojie Yuan <xiaojie.yuan@amd.com>
+Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
+---
+ drivers/gpu/drm/amd/amdgpu/gmc_v6_0.c | 2 ++
+ drivers/gpu/drm/amd/amdgpu/gmc_v7_0.c | 2 ++
+ drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c | 2 ++
+ 3 files changed, 6 insertions(+)
+
+diff --git a/drivers/gpu/drm/amd/amdgpu/gmc_v6_0.c b/drivers/gpu/drm/amd/amdgpu/gmc_v6_0.c
+index 2edb7fc84398..cdcac811a85f 100644
+--- a/drivers/gpu/drm/amd/amdgpu/gmc_v6_0.c
++++ b/drivers/gpu/drm/amd/amdgpu/gmc_v6_0.c
+@@ -839,6 +839,8 @@ static int gmc_v6_0_sw_init(void *handle)
+ int dma_bits;
+ struct amdgpu_device *adev = (struct amdgpu_device *)handle;
+
++ adev->num_vmhubs = 1;
++
+ if (adev->flags & AMD_IS_APU) {
+ adev->gmc.vram_type = AMDGPU_VRAM_TYPE_UNKNOWN;
+ } else {
+diff --git a/drivers/gpu/drm/amd/amdgpu/gmc_v7_0.c b/drivers/gpu/drm/amd/amdgpu/gmc_v7_0.c
+index 655bc4690958..26508a767582 100644
+--- a/drivers/gpu/drm/amd/amdgpu/gmc_v7_0.c
++++ b/drivers/gpu/drm/amd/amdgpu/gmc_v7_0.c
+@@ -960,6 +960,8 @@ static int gmc_v7_0_sw_init(void *handle)
+ int dma_bits;
+ struct amdgpu_device *adev = (struct amdgpu_device *)handle;
+
++ adev->num_vmhubs = 1;
++
+ if (adev->flags & AMD_IS_APU) {
+ adev->gmc.vram_type = AMDGPU_VRAM_TYPE_UNKNOWN;
+ } else {
+diff --git a/drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c b/drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c
+index a27a5ae75438..43ee4bc47f43 100644
+--- a/drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c
++++ b/drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c
+@@ -1085,6 +1085,8 @@ static int gmc_v8_0_sw_init(void *handle)
+ int dma_bits;
+ struct amdgpu_device *adev = (struct amdgpu_device *)handle;
+
++ adev->num_vmhubs = 1;
++
+ if (adev->flags & AMD_IS_APU) {
+ adev->gmc.vram_type = AMDGPU_VRAM_TYPE_UNKNOWN;
+ } else {
+--
+2.17.1
+