diff options
author | Michael Opdenacker <michael.opdenacker@bootlin.com> | 2023-09-17 16:38:11 +0200 |
---|---|---|
committer | Steve Sakoman <steve@sakoman.com> | 2023-09-23 05:26:16 -1000 |
commit | 2be874d5b401d271e9ae5eef46bbb0f64546f86b (patch) | |
tree | f52772b76402418b248672faa4424809c2a4724c | |
parent | 5ea10fc05bd044c8c521f56af0b0dfbae6a36331 (diff) | |
download | poky-2be874d5b401d271e9ae5eef46bbb0f64546f86b.tar.gz |
ref-manual: add Initramfs term
Backported from the master branch
(From yocto-docs rev: f5ecf1f407585617d258b6afc706d43fdbb33547)
Signed-off-by: Michael Opdenacker <michael.opdenacker@bootlin.com>
Signed-off-by: Steve Sakoman <steve@sakoman.com>
-rw-r--r-- | documentation/ref-manual/terms.rst | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/documentation/ref-manual/terms.rst b/documentation/ref-manual/terms.rst index ba13f77f19..a7ae8e1801 100644 --- a/documentation/ref-manual/terms.rst +++ b/documentation/ref-manual/terms.rst | |||
@@ -192,6 +192,48 @@ universal, the list includes them just in case: | |||
192 | of the supported image types that the Yocto Project provides, see the | 192 | of the supported image types that the Yocto Project provides, see the |
193 | ":ref:`ref-manual/images:Images`" chapter. | 193 | ":ref:`ref-manual/images:Images`" chapter. |
194 | 194 | ||
195 | :term:`Initramfs` | ||
196 | An Initial RAM Filesystem (:term:`Initramfs`) is an optionally compressed | ||
197 | :wikipedia:`cpio <Cpio>` archive which is extracted | ||
198 | by the Linux kernel into RAM in a special :wikipedia:`tmpfs <Tmpfs>` | ||
199 | instance, used as the initial root filesystem. | ||
200 | |||
201 | This is a replacement for the legacy init RAM disk ("initrd") | ||
202 | technique, booting on an emulated block device in RAM, but being less | ||
203 | efficient because of the overhead of going through a filesystem and | ||
204 | having to duplicate accessed file contents in the file cache in RAM, | ||
205 | as for any block device. | ||
206 | |||
207 | .. note:: | ||
208 | |||
209 | As far as bootloaders are concerned, :term:`Initramfs` and "initrd" | ||
210 | images are still copied to RAM in the same way. That's why most | ||
211 | most bootloaders refer to :term:`Initramfs` images as "initrd" | ||
212 | or "init RAM disk". | ||
213 | |||
214 | This kind of mechanism is typically used for two reasons: | ||
215 | |||
216 | - For booting the same kernel binary on multiple systems requiring | ||
217 | different device drivers. The :term:`Initramfs` image is then customized | ||
218 | for each type of system, to include the specific kernel modules | ||
219 | necessary to access the final root filesystem. This technique | ||
220 | is used on all GNU / Linux distributions for desktops and servers. | ||
221 | |||
222 | - For booting faster. As the root filesystem is extracted into RAM, | ||
223 | accessing the first user-space applications is very fast, compared | ||
224 | to having to initialize a block device, to access multiple blocks | ||
225 | from it, and to go through a filesystem having its own overhead. | ||
226 | For example, this allows to display a splashscreen very early, | ||
227 | and to later take care of mounting the final root filesystem and | ||
228 | loading less time-critical kernel drivers. | ||
229 | |||
230 | This cpio archive can either be loaded to RAM by the bootloader, | ||
231 | or be included in the kernel binary. | ||
232 | |||
233 | For information on creating and using an :term:`Initramfs`, see the | ||
234 | ":ref:`dev-manual/building:building an initial ram filesystem (Initramfs) image`" | ||
235 | section in the Yocto Project Development Tasks Manual. | ||
236 | |||
195 | :term:`Layer` | 237 | :term:`Layer` |
196 | A collection of related recipes. Layers allow you to consolidate related | 238 | A collection of related recipes. Layers allow you to consolidate related |
197 | metadata to customize your build. Layers also isolate information used | 239 | metadata to customize your build. Layers also isolate information used |