4 struct smfs_inode_info {
5 struct inode *smi_inode;
8 struct smfs_super_info {
9 struct super_block *smsi_sb;
10 struct vfsmount *smsi_mnt; /* mount the cache kere with kern_do_mount (like MDS) */
14 #define I2SMI(inode) ((struct smfs_inode_info *) (&(inode->u.generic_ip)))
15 #define S2SMI(sb) ((struct smfs_super_info *) (&(sb->u.generic_sbp)))
16 #define S2CSB(sb) (((struct smfs_super_info *) (&(sb->u.generic_sbp)))->smsi_sb)
17 #define I2CI(inode) (((struct smfs_inode_info*) (&(inode->u.generic_ip)))->smi_inode)
19 #define SB_OPS_CHECK 0x1
20 #define INODE_OPS_CHECK 0x2
21 #define FILE_OPS_CHECK 0x4
22 #define DENTRY_OPS_CHECK 0x8
23 #define DEV_OPS_CHECK 0x10
24 #define SYMLINK_OPS_CHECK 0x20
25 #define DIR_OPS_CHECK 0x40
27 #include "smfs_support.h"
29 /* operations on the file store */
30 struct super_operations sm_sb_ops;
32 struct inode_operations sm_dir_iops;
33 struct inode_operations sm_file_iops;
34 struct inode_operations sm_sym_iops;
36 struct file_operations sm_dir_fops;
37 struct file_operations sm_file_fops;
38 struct file_operations sm_sym_fops;
40 struct address_space_operations sm_file_aops;
41 struct dentry_operations sm_dentry_ops;
47 struct list_head list;
50 extern int get_opt(struct option **option, char **pos);
51 extern void cleanup_option(void);
52 extern int init_option(char *data);
54 void sm_setup_inode_ops(struct inode *cache_inode, struct inode *inode);
55 void sm_set_sb_ops(struct super_block *cache_sb, struct super_block *sb);
56 void init_smfs_cache(void);
57 void cleanup_smfs_cache(void);
60 extern int sm_debug_level;
62 extern long sm_kmemory;
64 #endif /* __LINUX_SNAPFS_H */