Skip to contentSkip to conversation

SYSCTL: Use RCU to avoid races with string sysctls

PATCH Alexey Dobriyan 2 participants 2 messages Dec 21, 2009

lore
Share & tools
lore
#0 lore raw
Quoted 1 line

new = alloc_rcu_string(MAX_GLOBAL_SIZE, GFP_KERNEL);

I think adding failure mode is not right.
We can get away with per-sysctl-string spinlock and not introduce yet another API.

#1 lore raw
Quoted 5 lines · Alexey Dobriyan
Quoted 1 line

new = alloc_rcu_string(MAX_GLOBAL_SIZE, GFP_KERNEL);

I think adding failure mode is not right.
We can get away with per-sysctl-string spinlock and not introduce yet another API.

You mean when running out of memory here?

When this runs out of memory the system will be not usable anyways and on the last legs and likely in a deadly swap storm.

-Andi

Signature · 1 line
[email protected] -- Speaking for myself only.