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]
Date:   Sat, 2 Nov 2019 21:18:11 +0100
From:   David Hildenbrand <david@...hat.com>
To:     Scott Cheloha <cheloha@...ux.vnet.ibm.com>
Cc:     Rick Lindsley <ricklind@...ux.vnet.ibm.com>,
        linux-kernel@...r.kernel.org,
        "Rafael J. Wysocki" <rafael@...nel.org>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        nathanl@...ux.ibm.com
Subject: Re: [PATCH] drivers/base/memory.c: memory subsys init: skip search for missing blocks



> Am 02.11.2019 um 20:43 schrieb Scott Cheloha <cheloha@...ux.vnet.ibm.com>:
> 
> On Fri, Nov 01, 2019 at 11:47:49PM +0100, David Hildenbrand wrote:
>> 
>>>> Am 01.11.2019 um 23:32 schrieb Rick Lindsley <ricklind@...ux.vnet.ibm.com>:
>>> 
>>> On 11/1/19 12:00 PM, David Hildenbrand wrote:
>>>> No, I don't really like that. Can we please speed up the lookup via a radix tree as noted in the comment of "find_memory_block()".
>>> 
>>> I agree with the general sentiment that a redesign is the correct long term action - it has been for some time now - but implementing a new storage and retrieval method and verifying that it introduces no new problems itself is non-trivial.  There's a reason it remains a comment.
>>> 
>>> I don't see any issues with the patch itself.   Do we really want to forego the short term, low-hanging, low risk fruit in favor of waiting indefinitely for that well-tested long-term solution?
>> 
>> The low hanging fruit for me is to convert it to a simple VM_BUG_ON(). As I said, this should never really happen with current code.
>> 
>> Also, I don‘t think adding a radix tree here is rocket science and takes indefinitely ;) feel free to prove me wrong.
> 
> To clarify the goal here, "adding a radix tree" means changing
> subsys_private's klist_devices member from a klist to a radix
> tree or xarray, right?

I wouldn‘t go that far and only use a subsystem local data structure as a fast lookup cache. The memory subsystem is one of the rare subsystems that deals with such a big number of devices (AFAIK). Most other subsystems don‘t really need that.

I do agree that converting the klist to a radix tree would be more involved, but at least I think we can keep this subsystem-local, at least for now. Introducing a local cache should be simple.

Cheers!

> 
> -Scott

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ