+
+static inline int smfs_do_cow(struct inode *inode)
+{
+ struct super_block *sb = inode->i_sb;
+ struct smfs_super_info *smfs_info = S2SMI(sb);
+
+ if (SMFS_DO_COW(smfs_info) && SMFS_DO_INODE_COW(inode))
+ return 1;
+ return 0;
+}
+
+
+/* XXX BUG 3188 -- must return to one set of opcodes */
+#define SMFS_TRANS_OP(inode, op) \
+{ \
+ if (smfs_do_rec(inode)) \
+ op = op | 0x10; \
+ if (smfs_cache_hook(inode)) \
+ op = op | 0x20; \
+}
+
+extern int smfs_start_rec(struct super_block *sb, struct vfsmount *mnt);
+extern int smfs_stop_rec(struct super_block *sb);
+extern int smfs_write_extents(struct inode *dir, struct dentry *dentry,
+ unsigned long from, unsigned long num);
+extern int smfs_rec_setattr(struct inode *dir, struct dentry *dentry,
+ struct iattr *attr);
+extern int smfs_rec_precreate(struct dentry *dentry, int *num, struct obdo *oa);
+extern int smfs_rec_md(struct inode *inode, void * lmm, int lmm_size);
+extern int smfs_rec_unpack(struct smfs_proc_args *args, char *record,
+ char **pbuf, int *opcode);
+
+
+extern int smfs_post_setup(struct super_block *sb, struct vfsmount *mnt);
+extern int smfs_post_cleanup(struct super_block *sb);
+extern struct inode *smfs_get_inode (struct super_block *sb, ino_t hash,
+ struct inode *dir, int index);
+
+extern int is_smfs_sb(struct super_block *sb);