Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1575487

Re: [PATCH v3 0/3] locking/spinlock_debug: Change it to a mostly fair lock

From Peter Zijlstra <peterz@infradead.org>
Newsgroups linux.kernel
Subject Re: [PATCH v3 0/3] locking/spinlock_debug: Change it to a mostly fair lock
Date 2017-02-07 09:50 +0100
Message-ID <t89Dk-vJ-19@gated-at.bofh.it> (permalink)
References <t6qoW-58b-17@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Thu, Feb 02, 2017 at 09:15:26AM -0500, Waiman Long wrote:
>  v2->v3:
>   - Keep the original v1 patches but move patch 3 of v2 in front so
>     as to disable GENERIC_LOCKBREAK when DEBUG_LOCK_ALLOC is on.
> 
>  v1->v2:
>   - Pack lockup and break_lock into a single 4-byte slot so as not
>     to in increase spinlock size when GENERIC_LOCKBREAK is
>     on. Hopefully that will be enough to fix a frame size too large
>     warning in 0-day build.
>   - Add a new patch to disable GENERIC_LOCKBREAK when DEBUG_LOCK_ALLOC
>     is on.
> 
> The current debug spinlock implementation is a TATAS unfair lock. This
> can occasionally lead to system lockup with a debug kernel because
> of the unfairness of the lock rather than inherent locking problem.
> 
> This patch set changes the debug spinlock implementation to a
> mostly fair spinlock based on the MCS lock similar to what is done
> in qspinlock. It also includes a patch that disable GENERIC_LOCKBREAK
> when DEBUG_LOCK_ALLOC is on.


An alternative is to just delete the thing entirely..

Ingo, much of what this thing does seems to be superseded by both
lockdep and a reliable NMI watchdog. Is there still value in
spinlock_debug?

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v3 0/3] locking/spinlock_debug: Change it to a mostly fair lock Waiman Long <longman@redhat.com> - 2017-02-02 15:20 +0100
  Re: [PATCH v3 0/3] locking/spinlock_debug: Change it to a mostly  fair lock Peter Zijlstra <peterz@infradead.org> - 2017-02-07 09:50 +0100
    Re: [PATCH v3 0/3] locking/spinlock_debug: Change it to a mostly  fair lock Ingo Molnar <mingo@kernel.org> - 2017-02-07 10:50 +0100
      Re: [PATCH v3 0/3] locking/spinlock_debug: Change it to a mostly fair  lock Waiman Long <longman@redhat.com> - 2017-02-07 20:50 +0100
        Re: [PATCH v3 0/3] locking/spinlock_debug: Change it to a mostly  fair lock "Paul E. McKenney" <paulmck@linux.vnet.ibm.com> - 2017-02-07 21:00 +0100
          Re: [PATCH v3 0/3] locking/spinlock_debug: Change it to a mostly  fair lock Peter Zijlstra <peterz@infradead.org> - 2017-02-08 10:50 +0100
            Re: [PATCH v3 0/3] locking/spinlock_debug: Change it to a mostly  fair lock "Paul E. McKenney" <paulmck@linux.vnet.ibm.com> - 2017-02-08 14:20 +0100

csiph-web