[PATCH] drm/xe/debugfs: Expose debugfs entry to check guc pc support

Nilawar, Badal badal.nilawar at intel.com
Fri Jan 19 08:25:18 UTC 2024



On 19-01-2024 13:48, Badal Nilawar wrote:
> Expose debugfs entry to check if platform support GuC PC (SLPC) feature.
> 
> Signed-off-by: Badal Nilawar <badal.nilawar at intel.com>
> ---
>   drivers/gpu/drm/xe/xe_debugfs.c | 8 ++++++++
>   1 file changed, 8 insertions(+)
> 
> diff --git a/drivers/gpu/drm/xe/xe_debugfs.c b/drivers/gpu/drm/xe/xe_debugfs.c
> index c56fd7d59f05..2f474bf0e7c7 100644
> --- a/drivers/gpu/drm/xe/xe_debugfs.c
> +++ b/drivers/gpu/drm/xe/xe_debugfs.c
> @@ -30,6 +30,13 @@ static struct xe_device *node_to_xe(struct drm_info_node *node)
>   	return to_xe_device(node->minor->dev);
>   }
>   
> +static int is_gucpc_supported(struct seq_file *m, void *data)
> +{
> +	struct xe_device *xe = node_to_xe(m->private);
> +
> +	return (int)!xe->info.skip_guc_pc;
Will change this to
return (xe->info.skip_guc_pc ? 0 : 1);

Regards,
Badal
> +}
> +
>   static int info(struct seq_file *m, void *data)
>   {
>   	struct xe_device *xe = node_to_xe(m->private);
> @@ -67,6 +74,7 @@ static int info(struct seq_file *m, void *data)
>   
>   static const struct drm_info_list debugfs_list[] = {
>   	{"info", info, 0},
> +	{"is_gucpc_supported", is_gucpc_supported, 0},
>   };
>   
>   static int forcewake_open(struct inode *inode, struct file *file)


More information about the Intel-xe mailing list