summary refs log tree commit diff
path: root/dracut/61-mtd.rules
diff options
context:
space:
mode:
authorChristian Neukirchen <chneukirchen@gmail.com>2015-05-02 01:01:17 +0200
committerJuan RP <xtraeme@voidlinux.eu>2015-05-02 12:16:21 +0200
commit929175a025254315fd0773d1af23943233616db8 (patch)
treebc7b06a8b5c0ae4fcbeefa4600518b0df0acbf1e /dracut/61-mtd.rules
parent1571ef8d4495c61f7061996d78c5f45db590930b (diff)
downloadhrmpf-929175a025254315fd0773d1af23943233616db8.tar.gz
hrmpf-929175a025254315fd0773d1af23943233616db8.tar.xz
hrmpf-929175a025254315fd0773d1af23943233616db8.zip
Support for MEMDISK
The .iso can now be booted using Grub (memdisk from Syslinux package):

	linux16 /memdisk
	initrd16 /path/to/iso

As well as from Syslinux:

	LINUX memdisk
	INITRD path/to/iso
Diffstat (limited to 'dracut/61-mtd.rules')
-rw-r--r--dracut/61-mtd.rules20
1 files changed, 20 insertions, 0 deletions
diff --git a/dracut/61-mtd.rules b/dracut/61-mtd.rules
new file mode 100644
index 0000000..0711d3a
--- /dev/null
+++ b/dracut/61-mtd.rules
@@ -0,0 +1,20 @@
+SUBSYSTEM!="block", GOTO="pss_end"
+ACTION!="add|change", GOTO="pss_end"
+# Also don't process disks that are slated to be a multipath device
+ENV{DM_MULTIPATH_DEVICE_PATH}=="?*", GOTO="pss_end"
+
+ACTION=="change", KERNEL=="dm-[0-9]*", ENV{DM_UDEV_DISABLE_OTHER_RULES_FLAG}!="1", GOTO="do_pss"
+KERNEL=="mtdblock*", GOTO="do_pss"
+
+GOTO="pss_end"
+
+LABEL="do_pss"
+# by-path (parent device path)
+ENV{DEVTYPE}=="disk", ENV{ID_PATH}=="", DEVPATH!="*/virtual/*", IMPORT PATH_ID
+ENV{DEVTYPE}=="disk", ENV{ID_PATH}=="?*", SYMLINK+="disk/by-path/$env{ID_PATH}"
+ENV{DEVTYPE}=="partition", ENV{ID_PATH}=="?*", SYMLINK+="disk/by-path/$env{ID_PATH}-part%n"
+
+# by-label/by-uuid links (filesystem metadata)
+ENV{ID_FS_USAGE}=="filesystem|other|crypto", ENV{ID_FS_UUID_ENC}=="?*", SYMLINK+="disk/by-uuid/$env{ID_FS_UUID_ENC}"
+ENV{ID_FS_USAGE}=="filesystem|other", ENV{ID_FS_LABEL_ENC}=="?*", SYMLINK+="disk/by-label/$env{ID_FS_LABEL_ENC}"
+LABEL="pss_end"