lkml.org 
[lkml]   [2023]   [Jun]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    SubjectRe: [RFC PATCH V3 4/6] sched/deadline: Introduce deadline servers
    Date
    On 08/06/23 17:58, Daniel Bristot de Oliveira wrote:
    > @@ -2033,9 +2147,20 @@ static struct task_struct *pick_next_task_dl(struct rq *rq)
    > struct task_struct *p;
    >
    > p = pick_task_dl(rq);
    > - if (p)
    > + if (!p)
    > + return p;
    > +
    > + /*
    > + * XXX: re-check !dl_server, changed from v2 because of
    > + * pick_next_task_dl change
    > + */
    > + if (!dl_server(&p->dl))
    > set_next_task_dl(rq, p, true);
    >

    Should this be

    if (!p->server)

    instead? AFAICT dl_server(&p->dl) can never be true since there's no
    pi_se-like link to the server via the dl_se, only via the task_struct, and
    the server pick cannot return the server itself (as it's a pure sched_entity).

    > + /* XXX not quite right */
    > + if (hrtick_enabled(rq))
    > + start_hrtick_dl(rq, &p->dl);
    > +

    IIUC that got hauled out of set_next_task_dl() to cover the case where we
    pick the server (+ the server pick) and want to more thoroughly enforce the
    server's bandwidth. If so, what's the issue with starting the hrtick here?

    > return p;
    > }
    >

    \
     
     \ /
      Last update: 2023-06-23 18:49    [W:5.163 / U:0.008 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site