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


Groups > linux.kernel > #1603368

Re: [locking/lockdep] 383776fa75: INFO: trying to register non-static key.

From Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Newsgroups linux.kernel
Subject Re: [locking/lockdep] 383776fa75: INFO: trying to register non-static key.
Date 2017-03-17 15:50 +0100
Message-ID <tm1mx-7VB-11@gated-at.bofh.it> (permalink)
References <tlI0y-25v-23@gated-at.bofh.it> <tm0A9-7ex-9@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On 2017-03-17 14:41:09 [+0100], Peter Zijlstra wrote:
> On Fri, Mar 17, 2017 at 02:07:05AM +0800, kernel test robot wrote:
> 
> >     locking/lockdep: Handle statically initialized PER_CPU locks properly
> 
> > [   11.712266] INFO: trying to register non-static key.
> 
> Blergh; so the problem is that when we assign can_addr to lock->key, we
> can, upon using a different subclass, reach static_obj(lock->key), which
> will fail on the can_addr.
> 
> One way to fix this would be to redefine the canonical address as the
> per-cpu address for a specific cpu; the below hard codes cpu0, but I'm
> not sure we want to rely on cpu0 being a valid cpu.

This solves two problems: The one reported by the bot. The other thing,
that is fixed by the patch, is that the first PER-CPU variable built-in
will return 0 for can_addr and so will the first variable in every
module. As far as I understand it, this should be unique and having the
same value for multiple different variables does not look too good :)
So adding the offset from CPU0 sounds good.

Sebastian

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


Thread

Re: [locking/lockdep] 383776fa75:  INFO: trying to register  non-static key. Peter Zijlstra <peterz@infradead.org> - 2017-03-17 15:00 +0100
  Re: [locking/lockdep] 383776fa75:  INFO: trying to register  non-static key. Sebastian Andrzej Siewior <bigeasy@linutronix.de> - 2017-03-17 15:50 +0100
    Re: [locking/lockdep] 383776fa75:  INFO: trying to register  non-static key. Peter Zijlstra <peterz@infradead.org> - 2017-03-20 12:50 +0100
      Re: [locking/lockdep] 383776fa75:  INFO: trying to register  non-static key. Borislav Petkov <bp@alien8.de> - 2017-03-25 19:20 +0100
      [tip:locking/core] lockdep: Fix per-cpu static objects tip-bot for Peter Zijlstra <tipbot@zytor.com> - 2017-03-26 11:50 +0200
      [tip:locking/core] lockdep: Fix per-cpu static objects tip-bot for Peter Zijlstra <tipbot@zytor.com> - 2017-03-26 15:30 +0200

csiph-web