lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <942e0ffb37a4580982206d72404c521d72d38314.camel@redhat.com>
Date:   Fri, 09 Oct 2020 13:54:34 -0400
From:   Qian Cai <cai@...hat.com>
To:     Peter Zijlstra <peterz@...radead.org>,
        "Paul E. McKenney" <paulmck@...nel.org>
Cc:     Steven Rostedt <rostedt@...dmis.org>,
        Ingo Molnar <mingo@...nel.org>, x86 <x86@...nel.org>,
        linux-kernel@...r.kernel.org, linux-tip-commits@...r.kernel.org,
        Linux Next Mailing List <linux-next@...r.kernel.org>,
        Stephen Rothwell <sfr@...b.auug.org.au>,
        Boqun Feng <boqun.feng@...il.com>
Subject: Re: [tip: locking/core] lockdep: Fix lockdep recursion

On Fri, 2020-10-09 at 13:36 -0400, Qian Cai wrote:
> Back to x86, we have:
> 
> start_secondary()
>   smp_callin()
>     apic_ap_setup()
>       setup_local_APIC()
>         printk() in certain conditions.
> 
> which is before smp_store_cpu_info().
> 
> Can't we add a rcu_cpu_starting() at the very top for each start_secondary(),
> secondary_start_kernel(), smp_start_secondary() etc, so we don't worry about
> any printk() later?

This is rather irony. rcu_cpu_starting() is taking a lock and then reports
itself.

[    8.826732][    T0]  __lock_acquire.cold.76+0x2ad/0x3e0
[    8.826732][    T0]  lock_acquire+0x1c8/0x820
[    8.826732][    T0]  _raw_spin_lock_irqsave+0x30/0x50
[    8.826732][    T0]  rcu_cpu_starting+0xd0/0x2c0
[    8.826732][    T0]  start_secondary+0x10/0x2a0
[    8.826732][    T0]  secondary_startup_64_no_verify+0xb8/0xbb


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ