summaryrefslogtreecommitdiff
path: root/include/uapi/drm/xe_drm.h
diff options
context:
space:
mode:
authorAshutosh Dixit <ashutosh.dixit@intel.com>2024-06-17 18:46:00 -0700
committerAshutosh Dixit <ashutosh.dixit@intel.com>2024-06-18 12:40:35 -0700
commite936f885f1e96f59d9d05fb6cb5a02b9b9b88a05 (patch)
treea735968fbc92042866350295c6ad0b31f3623a0a /include/uapi/drm/xe_drm.h
parent1db9a9dc90aece0803a26a711b52a9492faefab7 (diff)
downloadlwn-e936f885f1e96f59d9d05fb6cb5a02b9b9b88a05.tar.gz
lwn-e936f885f1e96f59d9d05fb6cb5a02b9b9b88a05.zip
drm/xe/oa/uapi: Expose OA stream fd
The OA stream open perf op returns an fd with its own file_operations for the newly initialized OA stream. These file_operations allow userspace to enable or disable the stream, as well as apply a different metric configuration for the OA stream. Userspace can also poll for data availability. OA stream initialization is completed in this commit by enabling the OA stream. When sampling is enabled this starts a hrtimer which periodically checks for data availablility. v2: Use stream properties for stream reconfiguration with DRM_XE_PERF_IOCTL_CONFIG v3: Hold runtime_pm reference across oa buffer alloc/free v4: Fix 32 bit build Acked-by: Rodrigo Vivi <rodrigo.vivi@intel.com> Acked-by: José Roberto de Souza <jose.souza@intel.com> Reviewed-by: Umesh Nerlige Ramappa <umesh.nerlige.ramappa@intel.com> Signed-off-by: Ashutosh Dixit <ashutosh.dixit@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20240618014609.3233427-9-ashutosh.dixit@intel.com
Diffstat (limited to 'include/uapi/drm/xe_drm.h')
-rw-r--r--include/uapi/drm/xe_drm.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/uapi/drm/xe_drm.h b/include/uapi/drm/xe_drm.h
index 307409f968e2..1e09f786b3e6 100644
--- a/include/uapi/drm/xe_drm.h
+++ b/include/uapi/drm/xe_drm.h
@@ -1478,6 +1478,10 @@ enum drm_xe_oa_format_type {
* @drm_xe_user_extension base.name set to @DRM_XE_OA_EXTENSION_SET_PROPERTY.
* @param field in struct @drm_xe_perf_param points to the first
* @drm_xe_ext_set_property struct.
+ *
+ * Exactly the same mechanism is also used for stream reconfiguration using
+ * the @DRM_XE_PERF_IOCTL_CONFIG perf fd ioctl, though only a subset of
+ * properties below can be specified for stream reconfiguration.
*/
enum drm_xe_oa_property_id {
#define DRM_XE_OA_EXTENSION_SET_PROPERTY 0