Commit 64419ca6 authored by Peter Zijlstra's avatar Peter Zijlstra

sched,msm: Convert to sched_set_fifo*()

Because SCHED_FIFO is a broken scheduler model (see previous patches)
take away the priority field, the kernel can't possibly make an
informed decision.

Use sched_set_fifo(); Effectively changes prio from 16 to 50.

Cc: airlied@redhat.com
Signed-off-by: default avatarPeter Zijlstra (Intel) <peterz@infradead.org>
Reviewed-by: default avatarIngo Molnar <mingo@kernel.org>
parent 6e6d6efa
...@@ -389,7 +389,6 @@ static int msm_drm_init(struct device *dev, struct drm_driver *drv) ...@@ -389,7 +389,6 @@ static int msm_drm_init(struct device *dev, struct drm_driver *drv)
struct msm_kms *kms; struct msm_kms *kms;
struct msm_mdss *mdss; struct msm_mdss *mdss;
int ret, i; int ret, i;
struct sched_param param;
ddev = drm_dev_alloc(drv, dev); ddev = drm_dev_alloc(drv, dev);
if (IS_ERR(ddev)) { if (IS_ERR(ddev)) {
...@@ -495,12 +494,6 @@ static int msm_drm_init(struct device *dev, struct drm_driver *drv) ...@@ -495,12 +494,6 @@ static int msm_drm_init(struct device *dev, struct drm_driver *drv)
ddev->mode_config.funcs = &mode_config_funcs; ddev->mode_config.funcs = &mode_config_funcs;
ddev->mode_config.helper_private = &mode_config_helper_funcs; ddev->mode_config.helper_private = &mode_config_helper_funcs;
/**
* this priority was found during empiric testing to have appropriate
* realtime scheduling to process display updates and interact with
* other real time and normal priority task
*/
param.sched_priority = 16;
for (i = 0; i < priv->num_crtcs; i++) { for (i = 0; i < priv->num_crtcs; i++) {
/* initialize event thread */ /* initialize event thread */
priv->event_thread[i].crtc_id = priv->crtcs[i]->base.id; priv->event_thread[i].crtc_id = priv->crtcs[i]->base.id;
...@@ -516,8 +509,7 @@ static int msm_drm_init(struct device *dev, struct drm_driver *drv) ...@@ -516,8 +509,7 @@ static int msm_drm_init(struct device *dev, struct drm_driver *drv)
goto err_msm_uninit; goto err_msm_uninit;
} }
ret = sched_setscheduler(priv->event_thread[i].thread, ret = sched_set_fifo(priv->event_thread[i].thread);
SCHED_FIFO, &param);
if (ret) if (ret)
dev_warn(dev, "event_thread set priority failed:%d\n", dev_warn(dev, "event_thread set priority failed:%d\n",
ret); ret);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment