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: <Zlb-9DNmRzIYRdJO@localhost.localdomain>
Date: Wed, 29 May 2024 12:09:56 +0200
From: Oscar Salvador <osalvador@...e.com>
To: Christophe Leroy <christophe.leroy@...roup.eu>
Cc: Oscar Salvador <osalvador@...e.com>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Jason Gunthorpe <jgg@...dia.com>, Peter Xu <peterx@...hat.com>,
	Michael Ellerman <mpe@...erman.id.au>,
	Nicholas Piggin <npiggin@...il.com>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	"linux-mm@...ck.org" <linux-mm@...ck.org>,
	"linuxppc-dev@...ts.ozlabs.org" <linuxppc-dev@...ts.ozlabs.org>
Subject: Re: [RFC PATCH v4 12/16] powerpc/e500: Encode hugepage size in PTE
 bits

On Wed, May 29, 2024 at 09:49:48AM +0000, Christophe Leroy wrote:
> Doesn't really matter if it's PUD or PMD at this point. On a 32 bits 
> kernel it will be all PMD while on a 64 bits kernel it is both PMD and PUD.
> 
> At the time being (as implemented with hugepd), Linux support 4M, 16M, 
> 64M, 256M and 1G (Shifts 22, 24, 26, 28, 30)
> 
> The hardware supports the following page sizes, and encodes them on 4 
> bits allthough it is not directly a shift. Maybe it would be better to 
> use that encoding after all:

I think so.

> 
> 0001 4 Kbytes (Shift 12)
> 0010 16 Kbytes (Shift 14)
> 0011 64 Kbytes (Shift 16)
> 0100 256 Kbytes (Shift 18)
> 0101 1 Mbyte (Shift 20)
> 0110 4 Mbytes (Shift 22)
> 0111 16 Mbytes (Shift 24)
> 1000 64 Mbytes (Shift 26)
> 1001 256 Mbytes (Shift 28)
> 1010 1 Gbyte (e500v2 only) (Shift 30)
> 1011 4 Gbytes (e500v2 only) (Shift 32)

You say hugehages start at 2MB (shift 21), but you say that the smallest hugepage
Linux support is 4MB (shift 22).?


-- 
Oscar Salvador
SUSE Labs

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ