Goldwyn Rodrigues | edb39c9 | 2014-03-29 10:01:53 -0500 | [diff] [blame] | 1 | |
| 2 | |
| 3 | #ifndef _MD_CLUSTER_H |
| 4 | #define _MD_CLUSTER_H |
| 5 | |
| 6 | #include "md.h" |
| 7 | |
| 8 | struct mddev; |
Goldwyn Rodrigues | 1aee41f | 2014-10-29 18:51:31 -0500 | [diff] [blame] | 9 | struct md_rdev; |
Goldwyn Rodrigues | edb39c9 | 2014-03-29 10:01:53 -0500 | [diff] [blame] | 10 | |
| 11 | struct md_cluster_operations { |
Goldwyn Rodrigues | cf921cc | 2014-03-30 00:42:49 -0500 | [diff] [blame] | 12 | int (*join)(struct mddev *mddev, int nodes); |
Goldwyn Rodrigues | edb39c9 | 2014-03-29 10:01:53 -0500 | [diff] [blame] | 13 | int (*leave)(struct mddev *mddev); |
Goldwyn Rodrigues | cf921cc | 2014-03-30 00:42:49 -0500 | [diff] [blame] | 14 | int (*slot_number)(struct mddev *mddev); |
Goldwyn Rodrigues | 96ae923 | 2014-06-06 12:35:34 -0500 | [diff] [blame] | 15 | void (*resync_info_update)(struct mddev *mddev, sector_t lo, sector_t hi); |
Goldwyn Rodrigues | 965400e | 2014-06-07 02:16:58 -0500 | [diff] [blame] | 16 | int (*resync_start)(struct mddev *mddev, sector_t lo, sector_t hi); |
| 17 | void (*resync_finish)(struct mddev *mddev); |
Goldwyn Rodrigues | 293467a | 2014-06-07 01:44:51 -0500 | [diff] [blame] | 18 | int (*metadata_update_start)(struct mddev *mddev); |
| 19 | int (*metadata_update_finish)(struct mddev *mddev); |
| 20 | int (*metadata_update_cancel)(struct mddev *mddev); |
Goldwyn Rodrigues | 589a1c4 | 2014-06-07 02:39:37 -0500 | [diff] [blame] | 21 | int (*area_resyncing)(struct mddev *mddev, sector_t lo, sector_t hi); |
Goldwyn Rodrigues | 1aee41f | 2014-10-29 18:51:31 -0500 | [diff] [blame] | 22 | int (*add_new_disk_start)(struct mddev *mddev, struct md_rdev *rdev); |
| 23 | int (*add_new_disk_finish)(struct mddev *mddev); |
Goldwyn Rodrigues | fa8259d | 2015-03-02 10:55:49 -0600 | [diff] [blame] | 24 | int (*new_disk_ack)(struct mddev *mddev, bool ack); |
Goldwyn Rodrigues | 88bcfef | 2015-04-14 10:44:44 -0500 | [diff] [blame] | 25 | int (*remove_disk)(struct mddev *mddev, struct md_rdev *rdev); |
Goldwyn Rodrigues | 97f6cd3 | 2015-04-14 10:45:42 -0500 | [diff] [blame] | 26 | int (*gather_bitmaps)(struct md_rdev *rdev); |
Goldwyn Rodrigues | edb39c9 | 2014-03-29 10:01:53 -0500 | [diff] [blame] | 27 | }; |
| 28 | |
| 29 | #endif /* _MD_CLUSTER_H */ |