summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c
diff options
context:
space:
mode:
authorKevin Wang <kevin1.wang@amd.com>2021-03-02 15:54:00 +0800
committerAlex Deucher <alexander.deucher@amd.com>2021-03-03 10:51:37 -0500
commit43fb6c195dee0f4d6844ec2936257f99473fa057 (patch)
tree7d5fbafa5ad3ab6d10d4ce09a1b6bd566d02725b /drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c
parente7bdf00e0040e6092305397831ea58fc2107c5d6 (diff)
downloadlinux-stable-43fb6c195dee0f4d6844ec2936257f99473fa057.tar.gz
linux-stable-43fb6c195dee0f4d6844ec2936257f99473fa057.tar.bz2
linux-stable-43fb6c195dee0f4d6844ec2936257f99473fa057.zip
drm/amdgpu: fix parameter error of RREG32_PCIE() in amdgpu_regs_pcie
the register offset isn't needed division by 4 to pass RREG32_PCIE() Signed-off-by: Kevin Wang <kevin1.wang@amd.com> Reviewed-by: Lijo Lazar <lijo.lazar@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c
index a4f492b79f86..bcaf271b39bf 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c
@@ -317,7 +317,7 @@ static ssize_t amdgpu_debugfs_regs_pcie_read(struct file *f, char __user *buf,
while (size) {
uint32_t value;
- value = RREG32_PCIE(*pos >> 2);
+ value = RREG32_PCIE(*pos);
r = put_user(value, (uint32_t *)buf);
if (r) {
pm_runtime_mark_last_busy(adev_to_drm(adev)->dev);
@@ -384,7 +384,7 @@ static ssize_t amdgpu_debugfs_regs_pcie_write(struct file *f, const char __user
return r;
}
- WREG32_PCIE(*pos >> 2, value);
+ WREG32_PCIE(*pos, value);
result += 4;
buf += 4;