summaryrefslogtreecommitdiffstats
path: root/rules.d
diff options
context:
space:
mode:
authorYu Watanabe <watanabe.yu+github@gmail.com>2022-04-13 16:09:14 +0200
committerYu Watanabe <watanabe.yu+github@gmail.com>2022-04-13 17:12:02 +0200
commit9a78ee002f14cf1feeb2d4a13ad9936a2f755e02 (patch)
tree651b27a2850149cbfb21013c4e2a1561cef4d5b8 /rules.d
parentudev: do not create disk/by-diskseq symlink when ID_IGNORE_DISKSEQ property i... (diff)
downloadsystemd-9a78ee002f14cf1feeb2d4a13ad9936a2f755e02.tar.xz
systemd-9a78ee002f14cf1feeb2d4a13ad9936a2f755e02.zip
udev: set ID_IGNORE_DISKSEQ for md devices
Diffstat (limited to 'rules.d')
-rw-r--r--rules.d/50-udev-default.rules.in4
1 files changed, 4 insertions, 0 deletions
diff --git a/rules.d/50-udev-default.rules.in b/rules.d/50-udev-default.rules.in
index 9cdaadb4cd..0394530479 100644
--- a/rules.d/50-udev-default.rules.in
+++ b/rules.d/50-udev-default.rules.in
@@ -4,6 +4,10 @@
ACTION=="remove", ENV{REMOVE_CMD}!="", RUN+="$env{REMOVE_CMD}"
ACTION=="remove", GOTO="default_end"
+# The md driver increments diskseq *after* emitting 'change' uevent.
+# Drop the line below if it is fixed on the kernel side.
+SUBSYSTEM=="block", KERNEL=="md*", ENV{ID_IGNORE_DISKSEQ}="1"
+
SUBSYSTEM=="virtio-ports", KERNEL=="vport*", ATTR{name}=="?*", SYMLINK+="virtio-ports/$attr{name}"
# select "system RTC" or just use the first one