]> git.ipfire.org Git - thirdparty/dracut-ng.git/commitdiff
chore: move net udev rules to net-lib dracut modules
authorJo Zzsi <jozzsicsataban@gmail.com>
Sat, 20 Dec 2025 18:46:23 +0000 (13:46 -0500)
committerNeal Gompa (ニール・ゴンパ) <ngompa13@gmail.com>
Tue, 6 Jan 2026 00:47:03 +0000 (19:47 -0500)
The net-lib dracut module is designed to be always installed when
networking is enabled in the generated initramfs.

Move networking related udev rules to net-lib dracut modules from the
udev-rules dracut module.

The motivation behind this change is to increase modularity,
stay consistent with other dracut modules and potentially
increase performance when networking is not required in the
initramfs.

modules.d/45net-lib/module-setup.sh
modules.d/74udev-rules/module-setup.sh

index 42835ff535808f9130a1e0e1f89b1f56c76c9482..3bc415255ffb0f06ab4f42d6f7f5976a78772d68 100755 (executable)
@@ -17,6 +17,12 @@ installkernel() {
 }
 
 install() {
+    inst_rules \
+        75-net-description.rules \
+        80-net-name-slot.rules \
+        80-net-setup-link.rules \
+        81-net-dhcp.rules
+
     inst_script "$moddir/netroot.sh" "/sbin/netroot"
     inst_simple "$moddir/net-lib.sh" "/lib/net-lib.sh"
     inst_hook pre-udev 50 "$moddir/ifname-genrules.sh"
index b30eafda6c3d03463acb600e299a499b6312e36a..8f50c8f7221abeb099481454868278be82aef4c4 100755 (executable)
@@ -51,13 +51,9 @@ install() {
         70-uaccess.rules \
         71-seat.rules \
         73-seat-late.rules \
-        75-net-description.rules \
         75-probe_mtd.rules \
         78-sound-card.rules \
         80-drivers.rules \
-        80-net-name-slot.rules \
-        80-net-setup-link.rules \
-        81-net-dhcp.rules \
         95-udev-late.rules
 
     {