Re: [PATCH 3/5] cpuset: change marker for relative numbering

From: Andrew Morton
Date: Sun Nov 06 2005 - 15:58:54 EST


Paul Jackson <pj@xxxxxxx> wrote:
>
> > Given that you're developing a library to do all this, why not do proper
> > locking in userspace and require that all cpuset updates go via the
> > library?
>
> The superficial reason why not is that I can't prevent someone from
> doing "echo pid > /dev/cpuset/tasks", moving a task to another cpuset
> even as that task in the middle of dorking with its cpusets. Not all
> cpuset operations will involve using my blessed library.

If someone modifies a library-managed cpuset via the backdoor then the
library (and its caller) are out of sync with reality _anyway_. Why does
an encounter with this very small race window worsen things?
-
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/