Re: [PATCH] drm/amdgpu: set adev->num_vmhubs for gmc6,7,8

2019-08-24 Thread Christian König

Reviewed-by: Christian König 

Am 23.08.19 um 17:21 schrieb Yuan, Xiaojie:

Reviewed-by: Xiaojie Yuan 

BR,
Xiaojie


On Aug 23, 2019, at 10:45 PM, Alex Deucher  wrote:

So that we properly handle them on older asics.

Fixes: 3ff985485b29 ("drm/amdgpu: Export function to flush TLB of specific vm 
hub")
Signed-off-by: Alex Deucher 
---
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 564fb1ce292f..3264548e375c 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 9e6a23304fd7..cc0aa178eb2d 100644
--- a/drivers/gpu/drm/amd/amdgpu/gmc_v7_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/gmc_v7_0.c
@@ -959,6 +959,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 f7d6a07ba4e1..88f3a171452f 100644
--- a/drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c
@@ -1079,6 +1079,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.20.1

___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx


___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

Re: [PATCH] drm/amdgpu: set adev->num_vmhubs for gmc6,7,8

2019-08-23 Thread Yuan, Xiaojie
Reviewed-by: Xiaojie Yuan 

BR,
Xiaojie

> On Aug 23, 2019, at 10:45 PM, Alex Deucher  wrote:
> 
> So that we properly handle them on older asics.
> 
> Fixes: 3ff985485b29 ("drm/amdgpu: Export function to flush TLB of specific vm 
> hub")
> Signed-off-by: Alex Deucher 
> ---
> 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 564fb1ce292f..3264548e375c 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 9e6a23304fd7..cc0aa178eb2d 100644
> --- a/drivers/gpu/drm/amd/amdgpu/gmc_v7_0.c
> +++ b/drivers/gpu/drm/amd/amdgpu/gmc_v7_0.c
> @@ -959,6 +959,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 f7d6a07ba4e1..88f3a171452f 100644
> --- a/drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c
> +++ b/drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c
> @@ -1079,6 +1079,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.20.1
> 
> ___
> amd-gfx mailing list
> amd-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/amd-gfx
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx