]>
Commit | Line | Data |
---|---|---|
4c880565 AM |
1 | diff --git a/geninitrd b/geninitrd |
2 | index 7b962b5..a4de196 100755 | |
3 | --- a/geninitrd | |
4 | +++ b/geninitrd | |
5 | @@ -1103,8 +1103,7 @@ sym_exists() { | |
6 | # find best compressor (or forced one) for initrd | |
7 | find_compressor() { | |
8 | local mode="$1" | |
9 | - # fastest initrd decompression speed is first | |
10 | - local compressors='lzo gzip xz lzma bzip2' | |
11 | + local compressors='xz lzma bzip2 gzip lzo' | |
12 | ||
13 | # a specified one, take it | |
14 | if ! is_yes "$mode"; then | |
15 | diff --git a/mod-md.sh b/mod-md.sh | |
16 | index a0cd7aa..d9093d4 100644 | |
17 | --- a/mod-md.sh | |
18 | +++ b/mod-md.sh | |
19 | @@ -139,13 +139,15 @@ initrd_gen_md() { | |
20 | ||
21 | inst_exec $mdassemble /bin/mdassemble | |
22 | ||
23 | + echo "DEVICE partitions containers" >> "$DESTDIR/etc/mdadm.conf" | |
24 | + | |
25 | # LVM on RAID case | |
26 | local dev_list_extra ex_dev | |
27 | dev_list_extra=$(awk '/^DEVICE / { for (i=2; i<=NF; i++) { printf "%s ", $i; }; } ' /etc/mdadm.conf | xargs) | |
28 | new_dev_list_extra="" | |
29 | for ex_dev in $dev_list_extra; do | |
30 | - if [ "$ex_dev" = "partitions" ]; then | |
31 | - echo "DEVICE partitions" >> "$DESTDIR/etc/mdadm.conf" | |
32 | + if [ "$ex_dev" = "partitions" -o "$ex_dev" = "containers" ]; then | |
33 | + echo "DEVICE $ex_dev" >> "$DESTDIR/etc/mdadm.conf" | |
34 | # FIXME: find and copy partition devices from /proc/partitions | |
35 | # - best if done at runtime, now initrd gen time | |
36 | continue | |
f9045633 AM |
37 | commit 11202855dbaee5bc32209913df1ae8738c210c39 |
38 | Author: Arkadiusz Miśkiewicz <arekm@maven.pl> | |
39 | Date: Sat May 14 00:36:02 2016 +0200 | |
40 | ||
41 | Make rootdev fallback work. | |
42 | ||
43 | diff --git a/geninitrd b/geninitrd | |
44 | index 92a519d..771245e 100755 | |
45 | --- a/geninitrd | |
46 | +++ b/geninitrd | |
47 | @@ -1004,7 +1004,11 @@ initrd_gen_initramfs_switchroot() { | |
48 | ||
49 | # XXX hack, fallback to rootdev from geninitrd time | |
50 | if [ ! -e "$device" ]; then | |
51 | + EOF | |
52 | + add_linuxrc <<-EOF | |
53 | device="$rootdev" | |
54 | + EOF | |
55 | + add_linuxrc <<-'EOF' | |
56 | echo "DEVICE set to $device based on fstab entry from initrd gen time" | |
57 | fi | |
58 | ||
95e49aad AM |
59 | commit 583a7f5f8783fb1f92b75ca9f651d675df016b73 |
60 | Author: Arkadiusz Miśkiewicz <arekm@maven.pl> | |
61 | Date: Tue Jun 7 08:30:46 2016 +0200 | |
62 | ||
63 | Mount /run with 0755. | |
64 | ||
65 | diff --git a/geninitrd b/geninitrd | |
66 | index 771245e..62e47ee 100755 | |
67 | --- a/geninitrd | |
68 | +++ b/geninitrd | |
69 | @@ -273,7 +273,7 @@ mount_run() { | |
70 | fi | |
71 | ||
72 | run_mounted=yes | |
73 | - echo "mount -t tmpfs run /run" | add_linuxrc | |
74 | + echo "mount -t tmpfs run /run -o mode=0755" | add_linuxrc | |
75 | } | |
76 | ||
77 | # unmount all mountpoints mounted by geninitrd | |
59e121d4 AM |
78 | commit b5a01dda8ca06f88b1210f806f3ac6da7c0019f0 |
79 | Author: Arkadiusz Miśkiewicz <arekm@maven.pl> | |
80 | Date: Fri May 4 15:50:18 2018 +0200 | |
81 | ||
82 | ext4 can use crc32 but has it in softdep only | |
83 | ||
84 | diff --git a/geninitrd b/geninitrd | |
85 | index 0a18298..c75c22b 100755 | |
86 | --- a/geninitrd | |
87 | +++ b/geninitrd | |
88 | @@ -435,6 +435,9 @@ find_depmod() { | |
89 | warn "mounting multidevice btrfs volume requires rootfsflags=device=/dev/...,device=/dev/... kernel option" | |
90 | find_depmod "-libcrc32c" | |
91 | ;; | |
92 | + ext4) | |
93 | + find_depmod "-libcrc32c" | |
94 | + ;; | |
95 | crc-t10dif) | |
96 | find_depmod "-crct10dif-pclmul" | |
97 | find_depmod "-crct10dif" | |
ce25c101 AM |
98 | commit 256e0bedb591a982ce87fb2ca1b38e1353d5b33a |
99 | Author: Arkadiusz Miśkiewicz <arekm@maven.pl> | |
100 | Date: Fri Aug 10 10:40:59 2018 +0200 | |
101 | ||
102 | ramdisk_size warning makes no sense for initramfs. | |
103 | ||
104 | diff --git a/geninitrd b/geninitrd | |
105 | index c75c22b..025674d 100755 | |
106 | --- a/geninitrd | |
107 | +++ b/geninitrd | |
108 | @@ -1759,14 +1759,16 @@ case "$INITRDFS" in | |
109 | die "Filesystem $INITRDFS not supported by $PROGRAM" | |
110 | esac | |
111 | ||
112 | -CONFIG_BLK_DEV_RAM_SIZE=$(ikconfig | awk -F= '/^CONFIG_BLK_DEV_RAM_SIZE/{print $2}') | |
113 | -if [ -z "$CONFIG_BLK_DEV_RAM_SIZE" ]; then | |
114 | - CONFIG_BLK_DEV_RAM_SIZE=4096 | |
115 | - warn "No CONFIG_BLK_DEV_RAM_SIZE detected, fallback to $CONFIG_BLK_DEV_RAM_SIZE" | |
116 | -fi | |
117 | +if [ "$INITRDFS" != "initramfs" ]; then | |
118 | + CONFIG_BLK_DEV_RAM_SIZE=$(ikconfig | awk -F= '/^CONFIG_BLK_DEV_RAM_SIZE/{print $2}') | |
119 | + if [ -z "$CONFIG_BLK_DEV_RAM_SIZE" ]; then | |
120 | + CONFIG_BLK_DEV_RAM_SIZE=4096 | |
121 | + warn "No CONFIG_BLK_DEV_RAM_SIZE detected, fallback to $CONFIG_BLK_DEV_RAM_SIZE" | |
122 | + fi | |
123 | ||
124 | -if [ "$IMAGESIZE" -gt $CONFIG_BLK_DEV_RAM_SIZE ]; then | |
125 | - warn "Your image size is larger than $CONFIG_BLK_DEV_RAM_SIZE, Be sure to boot kernel with ramdisk_size=$IMAGESIZE!" | |
126 | + if [ "$IMAGESIZE" -gt $CONFIG_BLK_DEV_RAM_SIZE ]; then | |
127 | + warn "Your image size is larger than $CONFIG_BLK_DEV_RAM_SIZE, Be sure to boot kernel with ramdisk_size=$IMAGESIZE!" | |
128 | + fi | |
129 | fi | |
130 | ||
131 | if ! is_no "$COMPRESS"; then |