[PATCH 4/5] drm/amd/amdgpu: L1 Policy(4/5) - removed SPI_GDBG_TRAP_CONFIG from VF
Jane Jian
Jane.Jian at amd.com
Fri Jan 3 09:47:43 UTC 2020
From: Zhigang Luo <zhigang.luo at amd.com>
Signed-off-by: Zhigang Luo <zhigang.luo at amd.com>
Signed-off-by: Jane Jian <jane.jian at amd.com>
---
drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c b/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c
index 35384f543664..bf02ca198283 100644
--- a/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c
@@ -2252,6 +2252,19 @@ static void gfx_v9_0_init_compute_vmid(struct amdgpu_device *adev)
WREG32_SOC15_OFFSET(GC, 0, mmGDS_GWS_VMID0, i, 0);
WREG32_SOC15_OFFSET(GC, 0, mmGDS_OA_VMID0, i, 0);
}
+
+ if (!amdgpu_sriov_vf(adev)) {
+ data = 0;
+ data = REG_SET_FIELD(data, SPI_GDBG_TRAP_CONFIG,
+ VMID_SEL, trap_config_vmid_mask);
+ data = REG_SET_FIELD(data, SPI_GDBG_TRAP_CONFIG,
+ TRAP_EN, 1);
+ WREG32(SOC15_REG_OFFSET(GC, 0, mmSPI_GDBG_TRAP_CONFIG), data);
+
+ WREG32(SOC15_REG_OFFSET(GC, 0, mmSPI_GDBG_TRAP_DATA0), 0);
+ WREG32(SOC15_REG_OFFSET(GC, 0, mmSPI_GDBG_TRAP_DATA1), 0);
+ WREG32(SOC15_REG_OFFSET(GC, 0, mmSPI_GDBG_TRAP_MASK), 0);
+ }
}
static void gfx_v9_0_init_gds_vmid(struct amdgpu_device *adev)
--
2.17.1
More information about the amd-gfx
mailing list