From: Boris Brezillon <boris.brezillon@collabora.com>
To: Mary Guillemard <mary.guillemard@collabora.com>
Cc: linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org,
Christopher Healy <healych@amazon.com>,
kernel@collabora.com, Steven Price <steven.price@arm.com>,
Liviu Dudau <liviu.dudau@arm.com>,
Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
Maxime Ripard <mripard@kernel.org>,
Thomas Zimmermann <tzimmermann@suse.de>,
David Airlie <airlied@gmail.com>, Daniel Vetter <daniel@ffwll.ch>
Subject: Re: [PATCH v2 1/2] drm/panthor: Add PANTHOR_GROUP_PRIORITY_REALTIME group priority
Date: Fri, 6 Sep 2024 08:13:02 +0200 [thread overview]
Message-ID: <20240906081302.4aba8c45@collabora.com> (raw)
In-Reply-To: <20240905173222.252641-3-mary.guillemard@collabora.com>
On Thu, 5 Sep 2024 19:32:22 +0200
Mary Guillemard <mary.guillemard@collabora.com> wrote:
> This adds a new value to drm_panthor_group_priority exposing the
> realtime priority to userspace.
>
> This is required to implement NV_context_priority_realtime in Mesa.
>
> v2:
> - Add Steven Price r-b
>
> Signed-off-by: Mary Guillemard <mary.guillemard@collabora.com>
> Reviewed-by: Steven Price <steven.price@arm.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
> ---
> drivers/gpu/drm/panthor/panthor_drv.c | 2 +-
> drivers/gpu/drm/panthor/panthor_sched.c | 2 --
> include/uapi/drm/panthor_drm.h | 7 +++++++
> 3 files changed, 8 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/panthor/panthor_drv.c b/drivers/gpu/drm/panthor/panthor_drv.c
> index 0caf9e9a8c45..7b1db2adcb4c 100644
> --- a/drivers/gpu/drm/panthor/panthor_drv.c
> +++ b/drivers/gpu/drm/panthor/panthor_drv.c
> @@ -1041,7 +1041,7 @@ static int group_priority_permit(struct drm_file *file,
> u8 priority)
> {
> /* Ensure that priority is valid */
> - if (priority > PANTHOR_GROUP_PRIORITY_HIGH)
> + if (priority > PANTHOR_GROUP_PRIORITY_REALTIME)
> return -EINVAL;
>
> /* Medium priority and below are always allowed */
> diff --git a/drivers/gpu/drm/panthor/panthor_sched.c b/drivers/gpu/drm/panthor/panthor_sched.c
> index 91a31b70c037..86908ada7335 100644
> --- a/drivers/gpu/drm/panthor/panthor_sched.c
> +++ b/drivers/gpu/drm/panthor/panthor_sched.c
> @@ -137,8 +137,6 @@ enum panthor_csg_priority {
> * non-real-time groups. When such a group becomes executable,
> * it will evict the group with the lowest non-rt priority if
> * there's no free group slot available.
> - *
> - * Currently not exposed to userspace.
> */
> PANTHOR_CSG_PRIORITY_RT,
>
> diff --git a/include/uapi/drm/panthor_drm.h b/include/uapi/drm/panthor_drm.h
> index 1fd8473548ac..011a555e4674 100644
> --- a/include/uapi/drm/panthor_drm.h
> +++ b/include/uapi/drm/panthor_drm.h
> @@ -720,6 +720,13 @@ enum drm_panthor_group_priority {
> * Requires CAP_SYS_NICE or DRM_MASTER.
> */
> PANTHOR_GROUP_PRIORITY_HIGH,
> +
> + /**
> + * @PANTHOR_GROUP_PRIORITY_REALTIME: Realtime priority group.
> + *
> + * Requires CAP_SYS_NICE or DRM_MASTER.
> + */
> + PANTHOR_GROUP_PRIORITY_REALTIME,
> };
>
> /**
next prev parent reply other threads:[~2024-09-06 6:13 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-09-05 17:32 [PATCH v2 0/2] drm/panthor: Expose realtime group priority and allowed priorites to userspace Mary Guillemard
2024-09-05 17:32 ` [PATCH v2 1/2] drm/panthor: Add PANTHOR_GROUP_PRIORITY_REALTIME group priority Mary Guillemard
2024-09-06 6:13 ` Boris Brezillon [this message]
2024-09-05 17:32 ` [PATCH v2 2/2] drm/panthor: Add DEV_QUERY_GROUP_PRIORITIES_INFO dev query Mary Guillemard
2024-09-06 6:12 ` Boris Brezillon
2024-09-06 10:22 ` Steven Price
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240906081302.4aba8c45@collabora.com \
--to=boris.brezillon@collabora.com \
--cc=airlied@gmail.com \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=healych@amazon.com \
--cc=kernel@collabora.com \
--cc=linux-kernel@vger.kernel.org \
--cc=liviu.dudau@arm.com \
--cc=maarten.lankhorst@linux.intel.com \
--cc=mary.guillemard@collabora.com \
--cc=mripard@kernel.org \
--cc=steven.price@arm.com \
--cc=tzimmermann@suse.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.