lkml.org 
[lkml]   [2020]   [Jul]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [RFC PATCH 09/16] sched/fair: core wide cfs task priority comparison(Internet mail)
    On Wed, Jul 22, 2020 at 12:23:44AM +0000, benbjiang(蒋彪) wrote:
    >
    >
    > > +/*
    > > + * This function takes care of adjusting the min_vruntime of siblings of
    > > + * a core during coresched enable/disable.
    > > + * This is called in stop machine context so no need to take the rq lock.
    > Hi,
    >
    > IMHO, it seems that stop machine context cannot guarantee race free. The param *cpu* maybe not *this_cpu*, rq lock should be taken even in stop machine context, and irq should be disabled too, to avoid potential races with other contexts.
    >

    In stop machine context, all CPUs except the active ones are spinning
    with irq disabled and in this invocation of stop_machine(), only one
    CPU is active so I don't think race is possible.

    \
     
     \ /
      Last update: 2020-07-24 09:16    [W:3.646 / U:0.024 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site