On 05/12/2016 03:56 PM, Waiman Long wrote: > As rwsem_down_read_failed() will queue itself and potentially call > __rwsem_do_wake(sem, RWSEM_WAKE_ANY), it is possible that a reader > will try to wake up its own task. This patch adds a check to make > sure that this won't happen.
Although there's no particular harm in the current code, this at least spells out this condition is normal (ie., when a failed reader wakes itself while waking the other waiting readers). Reviewed-by: Peter Hurley <pe...@hurleysoftware.com>