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] [day] [month] [year] [list]
Message-ID: <mhng-725db1f2-5b60-44d5-8ed1-71f3e7cdd8a7@palmer-ri-x1c9>
Date:   Fri, 16 Sep 2022 17:50:37 -0700 (PDT)
From:   Palmer Dabbelt <palmer@...osinc.com>
To:     Linus Torvalds <torvalds@...ux-foundation.org>
CC:     linux-kernel@...r.kernel.org, linux-riscv@...ts.infradead.org
Subject:     Re: [GIT PULL] RISC-V Fixes for 6.0-rc6

On Fri, 16 Sep 2022 13:09:21 PDT (-0700), Linus Torvalds wrote:
> On Fri, Sep 16, 2022 at 8:31 AM Palmer Dabbelt <palmer@...osinc.com> wrote:
>>
>> I have one merge conflict as a result of a treewide fix, I'm getting some odd
>> output from just showing the merge (it's showing some of the fix too), but I
>> think the merge itself is OK.  My fix is to keep the write lock
>>
>> -       mmap_read_lock(mm);
>> ++      mmap_write_lock(mm);
>>  +      ret = walk_page_range_novma(mm, start, end, &pageattr_ops, NULL,
>>  +                                  &masks);
>> -       mmap_read_unlock(mm);
>> ++      mmap_write_unlock(mm);
>
> Yes, thatr's the proper merge resolution.
>
> HOWEVER.
>
> Looking at the *callers* of this new __set_memory_mm(), this is all
> completely bogus and broken.
>
> In particular, fix_kernel_mem_early() does that call under rcu_read_lock().
>
> You can't do that. Not with the read-lock, and not with the
> write-lock. You simply cannot (and must not) block while in a
> read-side critical section, and trying to take any sleeping lock -
> whether for reading or for writing - is just completely wrong.
>
> So I'm not doing this pull. The merge resolution is trivial, but the
> code is simply wrong.

Sorry about that, it's pretty brain-dead.  I'd love to blame this one on 
the lack of sleep over the past week or two, but I'm a bit too tired to 
commit to that.  Either way I'll go sort it out, but not for this week 
-- I don't think anything else was super critical, so it shouldn't be 
that big of a problem.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ