While the patch itself is very clean and understandable, I can't understand
the changelog ;)
Could you explain what is the semantics difference? The current code allows
read-in-write recursion too.
The only difference I can see is that now cpu_hotplug_begin() doesn't rely
on cpu_add_remove_lock any longer (currently the caller must hold this lock),
but this (good) change is not documented.
waitqueue_active() ?
Please note that wake_up() and wake_up_all() doesn't differ here, because
cpu_hotplug_begin() use prepare_to_wait(), not prepare_to_wait_exclusive().
I'd suggest to change cpu_hotplug_begin(), and use wake_up() for both
cases.
(actually, since write-locks should be very rare, perhaps we don't need
2 wait_queues ?)
Oleg.
--