Compare commits

...
4 Commits
Author SHA1 Message Date
gompa a08c28f620 device-nokia-sparkler: add pmos.force-load-modules to kernel cmd
add pmos.force-load-modules to kernel cmd
this fixes: The screen flashes brightness, but the old content (lk2nd bootscreen) remains on the screen, and then it hangs.
2024-06-28 08:57:50 -07:00
gompa 1855531e0a device-nokia-leo: add pmos.force-load-modules to kernel cmd
add pmos.force-load-modules to kernel cmd
this fixes: The screen flashes brightness, but the old content (lk2nd bootscreen) remains on the screen, and then it hangs.
2024-06-28 08:57:50 -07:00
gompa 27eef3159e device-nokia-argon: add pmos.force-load-modules to kernel cmd
add pmos.force-load-modules to kernel cmd
this fixes: The screen flashes brightness, but the old content (lk2nd bootscreen) remains on the screen, and then it hangs.
2024-06-28 08:57:50 -07:00
Clayton Craft 4bbecb279e main/postmarketos-initramfs: add option to force loading modules
This brings back load_modules from the days when we used mdev, and calls
it before udev. If for some reason udev can't load modules, this at
least gives some sort of workaround for devices that can't boot with
udev-only [1]. This helps with debugging issues brought about by
7c981277, and gives device owners a way to temporarily work around it
until the kernel can be fixed.

The feature is hidden behind a kernel cmdline arg,
pmos.force-load-modules

1. https://gitlab.com/postmarketOS/pmaports/-/merge_requests/5287
2024-06-28 08:57:50 -07:00
9 changed files with 26 additions and 12 deletions

No files matched your search

+2 -2
View File
@@ -1,7 +1,7 @@
# Reference: <https://postmarketos.org/devicepkg>
pkgname=device-nokia-argon
pkgdesc="Nokia 8110 4G"
pkgver=4
pkgver=5
pkgrel=0
url="https://postmarketos.org"
license="GPL-2.0-only"
@@ -54,7 +54,7 @@ nonfree_firmware() {
sha512sums="
66302bb5d83c4ba155ff62405fb9a374ab76e1912411310b1ad75e00c216b6868da4e2b6f3987c97146389aa44b2b2c26f0ca0819566be45c9d0d2dd1d3b72f1 00-nokia-argon-display.files
69b04093b06d7aa615eaf585931ff6c16a4800476fa6b461d015318cd45fff224abf88019f4de2e966c0ad469b6bb4e6d5720e481d226cf691f8fc1b1c0cc99b deviceinfo
aa0b3ab526de64af3bd856cd12c9ccd28ad3e4647a9a6b9b100a8d78c377ebdf2f36cb75dc3e33c38e4d88524088313afe8acaea022adb6b9e17343fbb8a7733 deviceinfo
749fa5911f53f65c1a18a8768d374d1ea39ef47ed61146a5f79d669250788501434a059cfff65b83cb54eb7273841686b4a3a04f20aaec6ec7f742e14623c8bc modules-initfs
dd82fd4732694a24c91339b5c5fbb0bf485b3b2da3c17c11b72a02e90e9827c367504c99894556dd8273f927408cdb187325e5f3b9ea9e4a82e3cb3798cb2816 nokia,argon-gc9305-v2-panel.txt
"
+1 -1
View File
@@ -21,7 +21,7 @@ deviceinfo_screen_height="320"
# Bootloader related
deviceinfo_flash_method="fastboot"
deviceinfo_kernel_cmdline="earlycon console=ttyMSM0,115200"
deviceinfo_kernel_cmdline="earlycon pmos.force-load-modules console=ttyMSM0,115200"
deviceinfo_generate_bootimg="true"
deviceinfo_generate_extlinux_config="true"
deviceinfo_bootimg_qcdt="false"
+2 -2
View File
@@ -1,7 +1,7 @@
# Reference: <https://postmarketos.org/devicepkg>
pkgname=device-nokia-leo
pkgdesc="Nokia 6300 4G"
pkgver=2
pkgver=3
pkgrel=0
url="https://postmarketos.org"
license="GPL-2.0-only"
@@ -55,6 +55,6 @@ nonfree_firmware() {
sha512sums="
8583c7d5a97c4efedff3ec554cf682d815fd7b83140c2cab9eec4b6e2e735ce3c012bc3bd97f8bc75adc3483f76ce83a5bf1090d4f3e73a327efc64ca9eca5a7 nokia,leo-gc9305-hlt-24-panel.txt
c9985232e5e64ddb0906b053e5024c87fa62cc1bcb254260e1ef6afb43d384196e09d41287143bcba61dff616dd6b562a5ca335dbe592fcd8c954642b8085f38 00-nokia-leo-display.files
d28c316bace09629d13bf93261cbaaf2c6c2c9f3f0adb891e4055d4da721b881a9b883d13683989f483b9a5ef9a283974d6e4d1f7179928d768c1424c7fcc449 deviceinfo
66181f9915acdfbc5db98a071afaad36971c6c83fde9d3b8a670eec76a9f48ddcf37942db9ecca1a44439c39310e1b32ffdd6c888b650ebe209a61ca8e21fc1d deviceinfo
d5dfe844a45cfc4e0844e43b8fb3e1bbcb155e06430188f8d5059fc5ce3c4100fde7f1580b1b54c5318f40d238736b233463582e55b9dd25654e40539e11ed39 modules-initfs
"
+1 -1
View File
@@ -21,7 +21,7 @@ deviceinfo_screen_height="320"
# Bootloader related
deviceinfo_flash_method="fastboot"
deviceinfo_kernel_cmdline="earlycon console=ttyMSM0,115200"
deviceinfo_kernel_cmdline="earlycon pmos.force-load-modules console=ttyMSM0,115200"
deviceinfo_generate_bootimg="true"
deviceinfo_generate_extlinux_config="true"
deviceinfo_bootimg_qcdt="false"
@@ -1,7 +1,7 @@
# Reference: <https://postmarketos.org/devicepkg>
pkgname=device-nokia-sparkler
pkgdesc="Nokia 8000 4G"
pkgver=2
pkgver=3
pkgrel=0
url="https://postmarketos.org"
license="GPL-2.0-only"
@@ -55,6 +55,6 @@ nonfree_firmware() {
sha512sums="
721d740ff8dbbbafff4bc734228a82bd57d76177b9bf417d660ecb181a72a998319ddbde77d0efc5e875d2256596578212e3e0bfb85c2e77e5bbf6d0e88d9fa4 nokia,sparkler-gc9307-hlt-28-panel.txt
89b3dd5bf1dd5e85bf66bfb6dba56e2a8e919fe3aa7dc369c18c9e56f7e0ae88319186551412497a601081b904c12dd07ebed4f39fd4a4ba6199fb8af9c90f40 00-nokia-sparkler-display.files
7566d2cc3a43a12b37ae3b62c8e7947788dde94174ead19e9fd80e80244a02c97f27847a67677ff8564ad573048af884f588969b39dd2ce6385688c4fe0964b5 deviceinfo
e0eef709d17c5295387afe87428a4a2eba0bb6cb8af6666b57696561c3af30b650dc107f483e001aeefe85458bb8224c50dae6666cc28e273fb8ae5313a81312 deviceinfo
d5dfe844a45cfc4e0844e43b8fb3e1bbcb155e06430188f8d5059fc5ce3c4100fde7f1580b1b54c5318f40d238736b233463582e55b9dd25654e40539e11ed39 modules-initfs
"
@@ -21,7 +21,7 @@ deviceinfo_screen_height="320"
# Bootloader related
deviceinfo_flash_method="fastboot"
deviceinfo_kernel_cmdline="earlycon console=ttyMSM0,115200"
deviceinfo_kernel_cmdline="earlycon pmos.force-load-modules console=ttyMSM0,115200"
deviceinfo_generate_bootimg="true"
deviceinfo_generate_extlinux_config="true"
deviceinfo_bootimg_qcdt="false"
+3 -3
View File
@@ -2,7 +2,7 @@
# Co-Maintainer: Clayton Craft <clayton@craftyguy.net>
pkgname=postmarketos-initramfs
pkgver=3.2.1
pkgrel=0
pkgrel=1
pkgdesc="Base files for the postmarketOS initramfs / initramfs-extra"
url="https://postmarketos.org"
options="!check" # no tests
@@ -91,7 +91,7 @@ sha512sums="
9c0e8f6f61d5da191e03a1aa9d5d0ceb5baf1eae6dbb9bfb0af59817783525119ac8394b135f303f7b6434a3eab0b49185fb90379e06823db847a4999c75ce33 00-initramfs-base.dirs
929a8e6cca6b2b4ac6af89fc3912e80315f51c9bf6e9479124ccb7ebe9e99c6c1cafb98d3aa01b0a76a2f6e0071ba3eb86c7a2169a15c2e1788d69458bea3471 00-initramfs-base.files
8a4adad3785af474b36a09a05f6a3b2c4b4f43aac331a53b903abfa51ea12be1e3d1d807b7a6e66a1346815f3b0044daf8cd62e21e2dc75d2db13ee265a72985 00-initramfs-extra-base.files
e85386077d590cd0db0745e8b58f3323a408cb6a94bca0e4395c43e4db18b0beef29324ed2bfeab6511d0e3b297c067e5a37f420a6877d9c28c285f2416ca420 init.sh
e0954014d73e7a61376a2463978a4b44d17bbb2319072382a3412a8214e9c3e45266266d8eebd37634b1b18a71094055464a7c81b973501378dcf05aa5c2f4c0 init_functions.sh
9b8b06a97f702a0aa54022f662813d4aca48d618307f2295c5622b934c4d6c77ca2fb657d6e94a69040cda9f7fa368d1ba89c9e21a3d04d185c18284ba0ff0cf init.sh
ab3e1ec5b1aa3f492b95a20c23bc1e05771062fce1cb2a3f7ffa3cfce1fdb0522b413c018eeef4d1251079b6d23b19ec5a2ee4f4fb624dfccd44550f8c30788d init_functions.sh
ba3275a9af788c7c782322a22a0f144d5e50e3498ea6886486a29331f23ae89cd32d500a3635cfa7cab369afba92edc18aeca64ccbf0cd589061cce23d15b46c unudhcpd.conf
"
+5
View File
@@ -26,6 +26,11 @@ export PATH=/usr/bin:/bin:/usr/sbin:/sbin
mount_proc_sys_dev
setup_log
setup_firmware_path
if grep -q "pmos.force-load-modules" /proc/cmdline; then
load_modules /lib/modules/initramfs.load "libcomposite"
fi
# Run udev early, before splash, to make sure any relevant display drivers are
# loaded in time
setup_udev
@@ -100,6 +100,15 @@ setup_firmware_path() {
echo -n /lib/firmware/postmarketos >$SYS
}
# shellcheck disable=SC3043
load_modules() {
local file="$1"
local modules="$2"
[ -f "$file" ] && modules="$modules $(grep -v ^\# "$file")"
# shellcheck disable=SC2086
modprobe -a $modules
}
setup_udev() {
if ! command -v udevd > /dev/null || ! command -v udevadm > /dev/null; then
echo "ERROR: udev not found!"