diff mbox series

[6/6] drm/v3d: Deprecate the use of the Performance Counters enum

Message ID 20240508143306.2435304-8-mcanal@igalia.com (mailing list archive)
State New, archived
Headers show
Series drm/v3d: Improve Performance Counters handling | expand

Commit Message

Maíra Canal May 8, 2024, 2:30 p.m. UTC
The Performance Counters enum used to identify the index of each
performance counter and provide the total number of performance
counters (V3D_PERFCNT_NUM). But, this enum is only valid for V3D 4.2,
not for V3D 7.1.

As we implemented a new flexible structure to retrieve performance
counters information, we can deprecate this enum.

Signed-off-by: Maíra Canal <mcanal@igalia.com>
---
 include/uapi/drm/v3d_drm.h | 6 ++++++
 1 file changed, 6 insertions(+)

Comments

Iago Toral May 9, 2024, 6:14 a.m. UTC | #1
El mié, 08-05-2024 a las 11:30 -0300, Maíra Canal escribió:
> The Performance Counters enum used to identify the index of each
> performance counter and provide the total number of performance
> counters (V3D_PERFCNT_NUM). But, this enum is only valid for V3D 4.2,
> not for V3D 7.1.
> 
> As we implemented a new flexible structure to retrieve performance
> counters information, we can deprecate this enum.
> 
> Signed-off-by: Maíra Canal <mcanal@igalia.com>
> ---
>  include/uapi/drm/v3d_drm.h | 6 ++++++
>  1 file changed, 6 insertions(+)
> 
> diff --git a/include/uapi/drm/v3d_drm.h b/include/uapi/drm/v3d_drm.h
> index 0860ddb3d0b6..706b4dea1c45 100644
> --- a/include/uapi/drm/v3d_drm.h
> +++ b/include/uapi/drm/v3d_drm.h
> @@ -603,6 +603,12 @@ struct drm_v3d_submit_cpu {
>  	__u64 extensions;
>  };
>  
> +/* The performance counters index represented by this enum are
> deprecated and
> + * must no longer be used. These counters are only valid for V3D
> 4.2.
> + *
> + * In order to check for performance counter information,
> + * use DRM_IOCTL_V3D_PERFMON_GET_COUNTER.

We should probably also include a reference to the new
DRM_V3D_PARAM_MAX_PERF_COUNTERS param here as well to retrieve the
total number of counters available.

Iago

> + */
>  enum {
>  	V3D_PERFCNT_FEP_VALID_PRIMTS_NO_PIXELS,
>  	V3D_PERFCNT_FEP_VALID_PRIMS,
diff mbox series

Patch

diff --git a/include/uapi/drm/v3d_drm.h b/include/uapi/drm/v3d_drm.h
index 0860ddb3d0b6..706b4dea1c45 100644
--- a/include/uapi/drm/v3d_drm.h
+++ b/include/uapi/drm/v3d_drm.h
@@ -603,6 +603,12 @@  struct drm_v3d_submit_cpu {
 	__u64 extensions;
 };
 
+/* The performance counters index represented by this enum are deprecated and
+ * must no longer be used. These counters are only valid for V3D 4.2.
+ *
+ * In order to check for performance counter information,
+ * use DRM_IOCTL_V3D_PERFMON_GET_COUNTER.
+ */
 enum {
 	V3D_PERFCNT_FEP_VALID_PRIMTS_NO_PIXELS,
 	V3D_PERFCNT_FEP_VALID_PRIMS,