aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* mkinitfs: add --quiet to cpio callsnlplug-findfsTimo Teräs2015-12-181-3/+3
|
* mkinitfs: remove missing file warningTimo Teräs2015-12-181-2/+0
| | | | | it is normal that kernel modules or directories are missing in some architectures. don't give unwanted warnings on those.
* build: install mmc.modulesTimo Teräs2015-12-181-0/+1
|
* nlplug-findfs: fix usb settle delayNatanael Copa2015-12-161-10/+14
| | | | | | | kernel does not set any "DRIVER" env var in uevent from netlink so we use kmod to find usb_storage driver. We also reduce the timeout to 1 sec, which should be enough.
* init: add arch crypto modulesNatanael Copa2015-12-153-0/+7
| | | | | we want the faster crypto implementation early for cryptsetup, xfs and btrfs.
* init: fix mount relocationNatanael Copa2015-11-251-28/+29
|
* nlplug-findfs: do not try execute programs that does not existsNatanael Copa2015-11-251-4/+13
| | | | | Avoid printing error message if there are lvm devices but root is not on any of those.
* make: remove kms.filesNatanael Copa2015-11-251-1/+0
|
* nlplug-findfs: print device name user expectsNatanael Copa2015-11-251-1/+2
| | | | | | | we want print the device name that user is looking for when we prompt for cryptsetup password instead of the devname from kernel uevent. If user specified UUID, then we print kernel provided name.
* nlplug-findfs: make lvm more silentNatanael Copa2015-11-251-1/+1
| | | | | we want avoid lvm messages be printed after password prompt for cryptsetup is displayed.
* nlplug-findfs: fix cryptsetup race conditionNatanael Copa2015-11-252-20/+119
| | | | | | | | | | | | | | | | | | | We need run cryptsetup in parallel so that keyboard drivers are loaded while waiting for password input. But cryptsetup will recreate the device which means that the uevent for new device node will first be added then changed and finally will it create the /dev/mapper/* device node. We handle the first generated uevent and while handling, the device node might have disappeared causeing blkid not find any UUID, and the /dev/mapper/* does not yet exist. This means that we need to: - handle uevents in parallel while waiting for password input - block uevent handling while actually setting up the crypt device So we use libcryptsetup and add a mutex while setting up the crypt device.
* nlplug-findfs: use bit mask to indicate running threadNatanael Copa2015-11-251-5/+12
| | | | | Use a bit mask to indicate trigger thread. This is so we can have more threads in future.
* nlplug-findfs: compare device node major/minorNatanael Copa2015-11-241-15/+29
| | | | | | | | | Fix issue where /dev/vg0/lv_device is used as crypt device. We compare the major/minor of the event with the device we are searching for. That way we can find the device we are looking for regardless of the name it gets. ref #4863
* nlplug-findfs: improve debug infoNatanael Copa2015-11-231-2/+3
| | | | | | | - print only once when we reset timeout - print what the timeout was set to on exit This helps to show if what we were looking for was found or not
* mkinitfs: detect automatically firmware modules to copyTimo Teräs2015-10-282-1/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | -rw-r--r-- 1 tteras tteras 13922864 Oct 28 08:38 initramfs-new -rw-r--r-- 1 tteras tteras 12645566 Oct 28 08:27 initramfs-old diff on installed modules: +lib/firmware/matrox/g200_warp.fw +lib/firmware/matrox/g400_warp.fw +lib/firmware/cxgb3/t3c_psram-1.1.0.bin +lib/firmware/cxgb3/ael2020_twx_edc.bin +lib/firmware/cxgb3/t3fw-7.12.0.bin +lib/firmware/cxgb3/ael2005_opt_edc.bin +lib/firmware/cxgb3/t3b_psram-1.1.0.bin +lib/firmware/cxgb3/ael2005_twx_edc.bin +lib/firmware/qlogic/12160.bin +lib/firmware/qlogic/1040.bin +lib/firmware/qlogic/1280.bin +lib/firmware/ql2400_fw.bin +lib/firmware/ql2100_fw.bin +lib/firmware/ene-ub6250/sd_init1.bin +lib/firmware/ene-ub6250/ms_init.bin +lib/firmware/ene-ub6250/ms_rdwr.bin +lib/firmware/ene-ub6250/msp_rdwr.bin +lib/firmware/ene-ub6250/sd_init2.bin +lib/firmware/ene-ub6250/sd_rdwr.bin +lib/firmware/advansys/38C1600.bin +lib/firmware/advansys/mcode.bin +lib/firmware/advansys/38C0800.bin +lib/firmware/advansys/3550.bin +lib/firmware/ql2500_fw.bin +lib/firmware/isci/isci_firmware.bin +lib/firmware/r128/r128_cce.bin +lib/firmware/ql2300_fw.bin +lib/firmware/ql2322_fw.bin -lib/firmware/radeon/TAHITI_vce.bin +lib/firmware/ql2200_fw.bin +lib/firmware/cxgb4 +lib/firmware/cxgb4/t4fw.bin +lib/firmware/cxgb4/t5fw.bin
* nlplug-findfs: asynchronously fork child processesTimo Teräs2015-10-241-82/+185
| | | | | | | | instead of waiting each child to run end before continuing, fork or queue each command allowing up to CPU count concurrent childs. this enables full use of SMP cores, and allows loading of modules after a blocking command is started; fixing e.g. keyboard driver to load even if crypto disk command is waiting keyboard input.
* nlplug-findfs: check for valid key value pair in uevent processingTimo Teräs2015-10-241-1/+1
| | | | just to be on the safe side
* nlplug-findfs: make all functions staticTimo Teräs2015-10-231-16/+14
|
* nlplug-findfs: maintain environment for exec's in arrayTimo Teräs2015-10-231-22/+30
| | | | | | Using clearenv and setenv is slow, non-thread safe and problematic. This makes PATH inherited from parent environment, and explicitly constructs the rest of the environment for mdev.
* nlplug-findfs: support search for /dev/<devname>Natanael Copa2015-10-221-2/+3
| | | | this is so we also can specify cryptroot=/dev/sdaX at boot prompt
* init: also pass cryptopts when looking for apkovl/bootrepoNatanael Copa2015-10-221-7/+8
| | | | in theory we should be able to have apkovl on LUKS device
* init: fix cryptrootNatanael Copa2015-10-221-2/+2
| | | | we need actually pass the $cryptopts to nlplug-findfs
* init: start hwdrivers and modloop unless apkovl is foundNatanael Copa2015-10-201-0/+2
|
* Merge branch 'master' into nlplug-findfsNatanael Copa2015-10-205-17/+18
|\
| * mkinitfs: features should be read from $basedir if setChristian Kampka2015-10-201-1/+1
| |
| * features: virtio: Include virtio_net driversChristian Kampka2015-10-201-0/+1
| |
| * init: remove support for old apk package filesTimo Teräs2015-10-191-6/+1
| | | | | | | | | | | | remove support for /etc/lbu/packages.list (pre historic times) and /var/lib/apk/world (historic times). upgrade from versions using these files is no longer supported.
| * init: fix tmpfs installTimo Teräs2015-10-191-0/+5
| | | | | | | | | | | | | | during tmpfs install, some package scripts and triggers may require access to /dev, /proc or /sys. make sure those are bind mounted to have them available. they are later on move mounted to the new root.
| * init: remove unneeded openrc upgrade actionsTimo Teräs2015-10-131-5/+0
| | | | | | | | | | | | they in fact are harmful, hwdrivers is not needed or even wanted if using eudev. these were only needed for upgrade path from alpine 1.9.x which is no longer supported.
| * init: fix bootchartTimo Teräs2015-10-092-13/+10
| |
* | init: fix typo for fbsplashNatanael Copa2015-10-191-1/+1
| |
* | nlplug-findfs: make sure we handle all events in queueNatanael Copa2015-10-191-1/+7
| | | | | | | | | | | | | | | | | | | | we want handle all the events in queue, even if we find the devices we are looking for. This is so we load kernel module for framebuffer even if the apkvol and bootrepo are found first. This means that the only valid exit condition is a poll timeout and that we can set the timeout to 0 once we found all the things we are looking for.
* | nlplug-findfs: wait indefinitively til trigger thread is completeNatanael Copa2015-10-191-11/+14
| | | | | | | | | | | | make sure that we dont exit before the trigger thread is complete, regardless if we find the devices/bootrepo/apkovl we are looking for or not.
* | nlplug-findfs: use DT_UNKNOWN to detect if lstat is to be usedNatanael Copa2015-10-191-10/+4
| |
* | nlplug-findfs: dont exit before trigger thread is completeNatanael Copa2015-10-141-1/+1
| |
* | init: do not force add hwdrivers and modloopNatanael Copa2015-10-141-5/+0
| | | | | | | | we probably dont support upgrade from the old version it was there for
* | nlplug-findfs: avoid lstat syscall wen scanning /sys if possibleNatanael Copa2015-10-091-5/+18
| | | | | | | | | | | | | | There are ~10k entries in /sys so we want be fast. Not all filesystems supports dirent filed d_type, (iso9660 for example) so we need use lstat to find directories. However, we know that sysfs supports it, so we can avoid 10k lstat syscalls. This might be noticiable difference on rpi.
* | init: run mdev as handler for device modesNatanael Copa2015-10-091-3/+3
| |
* | init: refactor to use nlplug-findfsNatanael Copa2015-10-091-280/+67
| |
* | nlplug-findfs: increase timeout if usb-storage was foundNatanael Copa2015-10-091-1/+11
| | | | | | | | | | usb storage need some time to settle, we increase the timeout with 2 seconds if we detext usb-storage.
* | features: add nlplug-findfs to baseNatanael Copa2015-10-091-0/+1
| |
* | nlplug-findfs: allow user to override timeout with -t optionNatanael Copa2015-10-091-2/+8
| |
* | nlplug-findfs: fix exit codeNatanael Copa2015-10-081-5/+3
| | | | | | | | retun success if anything of what we searched for was found.
* | nlplug-findfs: save stackspace while recursing dir treeNatanael Copa2015-10-081-12/+26
| | | | | | | | | | avoid allocate PATH_MAX on stack for every dir. Instead reuse the path buffer.
* | nlplug-findfs: fix recursing dirs on isofsNatanael Copa2015-10-081-3/+12
| | | | | | | | | | the dirent d_type is not supported on isofs apparently. Use lstat instead.
* | nlplug-findfs: clean up netlink socketNatanael Copa2015-10-081-2/+6
| | | | | | | | we set CLOEXEC with socket create
* | nlplug-findfs: remove mountdir optionNatanael Copa2015-10-081-17/+6
| | | | | | | | | | We will need set optional mount options, so we better do the mount from script.
* | nlplug-findfs: add -a option to find apkovlNatanael Copa2015-10-081-29/+82
| | | | | | | | | | when both apkovl and boot repository are found, then we should have what we need to setup up a working tmpfs root so we exit at that point.
* | nlplug-findfs: add help text for -bNatanael Copa2015-10-081-0/+1
| |
* | nlplug-findfs: search for .boot_repositoryNatanael Copa2015-10-071-44/+137
| | | | | | | | | | add option -b OUTFILE which will create OUTFILE and add first found boot repository