summaryrefslogtreecommitdiff
path: root/drivers/md/raid0.h
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2009-03-31 07:27:03 +0400
committerNeilBrown <neilb@suse.de>2009-03-31 07:27:03 +0400
commitef740c372dfd80e706dbf955d4e4aedda6c0c148 (patch)
tree8d9ef9db346ee1ba319a125c9de83cdde049510d /drivers/md/raid0.h
parent2a40a8aed083d988df6822bb9b1b08fb7ce21e1d (diff)
downloadlinux-ef740c372dfd80e706dbf955d4e4aedda6c0c148.tar.xz
md: move headers out of include/linux/raid/
Move the headers with the local structures for the disciplines and bitmap.h into drivers/md/ so that they are more easily grepable for hacking and not far away. md.h is left where it is for now as there are some uses from the outside. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: NeilBrown <neilb@suse.de>
Diffstat (limited to 'drivers/md/raid0.h')
-rw-r--r--drivers/md/raid0.h30
1 files changed, 30 insertions, 0 deletions
diff --git a/drivers/md/raid0.h b/drivers/md/raid0.h
new file mode 100644
index 000000000000..fd42aa87c391
--- /dev/null
+++ b/drivers/md/raid0.h
@@ -0,0 +1,30 @@
+#ifndef _RAID0_H
+#define _RAID0_H
+
+#include <linux/raid/md.h>
+
+struct strip_zone
+{
+ sector_t zone_start; /* Zone offset in md_dev (in sectors) */
+ sector_t dev_start; /* Zone offset in real dev (in sectors) */
+ sector_t sectors; /* Zone size in sectors */
+ int nb_dev; /* # of devices attached to the zone */
+ mdk_rdev_t **dev; /* Devices attached to the zone */
+};
+
+struct raid0_private_data
+{
+ struct strip_zone **hash_table; /* Table of indexes into strip_zone */
+ struct strip_zone *strip_zone;
+ mdk_rdev_t **devlist; /* lists of rdevs, pointed to by strip_zone->dev */
+ int nr_strip_zones;
+
+ sector_t spacing;
+ int sector_shift; /* shift this before divide by spacing */
+};
+
+typedef struct raid0_private_data raid0_conf_t;
+
+#define mddev_to_conf(mddev) ((raid0_conf_t *) mddev->private)
+
+#endif