diff options
author | Jes Sorensen <jsorensen@fb.com> | 2017-04-13 13:30:17 -0400 |
---|---|---|
committer | Jes Sorensen <jsorensen@fb.com> | 2017-04-20 00:12:34 -0400 |
commit | 3ab8f4bf33d906cb1084f7b4036556bfb4bb73ec (patch) | |
tree | d868dedbd7309ab70ed2f48ad2d5e6f245578285 /mdadm.h | |
parent | 5e4ca8bb82e98400c9258cb3d7e4d030576f21df (diff) | |
download | mdadm-3ab8f4bf33d906cb1084f7b4036556bfb4bb73ec.tar.gz |
util: Introduce md_array_active() helper
Rather than querying md_get_array_info() to determine whether an array
is valid, do the work in md_array_active() using sysfs, and fall back
on md_get_array_info() if sysfs fails.
Signed-off-by: Jes Sorensen <jsorensen@fb.com>
Diffstat (limited to 'mdadm.h')
-rw-r--r-- | mdadm.h | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -1415,6 +1415,7 @@ extern int Dump_metadata(char *dev, char *dir, struct context *c, extern int Restore_metadata(char *dev, char *dir, struct context *c, struct supertype *st, int only); +int md_array_active(int fd); int md_get_array_info(int fd, struct mdu_array_info_s *array); int md_set_array_info(int fd, struct mdu_array_info_s *array); int md_get_disk_info(int fd, struct mdu_disk_info_s *disk); |