1
2
3
4
5
6
7
8
9
10
11
12
13
14
15 #ifndef _OCFS1_FS_COMPAT_H
16 #define _OCFS1_FS_COMPAT_H
17
18 #define OCFS1_MAX_VOL_SIGNATURE_LEN 128
19 #define OCFS1_MAX_MOUNT_POINT_LEN 128
20 #define OCFS1_MAX_VOL_ID_LENGTH 16
21 #define OCFS1_MAX_VOL_LABEL_LEN 64
22 #define OCFS1_MAX_CLUSTER_NAME_LEN 64
23
24 #define OCFS1_MAJOR_VERSION (2)
25 #define OCFS1_MINOR_VERSION (0)
26 #define OCFS1_VOLUME_SIGNATURE "OracleCFS"
27
28
29
30
31 struct ocfs1_vol_disk_hdr
32 {
33 __u32 minor_version;
34 __u32 major_version;
35 __u8 signature[OCFS1_MAX_VOL_SIGNATURE_LEN];
36 __u8 mount_point[OCFS1_MAX_MOUNT_POINT_LEN];
37 __u64 serial_num;
38 __u64 device_size;
39 __u64 start_off;
40 __u64 bitmap_off;
41 __u64 publ_off;
42 __u64 vote_off;
43 __u64 root_bitmap_off;
44 __u64 data_start_off;
45 __u64 root_bitmap_size;
46 __u64 root_off;
47 __u64 root_size;
48 __u64 cluster_size;
49 __u64 num_nodes;
50 __u64 num_clusters;
51 __u64 dir_node_size;
52 __u64 file_node_size;
53 __u64 internal_off;
54 __u64 node_cfg_off;
55 __u64 node_cfg_size;
56 __u64 new_cfg_off;
57 __u32 prot_bits;
58 __s32 excl_mount;
59
60 };
61
62
63 struct ocfs1_disk_lock
64 {
65 __u32 curr_master;
66 __u8 file_lock;
67 __u8 compat_pad[3];
68
69
70 __u64 last_write_time;
71 __u64 last_read_time;
72 __u32 writer_node_num;
73 __u32 reader_node_num;
74 __u64 oin_node_map;
75 __u64 dlock_seq_num;
76
77 };
78
79
80
81
82 struct ocfs1_vol_label
83 {
84 struct ocfs1_disk_lock disk_lock;
85 __u8 label[OCFS1_MAX_VOL_LABEL_LEN];
86 __u16 label_len;
87 __u8 vol_id[OCFS1_MAX_VOL_ID_LENGTH];
88 __u16 vol_id_len;
89 __u8 cluster_name[OCFS1_MAX_CLUSTER_NAME_LEN];
90 __u16 cluster_name_len;
91
92 };
93
94
95 #endif
96