root/include/linux/nfs_fs.h

/* [previous][next][first][last][top][bottom][index][help] */

INCLUDED FROM


   1 #ifndef _LINUX_NFS_FS_H
   2 #define _LINUX_NFS_FS_H
   3 
   4 /*
   5  *  linux/include/linux/nfs_fs.h
   6  *
   7  *  Copyright (C) 1992  Rick Sladkey
   8  *
   9  *  OS-specific nfs filesystem definitions and declarations
  10  */
  11 
  12 #include <linux/nfs.h>
  13 
  14 #include <netinet/in.h>
  15 #include <linux/nfs_mount.h>
  16 
  17 /*
  18  * The readdir cache size controls how many directory entries are cached.
  19  * Its size is limited by the number of nfs_entry structures that can fit
  20  * in one 4096-byte page, currently 256.
  21  */
  22 
  23 #define NFS_READDIR_CACHE_SIZE          64
  24 
  25 /*
  26  * WARNING!  The I/O buffer size cannot be bigger than about 3900 for now.
  27  * It needs to fit inside a 4096-byte page and leave room for the RPC and
  28  * NFS headers.  But it ought to at least be a multiple of 512 and probably
  29  * should be a power of 2.  I don't think Linux TCP/IP can handle more than
  30  * about 1800 yet.
  31  */
  32 
  33 #define NFS_MAX_FILE_IO_BUFFER_SIZE     (7*512)
  34 #define NFS_DEF_FILE_IO_BUFFER_SIZE     1024
  35 
  36 /*
  37  * The upper limit on timeouts for the exponential backoff algorithm
  38  * in tenths of a second.
  39  */
  40 
  41 #define NFS_MAX_RPC_TIMEOUT             600
  42 
  43 #define NFS_SUPER_MAGIC                 0x6969
  44 
  45 #define NFS_SERVER(inode)               (&(inode)->i_sb->u.nfs_sb.s_server)
  46 #define NFS_FH(inode)                   (&(inode)->u.nfs_i.fhandle)
  47 
  48 /* linux/fs/nfs/proc.c */
  49 
  50 extern int nfs_proc_getattr(struct nfs_server *server, struct nfs_fh *fhandle,
  51                             struct nfs_fattr *fattr);
  52 extern int nfs_proc_setattr(struct nfs_server *server, struct nfs_fh *fhandle,
  53                             struct nfs_sattr *sattr, struct nfs_fattr *fattr);
  54 extern int nfs_proc_lookup(struct nfs_server *server, struct nfs_fh *dir,
  55                            char *name, struct nfs_fh *fhandle,
  56                            struct nfs_fattr *fattr);
  57 extern int nfs_proc_readlink(struct nfs_server *server, struct nfs_fh *fhandle,
  58                              char *res);
  59 extern int nfs_proc_read(struct nfs_server *server, struct nfs_fh *fhandle,
  60                          int offset, int count, char *data,
  61                          struct nfs_fattr *fattr);
  62 extern int nfs_proc_write(struct nfs_server *server, struct nfs_fh *fhandle,
  63                           int offset, int count, char *data,
  64                           struct nfs_fattr *fattr);
  65 extern int nfs_proc_create(struct nfs_server *server, struct nfs_fh *dir,
  66                            char *name, struct nfs_sattr *sattr,
  67                            struct nfs_fh *fhandle, struct nfs_fattr *fattr);
  68 extern int nfs_proc_remove(struct nfs_server *server, struct nfs_fh *dir,
  69                            char *name);
  70 extern int nfs_proc_rename(struct nfs_server *server,
  71                            struct nfs_fh *old_dir, char *old_name,
  72                            struct nfs_fh *new_dir, char *new_name);
  73 extern int nfs_proc_link(struct nfs_server *server, struct nfs_fh *fhandle,
  74                          struct nfs_fh *dir, char *name);
  75 extern int nfs_proc_symlink(struct nfs_server *server, struct nfs_fh *dir,
  76                             char *name, char *path, struct nfs_sattr *sattr);
  77 extern int nfs_proc_mkdir(struct nfs_server *server, struct nfs_fh *dir,
  78                           char *name, struct nfs_sattr *sattr,
  79                           struct nfs_fh *fhandle, struct nfs_fattr *fattr);
  80 extern int nfs_proc_rmdir(struct nfs_server *server, struct nfs_fh *dir,
  81                           char *name);
  82 extern int nfs_proc_readdir(struct nfs_server *server, struct nfs_fh *fhandle,
  83                             int cookie, int count, struct nfs_entry *entry);
  84 extern int nfs_proc_statfs(struct nfs_server *server, struct nfs_fh *fhandle,
  85                             struct nfs_fsinfo *res);
  86 
  87 /* linux/fs/nfs/sock.c */
  88 
  89 extern int nfs_rpc_call(struct nfs_server *server, int *start, int *end);
  90 
  91 /* linux/fs/nfs/inode.c */
  92 
  93 extern struct super_block *nfs_read_super(struct super_block *sb, void *data);
  94 extern struct inode *nfs_fhget(struct super_block *sb, struct nfs_fh *fhandle,
  95                                struct nfs_fattr *fattr);
  96 extern void nfs_refresh_inode(struct inode *inode, struct nfs_fattr *fattr);
  97 
  98 /* linux/fs/nfs/file.c */
  99 
 100 extern struct inode_operations nfs_file_inode_operations;
 101 
 102 /* linux/fs/nfs/dir.c */
 103 
 104 extern struct inode_operations nfs_dir_inode_operations;
 105 
 106 /* linux/fs/nfs/symlink.c */
 107 
 108 extern struct inode_operations nfs_symlink_inode_operations;
 109 
 110 /* linux/fs/nfs/chrdev.c */
 111 
 112 extern struct inode_operations nfs_chrdev_inode_operations;
 113 
 114 /* linux/fs/nfs/blkdev.c */
 115 
 116 extern struct inode_operations nfs_blkdev_inode_operations;
 117 
 118 /* linux/fs/nfs/fifo.c */
 119 
 120 extern struct inode_operations nfs_fifo_inode_operations;
 121 
 122 #endif

/* [previous][next][first][last][top][bottom][index][help] */