lkml.org 
[lkml]   [2019]   [Feb]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2 6/6] RISC-V: Implement keepinitrd kernel parameter
On Tue, Feb 12, 2019 at 03:53:21PM +0530, Anup Patel wrote:
> If it is initramfs (i.e. CPIO image) then contents of CPIO archive
> are extracted to create a ramfs instance.
>
> If it is initrd (i.e. some filesystem image) then RAM block device
> is created in-place at initrd location. (Please correct me if I am
> wrong about initrd here).

No. If it is an initrd image we still copy it into the rootfs first,
and then load it into a ram disk. Take a look at
init/initramfs.c:populate_rootfs() and
init/do_mounts_initrd.c:initrd_load().

> So in case of initrd we might not want to free-up the RAM but
> we can certainly free-up in case of initramfs.

No, in either case we do not need the original initramfs/initrd
memory. I suspect arm has this as a workaround for some weird
legacy boot issue, but I can't see any reason why we would not want
to free the memory on riscv.

\
 
 \ /
  Last update: 2019-02-12 19:45    [W:0.082 / U:0.076 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site