11 #include <linux/module.h>
12 #include <linux/kernel.h>
14 #include <linux/string.h>
15 #include <linux/stat.h>
16 #include <linux/errno.h>
22 #include <linux/slab.h>
24 #include <asm/uaccess.h>
29 #include <linux/coda.h>
30 #include <linux/coda_psdev.h>
37 static void coda_evict_inode(
struct inode *);
63 static void coda_destroy_inode(
struct inode *inode)
68 static void init_once(
void *
foo)
81 if (coda_inode_cachep ==
NULL)
105 .alloc_inode = coda_alloc_inode,
106 .destroy_inode = coda_destroy_inode,
107 .evict_inode = coda_evict_inode,
108 .put_super = coda_put_super,
110 .remount_fs = coda_remount,
120 printk(
"coda_read_super: Bad mount data\n");
125 printk(
"coda_read_super: Bad mount version\n");
132 inode =
f.file->f_path.dentry->d_inode;
142 printk(
"coda_read_super: Bad minor number\n");
148 printk(
"coda_read_super: Bad file\n");
152 static int coda_fill_super(
struct super_block *sb,
void *data,
int silent)
172 printk(
"coda_read_super: No pseudo device\n");
178 printk(
"coda_read_super: Device already mounted\n");
195 sb->
s_op = &coda_super_operations;
202 printk(
"coda_read_super: coda_get_rootfid failed with %d\n",
211 error = PTR_ERR(root);
212 printk(
"Failure of coda_cnode_make for root: error %d\n", error);
216 printk(
"coda_read_super: rootinode is %ld dev %s\n",
244 printk(
"Coda: Bye bye.\n");
247 static void coda_evict_inode(
struct inode *inode)
264 struct inode *inode = de->
d_inode;
268 memset(&vattr, 0,
sizeof(vattr));
316 int flags,
const char *dev_name,
void *data)
318 return mount_nodev(fs_type, flags, data, coda_fill_super);