aboutsummaryrefslogtreecommitdiffstats
path: root/common/recipes-kernel/linux/linux-yocto-4.19.8/1471-drm-amdgpu-use-REG32_PCIE-wrapper-instead-for-psp.patch
diff options
context:
space:
mode:
Diffstat (limited to 'common/recipes-kernel/linux/linux-yocto-4.19.8/1471-drm-amdgpu-use-REG32_PCIE-wrapper-instead-for-psp.patch')
-rw-r--r--common/recipes-kernel/linux/linux-yocto-4.19.8/1471-drm-amdgpu-use-REG32_PCIE-wrapper-instead-for-psp.patch32
1 files changed, 32 insertions, 0 deletions
diff --git a/common/recipes-kernel/linux/linux-yocto-4.19.8/1471-drm-amdgpu-use-REG32_PCIE-wrapper-instead-for-psp.patch b/common/recipes-kernel/linux/linux-yocto-4.19.8/1471-drm-amdgpu-use-REG32_PCIE-wrapper-instead-for-psp.patch
new file mode 100644
index 00000000..3194e59e
--- /dev/null
+++ b/common/recipes-kernel/linux/linux-yocto-4.19.8/1471-drm-amdgpu-use-REG32_PCIE-wrapper-instead-for-psp.patch
@@ -0,0 +1,32 @@
+From 217ab0b8137687bd4a1206f632b31483f1211578 Mon Sep 17 00:00:00 2001
+From: Huang Rui <ray.huang@amd.com>
+Date: Mon, 25 Feb 2019 15:02:44 +0800
+Subject: [PATCH 1471/2940] drm/amdgpu: use REG32_PCIE wrapper instead for psp
+
+This patch uses REG32_PCIE wrapper instead of writting pci_index2 and reading
+pci_data2 for psp. This sequence should be protected by pcie_idx_lock.
+
+Signed-off-by: Huang Rui <ray.huang@amd.com>
+Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
+---
+ drivers/gpu/drm/amd/amdgpu/psp_v3_1.c | 4 +---
+ 1 file changed, 1 insertion(+), 3 deletions(-)
+
+diff --git a/drivers/gpu/drm/amd/amdgpu/psp_v3_1.c b/drivers/gpu/drm/amd/amdgpu/psp_v3_1.c
+index c63de945c021..0487e3a4e9e7 100644
+--- a/drivers/gpu/drm/amd/amdgpu/psp_v3_1.c
++++ b/drivers/gpu/drm/amd/amdgpu/psp_v3_1.c
+@@ -500,9 +500,7 @@ static bool psp_v3_1_smu_reload_quirk(struct psp_context *psp)
+ struct amdgpu_device *adev = psp->adev;
+ uint32_t reg;
+
+- reg = smnMP1_FIRMWARE_FLAGS | 0x03b00000;
+- WREG32_SOC15(NBIO, 0, mmPCIE_INDEX2, reg);
+- reg = RREG32_SOC15(NBIO, 0, mmPCIE_DATA2);
++ reg = RREG32_PCIE(smnMP1_FIRMWARE_FLAGS | 0x03b00000);
+ return (reg & MP1_FIRMWARE_FLAGS__INTERRUPTS_ENABLED_MASK) ? true : false;
+ }
+
+--
+2.17.1
+