[PATCH] arm64: spinlocks: Fix write starvation with rwlock

Peter Zijlstra peterz at infradead.org
Fri Sep 8 09:22:14 PDT 2017


On Fri, Sep 08, 2017 at 10:59:59AM -0500, Jeremy Linton wrote:
> 
> This patch changes the rwlock behavior so that the writer
> unconditionally flags the lock structure (given that its
> not already flagged by another writer). This blocks further
> readers from acquiring the lock. Once all the readers have
> drained, the writer that successfully flagged the lock can
> progress.

Recursive readers from IRQ context _should_ be allowed through,
otherwise you'll have deadlocks on tasklist_lock.



More information about the linux-arm-kernel mailing list