summaryrefslogtreecommitdiff
path: root/include/uapi/linux
diff options
context:
space:
mode:
authorPerry Yuan <perry.yuan@amd.com>2026-02-08 19:42:07 +0300
committerAlex Deucher <alexander.deucher@amd.com>2026-05-11 22:55:56 +0300
commitdd61e27535a6f5cfb32a847b282d2e3d5aebf46f (patch)
tree2014c59f8faf39adde7a8c99a53e98d333b6b2eb /include/uapi/linux
parentd51a0439358d4eacd8beb39df619998d8340d232 (diff)
downloadlinux-dd61e27535a6f5cfb32a847b282d2e3d5aebf46f.tar.xz
drm/amdkfd: Add PTL control IOCTL Option and unify refcount logic
Introduce a new IOCTL option to allow userspace explicit control over the Peak Tops Limiter (PTL) state for profiling Link: https://github.com/ROCm/rocm-systems/tree/develop/projects/rocprofiler-sdk Signed-off-by: Perry Yuan <perry.yuan@amd.com> Reviewed-by: Yifan Zhang <yifan1.zhang@amd.com> Acked-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'include/uapi/linux')
-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 cc3ed0765c83..1a94d512df35 100644
--- a/include/uapi/linux/kfd_ioctl.h
+++ b/include/uapi/linux/kfd_ioctl.h
@@ -1562,6 +1562,7 @@ struct kfd_ioctl_dbg_trap_args {
enum kfd_profiler_ops {
KFD_IOC_PROFILER_PMC = 0,
KFD_IOC_PROFILER_VERSION = 2,
+ KFD_IOC_PROFILER_PTL_CONTROL = 3,
};
/**
@@ -1573,10 +1574,16 @@ struct kfd_ioctl_pmc_settings {
__u32 perfcount_enable; /* Force Perfcount Enable for queues on GPU */
};
+struct kfd_ioctl_ptl_control {
+ __u32 gpu_id; /* user_gpu_id */
+ __u32 enable; /* set 1 to enable PTL, set 0 to disable PTL */
+};
+
struct kfd_ioctl_profiler_args {
__u32 op; /* kfd_profiler_op */
union {
struct kfd_ioctl_pmc_settings pmc;
+ struct kfd_ioctl_ptl_control ptl;
__u32 version; /* KFD_IOC_PROFILER_VERSION_NUM */
};
};