summaryrefslogtreecommitdiff
path: root/sys/dev/pci/drm/amd/amdgpu/amdgpu_umc.h
diff options
context:
space:
mode:
Diffstat (limited to 'sys/dev/pci/drm/amd/amdgpu/amdgpu_umc.h')
-rw-r--r--sys/dev/pci/drm/amd/amdgpu/amdgpu_umc.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/sys/dev/pci/drm/amd/amdgpu/amdgpu_umc.h b/sys/dev/pci/drm/amd/amdgpu/amdgpu_umc.h
index 18381449365..bda4438c392 100644
--- a/sys/dev/pci/drm/amd/amdgpu/amdgpu_umc.h
+++ b/sys/dev/pci/drm/amd/amdgpu/amdgpu_umc.h
@@ -22,6 +22,11 @@
#define __AMDGPU_UMC_H__
/*
+ * (addr / 256) * 4096, the higher 26 bits in ErrorAddr
+ * is the index of 4KB block
+ */
+#define ADDR_OF_4KB_BLOCK(addr) (((addr) & ~0xffULL) << 4)
+/*
* (addr / 256) * 8192, the higher 26 bits in ErrorAddr
* is the index of 8KB block
*/