summaryrefslogtreecommitdiffstats
path: root/meta/recipes-core/initrdscripts/initramfs-framework_1.0.bb
Commit message (Collapse)AuthorAgeFilesLines
* recipes: Update S = WORKDIR recipes to use ${S} correctlyRichard Purdie12 days1-11/+11
| | | | | | | | | | Where recipes use S = ${WORKDIR}, ensure they are referencing ${S} correctly to access files as soon we want to stop doing this in WORKDIR at which point they would break unless corrected. (From OE-Core rev: f25dd633fffe6560f191526d1869e657e129bad9) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* recipes: Drop remaining PR values from recipesRichard Purdie2023-09-221-1/+0
| | | | | | | | | | | | | | | | We've been removing PR values from recipes at upgrade time for a while. In general anyone maintaining a binary distro would end up having to curate these themselves so the values in OE-Core aren't really that useful anymore. In many ways it makes sense to clear out the remaining ones (which are mostly for 'config' recipes that are unlikely to increase in PV) and leave a clean slate for anyone implementing a binary distro config. References are left in meta-selftest since the tests there do involve them and their removal upon upgrade. (From OE-Core rev: d4c346e8ab8f3cae25d1b01c7331ed9f6d4f96ef) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initramfs-framework: Add overlayroot moduleAlejandro Hernandez Samaniego2022-03-011-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When installed, this module mounts a read-write (RW) overlay on top of a root filesystem, which is kept read-only (RO), free from modifications by the user, this might prove to be useful if we want to access or restore the original unmodified rootfs. The existing overlay-etc.bbclass does something similar, it mounts an overlay on top of the /etc directory, however doing the same for root causes the original root to be inaccessible once the system is booted, hence why this module is added to the initramfs boot flow, allowing us to mount the RW overlay, while keeping the original rootfs mounted at /rofs once the system finishes booting. This script is loosely based on that class. This module requires rootrw=<foo> to be passed as a kernel parameter to specify the device/partition to be used as RW by the overlay and has a dependency on overlayfs support being present in the running kernel. It does not require the read-only IMAGE_FEATURE to be enabled. The module needs to be executed after the initramfs-module-rootfs since it relies on it to mount the filesystem at initramfs startup but before the finish module which normally switches root. After overlayroot is executed the usual boot flow continues from the real init process. If something goes wrong while running this module, the rootfs is still mounted RO (with no overlay) and the finish module is executed to continue booting normally. Its worth noting that, on purpose, this isnt installed by default on any images that use initramfs-framework to keep the boot flow unmodified, only when a user manually requests to install it, then it becomes functional. (From OE-Core rev: 4f876982a856c54a8074c85346632e33caa7ef53) Signed-off-by: Alejandro Enedino Hernandez Samaniego <alhe@linux.microsoft.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* Convert to new override syntaxRichard Purdie2021-08-021-28/+28
| | | | | | | | | | | | This is the result of automated script conversion: scripts/contrib/convert-overrides.py <oe-core directory> converting the metadata to use ":" as the override character instead of "_". (From OE-Core rev: 42344347be29f0997cc2f7636d9603b1fe1875ae) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initramfs-framework: fix whitespace issueUlrich Ölmann2021-07-241-1/+1
| | | | | | | | (From OE-Core rev: 9eaf6f4b08144c7f5453545f2bd9fb387a2dbe2e) Signed-off-by: Ulrich Ölmann <u.oelmann@pengutronix.de> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initramfs-framework: add lvm moduleLiwei Song2019-03-251-0/+9
| | | | | | | | | | lvm module will initial lvm volume to support boot from Logical Volume. (From OE-Core rev: 3a4213f014fc4aa5be05dfc0722d87e01e5ff10c) Signed-off-by: Liwei Song <liwei.song@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* busybox/packagegroups: Break out the busybox-syslog dependencyRichard Purdie2018-09-101-0/+1
| | | | | | | | | | | | | | | | | | | | The busybox-syslog rrecomends is proving tricky as it gets pulled in early and there are conflicts between its use of update-alternatives and busybox needing to provide those things. We already have recipes using BAD_RRECOMMENDS to remove this dependency, it probably makes sense to spell it out explicitly and allow it to be overridden more easily. This patch does this, dropping the now unneeded BAD_RRECOMMENDS. It preserves the dependency as a recommendation for now, further cleanup may allow simplication of that. This unbreaks certain build failures on the autobuilder, more as a workaround but is a change we probably want to make anyway. (From OE-Core rev: 544ade2d78f1375d9e93d6bf5842d857ddaf3530) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initramfs-framework: add nfsrootfs moduleOleksii Konoplitskyi2018-07-091-0/+7
| | | | | | | | | nfsrootfs module mounts rootfs via nfs parsing "nfsroot" and "ip" cmdline options. (From OE-Core rev: d1737f2dabac5e338061863c78a91b4c115365c7) Signed-off-by: Oleksii Konoplitskyi <okonopli@cisco.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initramfs-framework: Add exec moduleOtavio Salvador2017-12-101-0/+9
| | | | | | | | | | | | This new module allow for easy execution of external scripts or applications. It runs anything found in /exec.d directory in order and in case of no scripts to be available, it opens a shell. (From OE-Core rev: 9b98c97338b4c3f985eca572d6a1e21324fa0fbc) Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initramfs-framework: bump PR and fix install-efi and setup-live modulesCalifornia Sullivan2017-09-121-1/+1
| | | | | | | | | | | | | | | | | | | | Bump initramfs-framework PR, as it was missed in the previous initramfs-framework patch. These modules are shell scripts so they can be allarch. Fix the SIGGEN_EXCLUDE_SAFE_RECIPE_DEPS in layer.conf, as these dependencies moved from the main recipe to these modules. Finally, set the PR to 4 in the new module recipes to avoid breaking package feeds. Fixes [YOCTO #12024]. (From OE-Core rev: d8af496dde699fadb2b21ff45cd20cf31e8abaf7) Signed-off-by: California Sullivan <california.l.sullivan@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initramfs-framework: split setup-live and install-efi into separate recipesCalifornia Sullivan2017-09-111-18/+2
| | | | | | | | | | | | | | Having these the initramfs-framework recipe forced initramfs-framework users to build several tools they didn't need, and made it more difficult to declare the recipe as allarch. Fixes [YOCTO #12024]. (From OE-Core rev: e4cc1a22dd4fc9b3b12808c86213eb613f1ecb51) Signed-off-by: California Sullivan <california.l.sullivan@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initramfs-framework: Change recipe to be allarchOtavio Salvador2017-08-311-6/+2
| | | | | | | | | | | | | | | There is no COMPATIBLE_HOST in the recipe neither it makes sense for this to be machine specific. Possibly, initramfs-framework's based modules may be machine specific but if there is the case they can just RDEPENDS on initramfs-framework-base and provide the specific module as another recipe. (From OE-Core rev: 9a661bca9d9dd03627a5efaea0f9247394f05b0e) Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initramfs-framework: include install-efi module in recipe for installationNg, Wei Tee2017-07-271-3/+16
| | | | | | | | | | | | | | | | | Utilized the existing init-install-efi.sh script and renamed it to install-efi.sh to manage the installation process of images in initramfs-framework model. This script will be executed when "install" option is being chosen in the grub menu and install the image on the target platform. A new install-efi module is being added in the recipe to handle the installation process using initramfs-framework. [YOCTO #10989] (From OE-Core rev: 41b34441c22143cbabace3d794ead05801afb7a0) Signed-off-by: Ng, Wei Tee <wei.tee.ng@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initramfs-framework: module to support boot live imageNg, Wei Tee2017-07-271-2/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | setup-live module is a new module being introduced to integrate the functionality of init-live.sh into new scriptlet named setup-live in order to support the live boot image. The udev-extraconf rdepends is being added to perform automounting. It gets to run before the rootfs and finish module. The setup-live scriplet include the changes for: - Create a conditional loop for the bootparam_root variable. If it is not set, then it will boot from ROOT_IMAGE. Else, it will boot normally which is not from removable media. - Gives a standard path to the original boot disk mount which can be used to. While /media/sda is a good guess, it isn't always right, nor is it a good assumption that only one boot disk is in the system. - The current rootfs module has no support for rootfs images, currently it only support for rootfs partitions for wic image. Therefore, there is a need to assign the rootfs image for live image. [YOCTO #11701] (From OE-Core rev: 4d3300e85a8e65207a415b9cf84c9fa1f71b0406) Signed-off-by: Ng, Wei Tee <wei.tee.ng@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initramfs-framework: make rootfs module optionalPatrick Ohly2016-07-201-1/+14
| | | | | | | | | | | | It still gets installed by default via RRECOMMENDS without having to update users of the framework (because without it, the framework is incomplete), but that recommendation can be overridden on a per-image basis. (From OE-Core rev: 73bfaa0e57a3b6c8779ba716c1e38fcbee734947) Signed-off-by: Patrick Ohly <patrick.ohly@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initramfs-framework: add retry loop for slow boot devices (like USB)Patrick Ohly2016-07-081-1/+3
| | | | | | | | | | | | | | | | | | | | | | On some hardware platforms (Gigabyte, qemu), detection of USB devices by the kernel is slow enough such that it happens only after the first attempt to mount the rootfs. We need to keep trying for a while (default: 5s seconds, controlled by roottimeout=<seconds>) and sleep between each attempt (default: one second, rootdelay=<seconds>). This change intentionally splits finding the rootfs (in the new "rootfs") and switching to it ("finish"). That is needed to keep udev running while waiting for the rootfs, because it shuts down before "finish" starts. It is also the direction that was discussed on the OE mailing list for future changes to initramfs-framework (like supporting a "live CD" module, which would replace or further augment mounting of the rootfs). (From OE-Core rev: 2a50bb9ee8838e3d026c82dc09aaccb880a264f4) Signed-off-by: Patrick Ohly <patrick.ohly@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initramfs-framework: mdev: Add a runtime dependency on busybox-mdevOtavio Salvador2016-06-231-1/+1
| | | | | | | | | | | | The mdev support relies on the mdev support inside busybox, which thus builds the busybox-mdev package. Adding the runtime dependency ensures its installation fails if mdev support is disabled. (From OE-Core rev: 48dbdc0317db6836cfeba083844910c15d5beb77) Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initramfs-framework_1.0:replace busybox for variable.Alejandro Joya2016-01-061-1/+1
| | | | | | | | | | | It replaces the use of busybox as hardcoded dependency to more dynamic this wouldn't affect the way that the initrams is build, just it let a more flexible replacement in the core. (From OE-Core rev: f0f7062e9aa5e7708fc92cac2afb1aa85eb3d4ef) Signed-off-by: Alejandro Joya <alejandro.joya.cruz@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initramfs-framework: create /dev/consolePatrick Ohly2015-09-061-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | Some kernels, for example linux-yocto 3.19 for qemux86, fail to execute /init in an initramfs unless there is already a /dev/console char device in the initramfs. Booting then fails with: Kernel panic - not syncing: /dev/console is missing or not a character device! Please ensure your rootfs is properly configured The panic itself comes from a linux-yocto specific patch to kernel_init_freeable in init/main.c, but even without it, that function will print an error when /dev/console is missing. The kernel's Documentation/initrd.txt also mentions creating that device. It remained unclear why this is not a problem on other machines. On intel-corei7-64 from meta-intel, something (the kernel?) creates /dev/console and /dev/[012] before transfering control to the init script. In that case, creating /dev/console in advance is not necessary, but does not cause any problem either. (From OE-Core rev: 0352841cd92f6316bcac092e2fff9d28c352b36b) Signed-off-by: Patrick Ohly <patrick.ohly@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* meta: set proper S valuePetter Mabäcker2015-01-231-0/+2
| | | | | | | | | | | | | | After removal of auto-creating S we must ensure that all recipes are using a proper value for S. Fix all recipes that only need to set S equals to WORKDIR. [YOCTO #5627] (From OE-Core rev: 9d220b1bfe4589736604dd5a7129e3699377d830) Signed-off-by: Petter Mabäcker <petter@technux.se> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initramfs-framework: get rid of udev-utilsChen Qi2014-06-251-1/+1
| | | | | | | | | | | Now that udev-utils package has been removed and 'udevadm' has been moved to udev package, the initramfs-framework should also get rid of the udev-utils package. (From OE-Core rev: f0b8f08e13f395820172d16c9d4c016a0fbdbfe9) Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* Replace one-line DESCRIPTION with SUMMARYPaul Eggleton2014-01-021-5/+5
| | | | | | | | | | | | | | A lot of our recipes had short one-line DESCRIPTION values and no SUMMARY value set. In this case it's much better to just set SUMMARY since DESCRIPTION is defaulted from SUMMARY anyway and then the SUMMARY is at least useful. I also took the opportunity to fix up a lot of the new SUMMARY values, making them concisely explain the function of the recipe / package where possible. (From OE-Core rev: b8feee3cf21f70ba4ec3b822d2f596d4fc02a292) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initramfsframework: Improve RDEPENDS to be package specificRichard Purdie2013-02-041-1/+1
| | | | | | (From OE-Core rev: 8c9a604d3ef33d47a48000d6c38159a64204e81e) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initramfs-framework: udev: Handle alternative binary pathsOtavio Salvador2012-12-031-1/+1
| | | | | | | | | | | This allows use of udev daemon for different installation destinations so allowing use of udev's from systemd code for initramfs. (From OE-Core rev: 96daf1b3105e17a67acb5027d0418b2ac28b6820) Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initrdscripts: fix udevd in the live boot init scriptsRoss Burton2012-11-121-0/+2
| | | | | | | | | | | | | | | udevd moved location and isn't in $PATH anymore, so use an absolute path to start it. The control socket path moved too, so mkdir the directory it's in. Mounts the new devtmpfs on /dev device tree. (From OE-Core rev: 543606e5dc379497c34196d004a214e847f5db2d) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Alexandru Damian <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initramfs-framework: provides a modular initramfsOtavio Salvador2011-12-081-0/+57
Provides the API and modules for a modular initramfs. The currently included modules are: * initramfs-module-debug adds support to dynamic debugging of initramfs using bootparams * initramfs-module-udev: enables udev usage * initramfs-module-mdev: enables mdev usage * initramfs-module-e2fs: adds support for ext4, ext3 and ext2 filesystems (From OE-Core rev: 7b69ad2167a1f0e57db82817b98a0cbcb70a0dd3) Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>