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: <CAHmME9qhdRbFT26beStH3JYLiE0mpAZz-jp1jJsJdJNZKFpbvA@mail.gmail.com>
Date:   Fri, 28 Jan 2022 17:28:47 +0100
From:   "Jason A. Donenfeld" <Jason@...c4.com>
To:     Sebastian Andrzej Siewior <bigeasy@...utronix.de>
Cc:     Jonathan Neuschäfer <j.neuschaefer@....net>,
        Andy Lutomirski <luto@...capital.net>,
        LKML <linux-kernel@...r.kernel.org>,
        "Theodore Ts'o" <tytso@....edu>,
        Peter Zijlstra <peterz@...radead.org>,
        Ingo Molnar <mingo@...hat.com>, Will Deacon <will@...nel.org>,
        Waiman Long <longman@...hat.com>,
        Boqun Feng <boqun.feng@...il.com>
Subject: Re: "BUG: Invalid wait context" in invalidate_batched_entropy

Hi Sebastian,

On Fri, Jan 28, 2022 at 5:19 PM Sebastian Andrzej Siewior
<bigeasy@...utronix.de> wrote:
> Correct. You must not acquire a spinlock_t while holding a
> raw_spinlock_t. This is because on PREEMPT_RT the spinlock_t is a
> sleeping lock while raw_spinlock_t disables preemption/ interrupts and
> sleeping is not possible.
>         Documentation/locking/locktypes.rst
>
> On non-PREEMPT both lock types (spinlock_t & raw_spinlock_t) behave in
> the same way but lockdep can tell them apart with
> CONFIG_PROVE_RAW_LOCK_NESTING=y and show code that is problematic on RT.

Gotcha. Surely, then, Andy's patch at least goes some of the way
toward fixing this, since it outright _removes_ a spinlock_t. There is
still the other spinlock_t that you want removed, I realize, though
this doesn't appear to be the one from Jonathan's bug report. It
sounds like Andy's patch might be one side of the fix, and your patch
the other?

Jason

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ