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]
Date:   Tue, 10 Dec 2019 12:33:41 +0100
From:   Michal Hocko <mhocko@...nel.org>
To:     Baoquan He <bhe@...hat.com>
Cc:     linux-kernel@...r.kernel.org, linux-mm@...ck.org, jgross@...e.com,
        william.kucharski@...cle.com, mingo@...nel.org,
        akpm@...ux-foundation.org
Subject: Re: [PATCH] mm/hotplug: Only respect mem= parameter during boot stage

On Tue 10-12-19 18:43:03, Baoquan He wrote:
> On 12/10/19 at 11:28am, Michal Hocko wrote:
> > On Tue 10-12-19 15:24:53, Baoquan He wrote:
[...]
> > > But after system bootup, we should be able to hot add/remove any memory
> > > board. This should not be restricted by a boot-time kernel parameter
> > > 'mme='. This is what I am trying to fix.
> > 
> > This is a simple statement without any actual explanation on why. Why is
> > hotplug memory special? What is the usecase? Who would want to use mem
> > parameter and later expect a memory above the restrected area to be
> > hotplugable?
> 
> The why is 'mem=' is used to restrict the amount of system ram during
> boot. We have two ways to add system memory, one is installing DIMMs
> before boot, the other is hot adding memory after boot. Without David's 
> use case, we may need redefine 'mem=' and change its documentation in
> kernel-parameters.txt, if we don't want to fix it like this. Otherwise,
> 'mem=' will limit the system's upper system ram always, that is not
> expected.

I really do not see why. It seems a pretty consistent behavior to me.
Because it essentially cut any memory above the given size. If a new
hotplugable memory fits into that cap then it just shows up. Quite
contrary I would consider it unexpected that a memory higher than the
given mem=XYZ is really there. But I do recognize a real usecase
mentioned elsewhere which beats the consistency argument here because
all setups where such a restriction would be really important are
debugging/workaround AFAICS.
-- 
Michal Hocko
SUSE Labs

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ