aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/block
diff options
context:
space:
mode:
authorAlex Elder <elder@inktank.com>2012-07-10 21:30:10 -0400
committerAlex Elder <elder@inktank.com>2012-10-01 15:30:53 -0400
commit3bb59ad515527fa75cf71d997d17cea18160da74 (patch)
treef93f9b6f42df400e2b989e1c9d24c3f0f77b83a9 /drivers/block
parentf8d4de6e1c939d56f1ee0a21ad677401846f990c (diff)
rbd: define some new format constants
Define constant symbols related to the rbd format 2 object names. This begins to bring this version of the "rbd_types.h" header more in line with the current user-space version of that file. Complete reconciliation of differences will be done at some point later, as a separate task. Signed-off-by: Alex Elder <elder@inktank.com> Reviewed-by: Josh Durgin <josh.durgin@inktank.com>
Diffstat (limited to 'drivers/block')
-rw-r--r--drivers/block/rbd_types.h25
1 files changed, 20 insertions, 5 deletions
diff --git a/drivers/block/rbd_types.h b/drivers/block/rbd_types.h
index d9d8a77748bc..cbe77fa105ba 100644
--- a/drivers/block/rbd_types.h
+++ b/drivers/block/rbd_types.h
@@ -15,15 +15,30 @@
15 15
16#include <linux/types.h> 16#include <linux/types.h>
17 17
18/* For format version 2, rbd image 'foo' consists of objects
19 * rbd_id.foo - id of image
20 * rbd_header.<id> - image metadata
21 * rbd_data.<id>.0000000000000000
22 * rbd_data.<id>.0000000000000001
23 * ... - data
24 * Clients do not access header data directly in rbd format 2.
25 */
26
27#define RBD_HEADER_PREFIX "rbd_header."
28#define RBD_DATA_PREFIX "rbd_data."
29#define RBD_ID_PREFIX "rbd_id."
30
18/* 31/*
19 * rbd image 'foo' consists of objects 32 * For format version 1, rbd image 'foo' consists of objects
20 * foo.rbd - image metadata 33 * foo.rbd - image metadata
21 * foo.00000000 34 * rb.<idhi>.<idlo>.00000000
22 * foo.00000001 35 * rb.<idhi>.<idlo>.00000001
23 * ... - data 36 * ... - data
37 * There is no notion of a persistent image id in rbd format 1.
24 */ 38 */
25 39
26#define RBD_SUFFIX ".rbd" 40#define RBD_SUFFIX ".rbd"
41
27#define RBD_DIRECTORY "rbd_directory" 42#define RBD_DIRECTORY "rbd_directory"
28#define RBD_INFO "rbd_info" 43#define RBD_INFO "rbd_info"
29 44