Commit graph

16 commits

Author SHA1 Message Date
Pablo Correa Gómez
34e2a3ddad
main/postmarketos-initramfs: add new deviceinfo path to initramfs (MR 4283)
Reorder alphabetically while in the process, and depend on the first
mkinitfs and devicepkg-utils that implemented deviceinfo in /usr/share
2023-09-25 09:20:32 +02:00
Clayton Craft
9198a2ad6e
main/postmarketos-initramfs: upgrade to 2.0.0 (MR 4204)
Updates this package's checksums for files modified in this patch
series, and bumps the pkgver
2023-09-08 17:14:59 +02:00
Caleb Connolly
e0fcfb74e2
main/postmarketos-initramfs: use mdev properly (MR 4204)
Drop in mdev.conf and the /lib/mdev/persistent-storage script, these
cause /dev/disk/by-* to be populated in the ramdisk, making it
possible to do look up partition by-label and by-partlabel for free,
compared to findfs which can take some time.

As a first optimisation based on this, check for some partitions using
these paths and prioritise them when looking for subpartitions. Drop the
first find_boot_partition call as it doesn't really save time over the
call in the while loop.

The mdev config also handles setting up /dev/null, /dev/random, etc, so
these don't have to be done manually.
2023-09-07 20:33:55 +01:00
Clayton Craft
7c79667fe0
main/postmarketos-initramfs: move init.sh to initramfs-specific dir (MR 4204)
These files aren't owned by mkinitfs, or used to configure mkinitfs, so
I think it makes sense that they belong in a dir specific to this
package instead of cluttering up mkinitfs's config dirs.
2023-09-07 20:33:55 +01:00
Luca Weiss
5f820deefc
main/postmarketos-initramfs: switch_root with /dev (MR 3230) (MR 4204)
Mount /dev (and /run) in initramfs so util-linux switch_root can move
the mounts over to the new sysroot before changing root.
BusyBox switch_root doesn't even attempt to move anything so use
util-linux's switch_root for this.

Explicitly disable tests too...
2023-09-07 20:33:55 +01:00
bademux
80fff9242a
main/postmarketos-initramfs: support custom IP addresses for USB net (MR 3349)
[ci:skip-build] already built successfully in CI
2023-08-23 13:06:15 -07:00
Johannes Marbach
202b6e9435
main/postmarketos-initramfs: wait for splash to exit before unlocking (MR 3952)
[ci:skip-build]: already built successfully in CI
2023-08-08 09:36:17 +02:00
Pablo Correa Gómez
9839303dca
main/postmarketos-initramfs: stop using removed deviceinfo_modules_initfs (MR 4169)
The modules are now managed exclusively through the
/lib/modules/initramfs.load files
2023-08-04 08:27:44 +02:00
Steven Davies
1e4c8238c3
postmarketos-initramfs: Handle rootfsopts= on kernel cmdline (MR 4288)
This also removes redundant code and handles mount failure/no filesystem
separately.

fixes #2242
2023-08-02 11:33:47 -07:00
Pablo Correa Gómez
38ce112cdf
main/postmarketos-initramfs: load modules also from /lib/modules/initramfs.load (MR 4193)
Make it possible to load modules from the file installed by devicepkg-dev,
that will be there when extra modules are needed. This is coded in a
backwards-compatible way, so that it can be independent of the main modules
MR.

The code changes create a new function which takes a list of modules
and possibly a file (that should contain a list of modules too). The
idea is to be able to support also loading modules for initramfs-extra
in the future, and having a similar file would be more convenient than
extracting all the modules each time. In addition, the "[ -d /lib/modules]"
check has been removed. If there's no modules directory, as all
modules might be built-in, modprobe will fail, but that will not be
fatal. This will most likely only exclusively happen in some android
downstream kernel, so it should not be a big concern.
2023-07-10 11:07:51 -07:00
Luca Weiss
87ef850e88
main/postmarketos-initramfs: remove telnetd from initramfs (MR 4237)
This appears to be an ancient leftover from the telnet-based FDE
unlocking mechanism that has been present many many years ago.

But since this was removed a while ago, it's time to also finally remove
telnetd from the initramfs.
2023-07-08 19:06:29 +02:00
Newbyte
881dbc6a22
main/postmarketos-initramfs: use source_deviceinfo from devicepkg-utils (MR 4129)
See https://gitlab.com/postmarketOS/pmaports/-/issues/2086
2023-06-03 17:44:24 +02:00
Pablo Correa Gómez
b26ba8784c
main/postmarketos-initramfs: add function to source deviceinfo (MR 4037)
As a preparation for #1836, move the sourcing of deviceinfo to its own
function. This should allow to have a single point in the whole of the
initramfs for the sourcing of the deviceinfo, instead of every script
that needs it sourcing it. This allows to change the way deviceinfo is
sourced in the future with a lot less effort.
2023-04-26 18:13:52 +02:00
Caleb Connolly
e74ac08673
main/postmarketos-initramfs: fix splash newline (MR 3930)
POSIX sh dictates that newlines in strings are, newlines, so use printf
to format the splash strings and replace the "\\n" with an actual
newline.
2023-03-18 23:45:32 +00:00
Clayton Craft
82c02ea325
main/postmarketos-initramfs: support initramfs-extra as gzip (MR 3948)
This is a revert of the change introduced in 4eda0715 to support an
uncompressed initramfs-extra. osk-sdl support results in an initramfs-extra
that is too big for some devices with a small (traditional) /boot partition

Also see: https://gitlab.com/postmarketOS/pmaports/-/issues/2009

[ci:skip-build]: Already built successfully in CI
2023-03-12 19:36:49 +01:00
Clayton Craft
536264bac0
main/postmarketos-initramfs: new aport (MR 3895)
This package contains base file and module lists for the initramfs /
initramfs-extra archives, along with the init.sh

The primary reason for doing this is so that changes to these
files/lists can be properly versioned (in pkgver), and (re)building
mkinitfs itself is no longer required for these changes.

- Add base file list for initramfs. The dirs at path
  /usr/share/postmarketos-mkinitfs/* are "new" in mkinitfs 2.0

- Install default modules to /usr/share

- Install system config to /usr/share/mkinifs

- Add base files for -extra archive

- Create user config dirs

- Update hook dirs in init.sh, change from mkinitfs 2.0

- Remove splash images, obsolete since pbsplash

- Support uncompressed initramfs-extra
2023-03-08 21:34:37 -08:00