summaryrefslogtreecommitdiffstats
path: root/include/uapi/linux/kfd_ioctl.h
diff options
context:
space:
mode:
authorOak Zeng2019-04-04 22:47:34 +0200
committerAlex Deucher2019-05-24 19:20:47 +0200
commit88807dc8d573c0f718d0d26f592f212c5a487cf0 (patch)
tree41975ffccdca07911be7d3b87a08bfb69082da76 /include/uapi/linux/kfd_ioctl.h
parentdrm/amd/powerplay: add helper function to get smu firmware & if version (diff)
downloadkernel-qcow2-linux-88807dc8d573c0f718d0d26f592f212c5a487cf0.tar.gz
kernel-qcow2-linux-88807dc8d573c0f718d0d26f592f212c5a487cf0.tar.xz
kernel-qcow2-linux-88807dc8d573c0f718d0d26f592f212c5a487cf0.zip
drm/amdgpu: Remap hdp coherency registers
Remap HDP_MEM_COHERENCY_FLUSH_CNTL and HDP_REG_COHERENCY_FLUSH_CNTL to an empty page in mmio space. We will later map this page to process space so application can flush hdp. This can't be done properly at those registers' original location because it will expose more than desired registers to process space. v2: Use explicit register hole location v3: Moved remapped hdp registers into adev struct v4: Use more generic name for remapped page Expose register offset in kfd_ioctl.h v5: Move hdp register remap function to nbio ip function v6: Fixed operator precedence issue and other bugs Signed-off-by: Oak Zeng <Oak.Zeng@amd.com> Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'include/uapi/linux/kfd_ioctl.h')
-rw-r--r--include/uapi/linux/kfd_ioctl.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/uapi/linux/kfd_ioctl.h b/include/uapi/linux/kfd_ioctl.h
index dc067ed0b72d..bb1b4280f53d 100644
--- a/include/uapi/linux/kfd_ioctl.h
+++ b/include/uapi/linux/kfd_ioctl.h
@@ -426,6 +426,13 @@ struct kfd_ioctl_import_dmabuf_args {
__u32 dmabuf_fd; /* to KFD */
};
+/* Register offset inside the remapped mmio page
+ */
+enum kfd_mmio_remap {
+ KFD_MMIO_REMAP_HDP_MEM_FLUSH_CNTL = 0,
+ KFD_MMIO_REMAP_HDP_REG_FLUSH_CNTL = 4,
+};
+
#define AMDKFD_IOCTL_BASE 'K'
#define AMDKFD_IO(nr) _IO(AMDKFD_IOCTL_BASE, nr)
#define AMDKFD_IOR(nr, type) _IOR(AMDKFD_IOCTL_BASE, nr, type)