diff options
author | Joel Becker <joel.becker@oracle.com> | 2008-02-01 15:08:23 -0800 |
---|---|---|
committer | Mark Fasheh <mfasheh@suse.com> | 2008-04-18 08:56:05 -0700 |
commit | b61817e1166c5e19c08baf05196477cc345e1b1a (patch) | |
tree | 8da1c387086313aecdbb8f96fd0ab33417860620 /fs/ocfs2/ocfs2.h | |
parent | 74ae4e104dfc57017783fc07d5f2f9129062207f (diff) | |
download | linux-3.10-b61817e1166c5e19c08baf05196477cc345e1b1a.tar.gz linux-3.10-b61817e1166c5e19c08baf05196477cc345e1b1a.tar.bz2 linux-3.10-b61817e1166c5e19c08baf05196477cc345e1b1a.zip |
ocfs2: Add the USERSPACE_STACK incompat bit.
The filesystem gains the USERSPACE_STACK incomat bit and the
s_cluster_info field on the superblock. When a userspace stack is in
use, the name of the stack is stored on-disk for mount-time
verification.
The "cluster_stack" option is added to mount(2) processing. The mount
process needs to pass the matching stack name. If the passed name and
the on-disk name do not match, the mount is failed.
When using the classic o2cb stack, the incompat bit is *not* set and no
mount option is used other than the usual heartbeat=local. Thus, the
filesystem is compatible with older tools.
Signed-off-by: Joel Becker <joel.becker@oracle.com>
Signed-off-by: Mark Fasheh <mfasheh@suse.com>
Diffstat (limited to 'fs/ocfs2/ocfs2.h')
-rw-r--r-- | fs/ocfs2/ocfs2.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/fs/ocfs2/ocfs2.h b/fs/ocfs2/ocfs2.h index af929eca541..9ff5811345a 100644 --- a/fs/ocfs2/ocfs2.h +++ b/fs/ocfs2/ocfs2.h @@ -248,6 +248,7 @@ struct ocfs2_super struct ocfs2_alloc_stats alloc_stats; char dev_str[20]; /* "major,minor" of the device */ + char osb_cluster_stack[OCFS2_STACK_LABEL_LEN + 1]; struct ocfs2_cluster_connection *cconn; struct ocfs2_lock_res osb_super_lockres; struct ocfs2_lock_res osb_rename_lockres; @@ -368,6 +369,12 @@ static inline int ocfs2_is_soft_readonly(struct ocfs2_super *osb) return ret; } +static inline int ocfs2_userspace_stack(struct ocfs2_super *osb) +{ + return (osb->s_feature_incompat & + OCFS2_FEATURE_INCOMPAT_USERSPACE_STACK); +} + static inline int ocfs2_mount_local(struct ocfs2_super *osb) { return (osb->s_feature_incompat & OCFS2_FEATURE_INCOMPAT_LOCAL_MOUNT); |