History

locking/rwsem: Remove RWSEM_OWNER_UNKNOWN

Remove the now unused RWSEM_OWNER_UNKNOWN hack. This hack breaks PREEMPT_RT and getting rid of it was the entire motivation for re-writing the percpu rwsem. The biggest problem is that it is fundamentally incompatible with any form of Priority Inheritance, any exclusively held lock must have a distinct owner.

Peter Zijlstra committed 6 years ago

Commit bcba67c1 parent 7f264822 files · +0 −8Browse files

Showing the changes to kernel/locking (1 of 2 files). Show all

Unified · Split

kernel/locking/rwsem.c+0−2
@@ -659,8 +659,6 @@ static inline bool rwsem_can_spin_on_owner(struct rw_semaphore *sem, · 658 unmodified lines
659659 unsigned long flags;
660660 bool ret = true;
661661
662− BUILD_BUG_ON(!(RWSEM_OWNER_UNKNOWN & RWSEM_NONSPINNABLE));
663−
664662 if (need_resched()) {
665663 lockevent_inc(rwsem_opt_fail);
666664 return false;