Merge tag 'drm-next-2024-03-13' of https://gitlab.freedesktop.org/drm/kernel
[sfrench/cifs-2.6.git] / include / uapi / drm / xe_drm.h
index bb0c8a9941164228fef069433194aa2e549a0174..538a3ac95c54fd600af86638d061cb80632a0097 100644 (file)
@@ -574,6 +574,36 @@ struct drm_xe_query_engine_cycles {
        __u64 cpu_delta;
 };
 
+/**
+ * struct drm_xe_query_uc_fw_version - query a micro-controller firmware version
+ *
+ * Given a uc_type this will return the branch, major, minor and patch version
+ * of the micro-controller firmware.
+ */
+struct drm_xe_query_uc_fw_version {
+       /** @uc_type: The micro-controller type to query firmware version */
+#define XE_QUERY_UC_TYPE_GUC_SUBMISSION 0
+       __u16 uc_type;
+
+       /** @pad: MBZ */
+       __u16 pad;
+
+       /** @branch_ver: branch uc fw version */
+       __u32 branch_ver;
+       /** @major_ver: major uc fw version */
+       __u32 major_ver;
+       /** @minor_ver: minor uc fw version */
+       __u32 minor_ver;
+       /** @patch_ver: patch uc fw version */
+       __u32 patch_ver;
+
+       /** @pad2: MBZ */
+       __u32 pad2;
+
+       /** @reserved: Reserved */
+       __u64 reserved;
+};
+
 /**
  * struct drm_xe_device_query - Input of &DRM_IOCTL_XE_DEVICE_QUERY - main
  * structure to query device information
@@ -643,6 +673,7 @@ struct drm_xe_device_query {
 #define DRM_XE_DEVICE_QUERY_HWCONFIG           4
 #define DRM_XE_DEVICE_QUERY_GT_TOPOLOGY                5
 #define DRM_XE_DEVICE_QUERY_ENGINE_CYCLES      6
+#define DRM_XE_DEVICE_QUERY_UC_FW_VERSION      7
        /** @query: The type of data to query */
        __u32 query;