[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH 1/6] xen/sched: call cpu_disable_scheduler() via cpu notifier



>>> On 18.03.19 at 14:11, <jgross@xxxxxxxx> wrote:
> @@ -1738,6 +1733,9 @@ static int cpu_schedule_callback(
>          rc = cpu_schedule_up(cpu);
>          break;
>      case CPU_DEAD:
> +        rcu_read_lock(&domlist_read_lock);
> +        cpu_disable_scheduler(cpu);
> +        rcu_read_unlock(&domlist_read_lock);
>          SCHED_OP(sched, deinit_pdata, sd->sched_priv, cpu);
>          /* Fallthrough */
>      case CPU_UP_CANCELED:

cpu_disable_scheduler() has a return value (and hence means to
fail) - is ignoring this here really appropriate?

Also while indeed (as the description says) there's no need to
run the function on the CPU itself, it's not obvious to me that
it's safe to run it outside of stop_machine() context. Or to be
more precise, it's not clear to me that leaving stop_machine()
context with the adjustments not done yet is not going to
lead to problems (due to the gap between leaving that context
and acquiring the RCU lock). Could you clarify this in the
description, please (if it indeed is fine this way)?

Jan



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.