aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/msm/msm_submitqueue.c
diff options
context:
space:
mode:
authorRob Clark <[email protected]>2021-07-28 01:06:06 +0000
committerRob Clark <[email protected]>2021-07-28 01:09:17 +0000
commit375f9a63a66baeb63ecc7d5fc740b9f02891ceda (patch)
tree445877bcbc5ecf890d2418ec1db6f05b5671ca65 /drivers/gpu/drm/msm/msm_submitqueue.c
parentdrm/msm: Devfreq tuning (diff)
downloadkernel-375f9a63a66baeb63ecc7d5fc740b9f02891ceda.tar.gz
kernel-375f9a63a66baeb63ecc7d5fc740b9f02891ceda.zip
drm/msm: Docs and misc cleanup
Fix a couple incorrect or misspelt comments, and add submitqueue doc comment. Signed-off-by: Rob Clark <[email protected]> Acked-by: Christian König <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Rob Clark <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/msm/msm_submitqueue.c')
-rw-r--r--drivers/gpu/drm/msm/msm_submitqueue.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/gpu/drm/msm/msm_submitqueue.c b/drivers/gpu/drm/msm/msm_submitqueue.c
index c3d206105d28..e5eef11ed014 100644
--- a/drivers/gpu/drm/msm/msm_submitqueue.c
+++ b/drivers/gpu/drm/msm/msm_submitqueue.c
@@ -98,17 +98,18 @@ int msm_submitqueue_create(struct drm_device *drm, struct msm_file_private *ctx,
return 0;
}
+/*
+ * Create the default submit-queue (id==0), used for backwards compatibility
+ * for userspace that pre-dates the introduction of submitqueues.
+ */
int msm_submitqueue_init(struct drm_device *drm, struct msm_file_private *ctx)
{
struct msm_drm_private *priv = drm->dev_private;
int default_prio;
- if (!ctx)
- return 0;
-
/*
* Select priority 2 as the "default priority" unless nr_rings is less
- * than 2 and then pick the lowest pirority
+ * than 2 and then pick the lowest priority
*/
default_prio = priv->gpu ?
clamp_t(uint32_t, 2, 0, priv->gpu->nr_rings - 1) : 0;