Re: [PATCH] [0/11] SYSCTL: Use RCU to avoid races with stringsysctls
From: Andi Kleen
Date: Sun Dec 20 2009 - 22:21:16 EST
> So we have sysctl have locking problems, not new sysctl regressions.
Ok.
> > If the strings were made a bit smaller this could be also
> > put on the stack, but I didn't dare for 256 bytes.
>
> Hmm. rcu wise that sounds wrong, but I haven't looked into your
What sounds wrong?
The reason for the copies is that when the reader sleeps
rcu_read_lock() cannot be used to protect the string completely,
so it copies instead.
The alternative would have been to use SRCU, but I didn't like that.
> cool new data structure yet.
It's not really particularly new or cool, it's just a simple RCU wrapper
around a string.
-Andi
--
ak@xxxxxxxxxxxxxxx -- Speaking for myself only.
--
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/