diff options
author | Dan Williams <dan.j.williams@intel.com> | 2008-09-15 20:58:43 -0700 |
---|---|---|
committer | Dan Williams <dan.j.williams@intel.com> | 2008-09-15 20:58:43 -0700 |
commit | 313a4a82f130e6668ba0f4550200662e168aa945 (patch) | |
tree | 56f6b17ba26b00684153bbbc976dd1c1f825b122 /msg.h | |
parent | 4795982e68f72ef44bd29c9883e5f6291088a3e1 (diff) | |
download | mdadm-313a4a82f130e6668ba0f4550200662e168aa945.tar.gz |
ping_manager() to prevent 'add' before 'remove' completes
It is currently possible to remove a device and re-add it without the
manager noticing, i.e. without detecting a mdstat->devcnt
container->devcnt mismatch. Introduce ping_manager() to arrange for
mdmon to run manage_container() prior to mdadm dropping the exclusive
open() on the container. Despite these precautions sysfs_read() may
still fail. If this happens invalidate container->devcnt to ensure
manage_container() runs at the next event.
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'msg.h')
-rw-r--r-- | msg.h | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -27,5 +27,6 @@ extern int ack(int fd, int tmo); extern int wait_reply(int fd, int tmo); extern int connect_monitor(char *devname); extern int ping_monitor(char *devname); +extern int ping_manager(char *devname); #define MSG_MAX_LEN (4*1024*1024) |