aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md/persistent-data/dm-space-map-metadata.h
diff options
context:
space:
mode:
authorDmitry Torokhov <dmitry.torokhov@gmail.com>2011-11-29 01:51:07 -0800
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2011-11-29 01:51:07 -0800
commit0d2cd91bf7b1a7cc1d638296111fcc2bcf5c0bb4 (patch)
treed2ca69347816c27f9dc352581f5d0fe76811cd49 /drivers/md/persistent-data/dm-space-map-metadata.h
parentInput: elantech - add resolution query support for v4 hardware (diff)
parentLinux 3.2-rc3 (diff)
downloadlinux-dev-0d2cd91bf7b1a7cc1d638296111fcc2bcf5c0bb4.tar.xz
linux-dev-0d2cd91bf7b1a7cc1d638296111fcc2bcf5c0bb4.zip
Merge commit 'v3.2-rc3' into next
Diffstat (limited to 'drivers/md/persistent-data/dm-space-map-metadata.h')
-rw-r--r--drivers/md/persistent-data/dm-space-map-metadata.h33
1 files changed, 33 insertions, 0 deletions
diff --git a/drivers/md/persistent-data/dm-space-map-metadata.h b/drivers/md/persistent-data/dm-space-map-metadata.h
new file mode 100644
index 000000000000..39bba0801cf2
--- /dev/null
+++ b/drivers/md/persistent-data/dm-space-map-metadata.h
@@ -0,0 +1,33 @@
+/*
+ * Copyright (C) 2011 Red Hat, Inc.
+ *
+ * This file is released under the GPL.
+ */
+
+#ifndef DM_SPACE_MAP_METADATA_H
+#define DM_SPACE_MAP_METADATA_H
+
+#include "dm-transaction-manager.h"
+
+/*
+ * Unfortunately we have to use two-phase construction due to the cycle
+ * between the tm and sm.
+ */
+struct dm_space_map *dm_sm_metadata_init(void);
+
+/*
+ * Create a fresh space map.
+ */
+int dm_sm_metadata_create(struct dm_space_map *sm,
+ struct dm_transaction_manager *tm,
+ dm_block_t nr_blocks,
+ dm_block_t superblock);
+
+/*
+ * Open from a previously-recorded root.
+ */
+int dm_sm_metadata_open(struct dm_space_map *sm,
+ struct dm_transaction_manager *tm,
+ void *root_le, size_t len);
+
+#endif /* DM_SPACE_MAP_METADATA_H */