[Intel-xe] [PATCH v5 3/3] drm/xe/pmu: Enable PMU interface

Aravind Iddamsetty aravind.iddamsetty at linux.intel.com
Thu Aug 31 22:14:44 UTC 2023


On 01/09/23 02:15, Dixit, Ashutosh wrote:
> On Wed, 30 Aug 2023 13:58:29 -0700, Rodrigo Vivi wrote:
> Hi Aravind,
>
>>> diff --git a/include/uapi/drm/xe_drm.h b/include/uapi/drm/xe_drm.h
>>> index 86f16d50e9cc..75c9a7fe3490 100644
>>> --- a/include/uapi/drm/xe_drm.h
>>> +++ b/include/uapi/drm/xe_drm.h
>>> @@ -1056,6 +1056,22 @@ struct drm_xe_vm_madvise {
>>> 	__u64 reserved[2];
>>>  };
>>>
>>> +/* PMU event config IDs */
>>> +
>>> +/*
>>> + * Top bits of every counter are GT id.
>>> + */
>>> +#define __XE_PMU_GT_SHIFT (56)
>>> +
>>> +#define ___XE_PMU_OTHER(gt, x) \
>>> +	(((__u64)(x)) | ((__u64)(gt) << __XE_PMU_GT_SHIFT))
>>> +
>>> +#define XE_PMU_INTERRUPTS(gt)			___XE_PMU_OTHER(gt, 0)
>>> +#define XE_PMU_RENDER_GROUP_BUSY(gt)		___XE_PMU_OTHER(gt, 1)
>>> +#define XE_PMU_COPY_GROUP_BUSY(gt)		___XE_PMU_OTHER(gt, 2)
>>> +#define XE_PMU_MEDIA_GROUP_BUSY(gt)		___XE_PMU_OTHER(gt, 3)
>>> +#define XE_PMU_ANY_ENGINE_GROUP_BUSY(gt)	___XE_PMU_OTHER(gt, 4)
>> Could you please add uapi documentation here showing examples on how
>> this is used and all?
> Rodrigo clarified some more the sort of uapi documentation to add here:
yup I didn't acknowledge but didn't neglect it either, i'm working on it
will add as part of next series.

Thanks,
Aravind.
>
> https://patchwork.freedesktop.org/patch/551694/?series=121084&rev=4#comment_1009774
>
> Cheers,
> Ashutosh


More information about the Intel-xe mailing list