diff options
author | Timo Teräs <timo.teras@iki.fi> | 2016-03-11 21:39:03 +0200 |
---|---|---|
committer | Timo Teräs <timo.teras@iki.fi> | 2016-03-11 21:39:03 +0200 |
commit | d3bc637d76eb34fc95de4fefa335f7870063dded (patch) | |
tree | 672c20d0ab01ae4cdfa5e2259630eed712ddd631 /nlplug-findfs.c | |
parent | 130ac62c49a796d558f9b3b6a343bdac870a9cdd (diff) | |
download | mkinitfs-d3bc637d76eb34fc95de4fefa335f7870063dded.tar.bz2 mkinitfs-d3bc637d76eb34fc95de4fefa335f7870063dded.tar.xz |
nlplug-findfs: scan block devices on change
raid disks are created zero sized. when mdadm has found all the
disks it finally enables it. this causes md devices to be zero
sized for some time after their creation, and blkid will not
detect them. catch the 'change' notification and rescan block
devices for updated blkid.
Diffstat (limited to 'nlplug-findfs.c')
-rw-r--r-- | nlplug-findfs.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/nlplug-findfs.c b/nlplug-findfs.c index b93a5a9..5bdb7b1 100644 --- a/nlplug-findfs.c +++ b/nlplug-findfs.c @@ -713,7 +713,7 @@ static int dispatch_uevent(struct uevent *ev, struct ueventconf *conf) } if (ev->subsystem && strcmp(ev->subsystem, "block") == 0 - && strcmp(ev->action, "add") == 0) { + && (strcmp(ev->action, "add") == 0 || strcmp(ev->action, "change") == 0)) { int rc; snprintf(ev->devnode, sizeof(ev->devnode), "/dev/%s", |