Re: [PATCH] specific do_timer_cpu value for nohz off mode

From: Andrew Morton
Date: Wed Nov 30 2011 - 21:12:09 EST


On Wed, 30 Nov 2011 20:07:27 -0600 Dimitri Sivanich <sivanich@xxxxxxx> wrote:

> > And the whole thing is racy, isn't it? The "new" CPU can go offline a
> > nanosecond after we performed that test, so why perform it at all?
>
> See my email concerning the panic in cpu_online().

That doesn't address my question.

What's the point in checking cpu_online() when we have no locks to
prevent the online map from changing?

What happens if this cpu goes offline immediately after that check has
passed?

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/