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: <YO1pT1bjMfldbQKg@kernel.org>
Date:   Tue, 13 Jul 2021 13:22:07 +0300
From:   Mike Rapoport <rppt@...nel.org>
To:     David Hildenbrand <david@...hat.com>
Cc:     Andrew Morton <akpm@...ux-foundation.org>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Mike Rapoport <rppt@...ux.ibm.com>,
        "Rafael J. Wysocki" <rafael@...nel.org>,
        linux-kernel@...r.kernel.org, linux-mm@...ck.org
Subject: Re: [PATCH 1/2] mm: remove pfn_valid_within() and
 CONFIG_HOLES_IN_ZONE

On Tue, Jul 13, 2021 at 11:51:46AM +0200, David Hildenbrand wrote:
> On 13.07.21 10:00, Mike Rapoport wrote:
> > From: Mike Rapoport <rppt@...ux.ibm.com>
> > 
> > After recent changes in freeing of the unused parts of the memory map and
> > rework of pfn_valid() in arm and arm64 there are no architectures that can
> > have holes in the memory map within a pageblock and so nothing can enable
> > CONFIG_HOLES_IN_ZONE which guards non trivial implementation of
> > pfn_valid_within().
> > 
> > With that, pfn_valid_within() is always hardwired to 1 and can be
> > completely removed.
> > 
> > Remove calls to pfn_valid_within() and CONFIG_HOLES_IN_ZONE.
> > 
> > Signed-off-by: Mike Rapoport <rppt@...ux.ibm.com>
> 
> There is currently the discussion to increase MAX_ORDER, for example, to
> cover 1GiB instead of 4MiB on x86-64. This would mean that we could
> suddenly, again, have holes insides MAX_ORDER - 1 pages.
> 
> So I assume if we ever go down that path, we'll need something like this
> again.

It depends whether pageblock_order will be also increased. PFN walkers rely
on continuity of pageblocks rather than MAX_ORDER chunks, so if
pageblock_order won't change, there won't be need to check for pfn_valid()
inside a pageblock.
 
> For now, this looks like the right thing to do
> 
> Acked-by: David Hildenbrand <david@...hat.com>

Thanks!

-- 
Sincerely yours,
Mike.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ