main/postmarketos-initramfs: move unlock_root_partition to 2nd funcs (MR 6177)
It is used in the "2nd" part of the initramfs, not in the first one [ci:skip-build]: already built successfully in CI
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
# Maintainer: Caleb Connolly <caleb@postmarketos.org>
|
||||
# Co-Maintainer: Clayton Craft <clayton@craftyguy.net>
|
||||
pkgname=postmarketos-initramfs
|
||||
pkgver=3.7.4
|
||||
pkgver=3.7.5
|
||||
pkgrel=0
|
||||
pkgdesc="Base files for the postmarketOS initramfs / initramfs-extra"
|
||||
url="https://postmarketos.org"
|
||||
@@ -109,9 +109,9 @@ sha512sums="
|
||||
c0233d22858a5901db64e1d2fe1f6d39a2e2cfd1b94a10932483f55fed9461e9b8aa2d73b154b9d99a7a8b49ee02abfbddfe917ce0c6d7576601ba2668589c01 00-initramfs-base.files
|
||||
d0f35562365756d93066ce45924d17fb347b54095179c3262daa2f073e12743505cd5d9372ad30485915ca754d95a8edba9a74314e7949e0b3cf6978a87d03a5 00-initramfs-extra-base.files
|
||||
c497ace6f3d183c48722b9e4fd2b6fed21338d68a9e729c1423d3c3de3eaae7366d8dd75a11f78b7072a6795dcc5380c10d8b390738372ede6dc78074ae87a76 init.sh
|
||||
9f581b8ba94a2f9e4ca005c195c3ebbcfb4ffab6a89f376a27bcf316942b9246a8e7f47c8282c7033041e673d5409ad4df0b2bfd5b99a957e11e53f7b4513bf0 init_functions.sh
|
||||
b7fe2fb320831c2b482ed6f8299b3fd8bfe993cdf437c6d2d6161bc3f37d93d1959224809e776db6a3017737b97c4a7250c8a4f9eb0f57bbd42c3f21b1d34abd init_functions.sh
|
||||
1edba1de85505cf74f1d1639d8dc0f79764397643aa58b63e0beb7b97d8b67a4f604d90c4efafff0e75e36a3a88bf9d590eb5c29bce5711fc0fc6ffd4d4b617b init_2nd.sh
|
||||
1d3e3ca37a14c7e3d4b600cb0bcd389e467bd4e08aa33990b589ec5a3e42a59ffc38b2c2ed18972095ca96b14e8abe6df296f1a6615e8bb0dabfbd20fabe17e1 init_functions_2nd.sh
|
||||
3f750f2d963bdff97b662d220e9dc8092ce482b799695d27ae038f2c8b39ed442082931dfd19ed4833ec3e754f8877860df724f3d860845dc8793353b289e750 init_functions_2nd.sh
|
||||
675e7d5bee39b2df7d322117f8dcaccc274d61beaf4d50ead19bbf2109446d64b1c0aa0c5b4f9846eb6c1c403418f28f6364eff4537ba41120fbfcbc484b7da7 mdev.conf
|
||||
ba3275a9af788c7c782322a22a0f144d5e50e3498ea6886486a29331f23ae89cd32d500a3635cfa7cab369afba92edc18aeca64ccbf0cd589061cce23d15b46c unudhcpd.conf
|
||||
"
|
||||
|
||||
@@ -524,23 +524,6 @@ has_unallocated_space() {
|
||||
head -n1 | grep -qi "free space"
|
||||
}
|
||||
|
||||
unlock_root_partition() {
|
||||
command -v cryptsetup >/dev/null || return
|
||||
partition="$(find_root_partition)"
|
||||
if cryptsetup isLuks "$partition"; then
|
||||
# Make sure the splash doesn't interfere
|
||||
hide_splash
|
||||
tried=0
|
||||
until cryptsetup status root | grep -qwi active; do
|
||||
fde-unlock "$partition" "$tried"
|
||||
tried=$((tried + 1))
|
||||
done
|
||||
PMOS_ROOT=/dev/mapper/root
|
||||
# Show again the loading splashscreen
|
||||
show_splash "Loading..."
|
||||
fi
|
||||
}
|
||||
|
||||
mount_root_partition() {
|
||||
# Don't mount root if it is already mounted
|
||||
if mountpoint -q /sysroot; then
|
||||
|
||||
@@ -86,6 +86,23 @@ resize_root_partition() {
|
||||
fi
|
||||
}
|
||||
|
||||
unlock_root_partition() {
|
||||
command -v cryptsetup >/dev/null || return
|
||||
partition="$(find_root_partition)"
|
||||
if cryptsetup isLuks "$partition"; then
|
||||
# Make sure the splash doesn't interfere
|
||||
hide_splash
|
||||
tried=0
|
||||
until cryptsetup status root | grep -qwi active; do
|
||||
fde-unlock "$partition" "$tried"
|
||||
tried=$((tried + 1))
|
||||
done
|
||||
PMOS_ROOT=/dev/mapper/root
|
||||
# Show again the loading splashscreen
|
||||
show_splash "Loading..."
|
||||
fi
|
||||
}
|
||||
|
||||
# resize2fs and resize.f2fs are too big
|
||||
resize_root_filesystem() {
|
||||
partition="$(find_root_partition)"
|
||||
|
||||
Reference in New Issue
Block a user