summaryrefslogtreecommitdiff
path: root/drivers/md/md-cluster.h
diff options
context:
space:
mode:
authorGuoqing Jiang <gqjiang@suse.com>2015-12-20 23:51:00 (GMT)
committerNeilBrown <neilb@suse.com>2016-01-06 00:38:57 (GMT)
commitf6a2dc64ee74477c966f5220b1f560ed6308d010 (patch)
treeb371e1cbeb71c2e04e45be01c4964faace6ec400 /drivers/md/md-cluster.h
parent09afd2a8d6ad2c40f3c1ae0b3f83784864cf4c15 (diff)
downloadlinux-f6a2dc64ee74477c966f5220b1f560ed6308d010.tar.xz
md-cluster: append some actions when change bitmap from clustered to none
For clustered raid, we need to do extra actions when change bitmap to none. 1. check if all the bitmap lock could be get or not, if yes then we can continue the change since cluster raid is only active in current node. Otherwise return fail and unlock the related bitmap locks 2. set nodes to 0 and then leave cluster environment. 3. release other nodes's bitmap lock. Signed-off-by: Guoqing Jiang <gqjiang@suse.com> Signed-off-by: NeilBrown <neilb@suse.com>
Diffstat (limited to 'drivers/md/md-cluster.h')
-rw-r--r--drivers/md/md-cluster.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/md/md-cluster.h b/drivers/md/md-cluster.h
index e75ea26..45ce6c9 100644
--- a/drivers/md/md-cluster.h
+++ b/drivers/md/md-cluster.h
@@ -24,6 +24,8 @@ struct md_cluster_operations {
int (*new_disk_ack)(struct mddev *mddev, bool ack);
int (*remove_disk)(struct mddev *mddev, struct md_rdev *rdev);
int (*gather_bitmaps)(struct md_rdev *rdev);
+ int (*lock_all_bitmaps)(struct mddev *mddev);
+ void (*unlock_all_bitmaps)(struct mddev *mddev);
};
#endif /* _MD_CLUSTER_H */