aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md/md.h
diff options
context:
space:
mode:
authorNeilBrown <neilb@suse.de>2009-03-30 23:39:39 -0400
committerNeilBrown <neilb@suse.de>2009-03-30 23:39:39 -0400
commit245f46c2c221ef09c7db892f0e3fc2149be42052 (patch)
treebe7e6f4b7b65b682c43e59ef17f7ed580bc8a82b /drivers/md/md.h
parent409c57f3801701dfee27a28103dda4831306cb20 (diff)
md: add ->takeover method to support changing the personality managing an array
Implement this for RAID6 to be able to 'takeover' a RAID5 array. The new RAID6 will use a layout which places Q on the last device, and that device will be missing. If there are any available spares, one will immediately have Q recovered onto it. Signed-off-by: NeilBrown <neilb@suse.de>
Diffstat (limited to 'drivers/md/md.h')
-rw-r--r--drivers/md/md.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/md/md.h b/drivers/md/md.h
index 84b22d67ba14..8034f62a9d28 100644
--- a/drivers/md/md.h
+++ b/drivers/md/md.h
@@ -321,6 +321,16 @@ struct mdk_personality
321 * others - reserved 321 * others - reserved
322 */ 322 */
323 void (*quiesce) (mddev_t *mddev, int state); 323 void (*quiesce) (mddev_t *mddev, int state);
324 /* takeover is used to transition an array from one
325 * personality to another. The new personality must be able
326 * to handle the data in the current layout.
327 * e.g. 2drive raid1 -> 2drive raid5
328 * ndrive raid5 -> degraded n+1drive raid6 with special layout
329 * If the takeover succeeds, a new 'private' structure is returned.
330 * This needs to be installed and then ->run used to activate the
331 * array.
332 */
333 void *(*takeover) (mddev_t *mddev);
324}; 334};
325 335
326 336