- Subject: need some clarifications concerning rootf mounting
- From: stl <st.lambert02@xxxxxxxxx>
- Date: Wed, 8 Aug 2012 11:01:20 +0200
I need some explanations concerning the ways to mount rootf during boot.
I have read some documents (notably the very useful How to use initramfs by Rob Landley)
and dug into the source code, but some doubts remain.
If I well understood, there is 2 differents procedures to mount the rootfs:
- using the old way: init ramdisk
- using the initramfs support (which appears to be really more efficient)
The fonction "populate_rootfs()" seems to be a crucial point of the procedure:
it calls a first time "unpack_to_roofs()" with __initramfs_start and __initramfs_size
as arguments, and if initrd_start is not NULL, calls one more time "unpack_to_rootfs()"
with initrd_start and (initrd_end-initrd_start) as arguments.
What's really happening during the first unpack_to_rootfs() ?
Does the kernel unpack the iniramfs.cpio (created either by supplying a valid cpio one
or a config file through CONFIG_INITRAMFS_SOURCE) from __initramfs_start (defined in vmlinux.lds.S)?
If I aim to use initramfs support, should I do something with initrd_start/end and CONFIG_BLK_DEV_RAM stuffs?
Thanks in advance for your help and clarifications.
Kernelnewbies mailing list
[Linux Kernel Mentors]
[Linux Kernel Development]