Skip to content

Commit

Permalink
drm/msm: Mark important kthreads as performance critical
Browse files Browse the repository at this point in the history
These kthreads (particularly crtc_event and crtc_commit) play a major role
in rendering frames to the display, so mark them as performance critical.

Signed-off-by: Sultan Alsawaf <[email protected]>
  • Loading branch information
kerneltoast authored and zeelog committed Dec 19, 2022
1 parent bca0062 commit 109ba9e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions drivers/gpu/drm/msm/msm_drv.c
Original file line number Diff line number Diff line change
Expand Up @@ -589,7 +589,7 @@ static int msm_drm_init(struct device *dev, struct drm_driver *drv)
kthread_init_worker(&priv->disp_thread[i].worker);
priv->disp_thread[i].dev = ddev;
priv->disp_thread[i].thread =
kthread_run(kthread_worker_fn,
kthread_run_perf_critical(kthread_worker_fn,
&priv->disp_thread[i].worker,
"crtc_commit:%d", priv->disp_thread[i].crtc_id);
ret = sched_setscheduler(priv->disp_thread[i].thread,
Expand All @@ -608,7 +608,7 @@ static int msm_drm_init(struct device *dev, struct drm_driver *drv)
kthread_init_worker(&priv->event_thread[i].worker);
priv->event_thread[i].dev = ddev;
priv->event_thread[i].thread =
kthread_run(kthread_worker_fn,
kthread_run_perf_critical(kthread_worker_fn,
&priv->event_thread[i].worker,
"crtc_event:%d", priv->event_thread[i].crtc_id);
/**
Expand Down Expand Up @@ -655,7 +655,7 @@ static int msm_drm_init(struct device *dev, struct drm_driver *drv)
* other important events.
*/
kthread_init_worker(&priv->pp_event_worker);
priv->pp_event_thread = kthread_run(kthread_worker_fn,
priv->pp_event_thread = kthread_run_perf_critical(kthread_worker_fn,
&priv->pp_event_worker, "pp_event");

ret = sched_setscheduler(priv->pp_event_thread,
Expand Down

0 comments on commit 109ba9e

Please sign in to comment.