summaryrefslogtreecommitdiffstats
path: root/mdadm.h
diff options
context:
space:
mode:
authorKinga Stefaniuk <kinga.stefaniuk@intel.com>2024-05-07 05:38:56 +0200
committerMariusz Tkaczyk <mariusz.tkaczyk@linux.intel.com>2024-05-14 11:08:06 +0200
commitaa1cc5815d2b14a8b47add18cfaa8264e19c10ce (patch)
tree19b8e321caa9d3107ca951b26c735e06372fea8c /mdadm.h
parentutil.c: change devnm to const in mdmon functions (diff)
downloadmdadm-aa1cc5815d2b14a8b47add18cfaa8264e19c10ce.tar.xz
mdadm-aa1cc5815d2b14a8b47add18cfaa8264e19c10ce.zip
Wait for mdmon when it is stared via systemd
When mdmon is being started it may need few seconds to start. For now, we didn't wait for it. Introduce wait_for_mdmon() function, which waits up to 5 seconds for mdmon to start completely. Signed-off-by: Kinga Stefaniuk <kinga.stefaniuk@intel.com> Signed-off-by: Mariusz Tkaczyk <mariusz.tkaczyk@linux.intel.com>
Diffstat (limited to 'mdadm.h')
-rw-r--r--mdadm.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/mdadm.h b/mdadm.h
index 1ba541fc..b71d7b32 100644
--- a/mdadm.h
+++ b/mdadm.h
@@ -1770,6 +1770,8 @@ extern struct superswitch *version_to_superswitch(char *vers);
extern int mdmon_running(const char *devnm);
extern int mdmon_pid(const char *devnm);
+extern mdadm_status_t wait_for_mdmon(const char *devnm);
+
extern int check_env(char *name);
extern __u32 random32(void);
extern void random_uuid(__u8 *buf);