V3 file capabilities: alter behavior of cap_setpcap
[safe/jmp/linux-2.6] / include / linux / msdos_fs.h
index 53cee15..f950921 100644 (file)
@@ -1,6 +1,8 @@
 #ifndef _LINUX_MSDOS_FS_H
 #define _LINUX_MSDOS_FS_H
 
+#include <linux/magic.h>
+
 /*
  * The MS-DOS filesystem constants/structures
  */
@@ -18,8 +20,6 @@
 #define CT_LE_L(v)     cpu_to_le32(v)
 
 
-#define MSDOS_SUPER_MAGIC 0x4d44 /* MD */
-
 #define MSDOS_ROOT_INO 1       /* == MINIX_ROOT_INO */
 #define MSDOS_DIR_BITS 5       /* log2(sizeof(struct msdos_dir_entry)) */
 
@@ -146,7 +146,7 @@ struct fat_boot_fsinfo {
 };
 
 struct msdos_dir_entry {
-       __u8    name[8],ext[3]; /* name and extension */
+       __u8    name[MSDOS_NAME];/* name and extension */
        __u8    attr;           /* attribute bits */
        __u8    lcase;          /* Case for base and extension */
        __u8    ctime_cs;       /* Creation time, centiseconds (0-199) */
@@ -204,7 +204,9 @@ struct fat_mount_options {
                 unicode_xlate:1, /* create escape sequences for unhandled Unicode */
                 numtail:1,       /* Does first alias have a numeric '~1' type tail? */
                 atari:1,         /* Use Atari GEMDOS variation of MS-DOS fs */
-                nocase:1;        /* Does this need case conversion? 0=need case conversion*/
+                flush:1,         /* write things quickly */
+                nocase:1,        /* Does this need case conversion? 0=need case conversion*/
+                usefree:1;       /* Use free_clusters for FAT32 */
 };
 
 #define FAT_HASH_BITS  8
@@ -233,7 +235,7 @@ struct msdos_sb_info {
        struct fat_mount_options options;
        struct nls_table *nls_disk;  /* Codepage used on disk */
        struct nls_table *nls_io;    /* Charset used for input and display */
-       void *dir_ops;               /* Opaque; default directory operations */
+       const void *dir_ops;                 /* Opaque; default directory operations */
        int dir_per_block;           /* dir entries per block */
        int dir_per_block_bits;      /* log2(dir_per_block) */
 
@@ -334,7 +336,7 @@ extern int fat_bmap(struct inode *inode, sector_t sector, sector_t *phys,
                    unsigned long *mapped_blocks);
 
 /* fat/dir.c */
-extern struct file_operations fat_dir_operations;
+extern const struct file_operations fat_dir_operations;
 extern int fat_search_long(struct inode *inode, const unsigned char *name,
                           int name_len, struct fat_slot_info *sinfo);
 extern int fat_dir_empty(struct inode *dir);
@@ -397,10 +399,12 @@ extern int fat_count_free_clusters(struct super_block *sb);
 /* fat/file.c */
 extern int fat_generic_ioctl(struct inode *inode, struct file *filp,
                             unsigned int cmd, unsigned long arg);
-extern struct file_operations fat_file_operations;
-extern struct inode_operations fat_file_inode_operations;
+extern const struct file_operations fat_file_operations;
+extern const struct inode_operations fat_file_inode_operations;
 extern int fat_notify_change(struct dentry * dentry, struct iattr * attr);
 extern void fat_truncate(struct inode *inode);
+extern int fat_getattr(struct vfsmount *mnt, struct dentry *dentry,
+                      struct kstat *stat);
 
 /* fat/inode.c */
 extern void fat_attach(struct inode *inode, loff_t i_pos);
@@ -410,8 +414,10 @@ extern struct inode *fat_build_inode(struct super_block *sb,
                        struct msdos_dir_entry *de, loff_t i_pos);
 extern int fat_sync_inode(struct inode *inode);
 extern int fat_fill_super(struct super_block *sb, void *data, int silent,
-                       struct inode_operations *fs_dir_inode_ops, int isvfat);
+                       const struct inode_operations *fs_dir_inode_ops, int isvfat);
 
+extern int fat_flush_inodes(struct super_block *sb, struct inode *i1,
+                           struct inode *i2);
 /* fat/misc.c */
 extern void fat_fs_panic(struct super_block *s, const char *fmt, ...);
 extern void fat_clusters_flush(struct super_block *sb);