Re: [PATCH v4 1/4] MIPS: Refactor early_parse_mem() to fix mem= parameter

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 8 Mar 2022, Mike Rapoport wrote:

> > So can I just limit amount of memory without interfering with normal
> > memory detection ?
> 
> Maybe it's better to add a new encoding to mem= that will have the semantics
> of limiting amount of memory?
> 
> E.g.
> 
> mem=384M@
> 
> would mean "only use 384M of memory that firmware reported" while
> 
> mem=384M would mean "set memory to 0 - 384M" as it does now.

 I think you're going in the right direction, we'd just need to sort out 
the most reasonable syntax for the new semantics; `mem=384M@' just seems 
too analogous to me to `mem=384M@0'.  Maybe `mem=384M-'?

 NB that would have to work with the existing overrides, for e.g.:

`mem=192M@0 mem=192M@256M mem=384M-'

to produce the following memory ranges available for use:

  Normal   [mem 0x0000000000000000-0x000000000bffffff]
  Normal   [mem 0x0000000010000000-0x0000000017ffffff]

(so that you can paste the final cap at some command prompt and still have 
earlier parameters respected that may have been passed by the firmware or 
bootloader, or built in).

  Maciej



[Index of Archives]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux