hc
2023-12-06 08f87f769b595151be1afeff53e144f543faa614
kernel/fs/incfs/vfs.h
....@@ -6,8 +6,28 @@
66 #ifndef _INCFS_VFS_H
77 #define _INCFS_VFS_H
88
9
+extern const struct file_operations incfs_file_ops;
10
+extern const struct inode_operations incfs_file_inode_ops;
11
+
912 void incfs_kill_sb(struct super_block *sb);
1013 struct dentry *incfs_mount_fs(struct file_system_type *type, int flags,
1114 const char *dev_name, void *data);
15
+int incfs_link(struct dentry *what, struct dentry *where);
16
+int incfs_unlink(struct dentry *dentry);
17
+
18
+static inline struct mount_info *get_mount_info(struct super_block *sb)
19
+{
20
+ struct mount_info *result = sb->s_fs_info;
21
+
22
+ WARN_ON(!result);
23
+ return result;
24
+}
25
+
26
+static inline struct super_block *file_superblock(struct file *f)
27
+{
28
+ struct inode *inode = file_inode(f);
29
+
30
+ return inode->i_sb;
31
+}
1232
1333 #endif