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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Tue, 18 Jun 2024 08:52:19 +0200
From: Hannes Reinecke <hare@...e.de>
To: Matthew Wilcox <willy@...radead.org>,
 "Pankaj Raghav (Samsung)" <kernel@...kajraghav.com>
Cc: david@...morbit.com, djwong@...nel.org, chandan.babu@...cle.com,
 brauner@...nel.org, akpm@...ux-foundation.org, mcgrof@...nel.org,
 linux-mm@...ck.org, linux-kernel@...r.kernel.org,
 yang@...amperecomputing.com, Zi Yan <zi.yan@...t.com>,
 linux-xfs@...r.kernel.org, p.raghav@...sung.com,
 linux-fsdevel@...r.kernel.org, hch@....de, gost.dev@...sung.com,
 cl@...amperecomputing.com, john.g.garry@...cle.com
Subject: Re: [PATCH v7 04/11] readahead: allocate folios with
 mapping_min_order in readahead

On 6/17/24 18:10, Matthew Wilcox wrote:
> On Mon, Jun 17, 2024 at 04:04:20PM +0000, Pankaj Raghav (Samsung) wrote:
>> On Mon, Jun 17, 2024 at 01:32:42PM +0100, Matthew Wilcox wrote:
>> So the following can still be there from Hannes patch as we have a
>> stable reference:
>>
>>   		ractl->_workingset |= folio_test_workingset(folio);
>> -		ractl->_nr_pages++;
>> +		ractl->_nr_pages += folio_nr_pages(folio);
>> +		i += folio_nr_pages(folio);
>>   	}
> 
> We _can_, but we just allocated it, so we know what size it is already.
> I'm starting to feel that Hannes' patch should be combined with this
> one.

And we could even make it conditional; on recent devices allocating 64k
(or even 2M) worth of zero pages is not a big deal. And if you have 
machines where this is an issue maybe using large folios isn't the best
of ideas to start with.

Cheers,

Hannes
-- 
Dr. Hannes Reinecke                  Kernel Storage Architect
hare@...e.de                                +49 911 74053 688
SUSE Software Solutions GmbH, Frankenstr. 146, 90461 Nürnberg
HRB 36809 (AG Nürnberg), GF: I. Totev, A. McDonald, W. Knoblich


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ