vserver 1.9.3
[linux-2.6.git] / fs / xfs / xfs_fs.h
index 7e1b82c..8290ea7 100644 (file)
@@ -76,6 +76,9 @@ struct fsxattr {
 #define XFS_XFLAG_SYNC         0x00000020      /* all writes synchronous */
 #define XFS_XFLAG_NOATIME      0x00000040      /* do not update access time */
 #define XFS_XFLAG_NODUMP       0x00000080      /* do not include in backups */
+#define XFS_XFLAG_RTINHERIT    0x00000100      /* create with rt bit set */
+#define XFS_XFLAG_PROJINHERIT  0x00000200      /* create with parents projid */
+#define XFS_XFLAG_NOSYMLINKS   0x00000400      /* disallow symlink creation */
 #define XFS_XFLAG_BARRIER      0x00004000      /* chroot() barrier */
 #define XFS_XFLAG_IUNLINK      0x00008000      /* Immutable unlink */
 #define XFS_XFLAG_HASATTR      0x80000000      /* no DIFLAG for this   */
@@ -166,7 +169,7 @@ typedef struct xfs_flock64 {
        __s64           l_start;
        __s64           l_len;          /* len == 0 means until end of file */
        __s32           l_sysid;
-       pid_t           l_pid;
+       __u32           l_pid;
        __s32           l_pad[4];       /* reserve area                     */
 } xfs_flock64_t;
 
@@ -315,10 +318,10 @@ typedef struct xfs_bstat {
  * The user-level BulkStat Request interface structure.
  */
 typedef struct xfs_fsop_bulkreq {
-       __u64           *lastip;        /* last inode # pointer         */
+       __u64           __user *lastip; /* last inode # pointer         */
        __s32           icount;         /* count of entries in buffer   */
-       void            *ubuffer;       /* user buffer for inode desc.  */
-       __s32           *ocount;        /* output count pointer         */
+       void            __user *ubuffer;/* user buffer for inode desc.  */
+       __s32           __user *ocount; /* output count pointer         */
 } xfs_fsop_bulkreq_t;
 
 
@@ -346,12 +349,12 @@ typedef struct xfs_error_injection {
  */
 typedef struct xfs_fsop_handlereq {
        __u32           fd;             /* fd for FD_TO_HANDLE          */
-       void            *path;          /* user pathname                */
+       void            __user *path;   /* user pathname                */
        __u32           oflags;         /* open flags                   */
-       void            *ihandle;       /* user supplied handle         */
+       void            __user *ihandle;/* user supplied handle         */
        __u32           ihandlen;       /* user supplied length         */
-       void            *ohandle;       /* user buffer for handle       */
-       __u32           *ohandlen;      /* user buffer length           */
+       void            __user *ohandle;/* user buffer for handle       */
+       __u32           __user *ohandlen;/* user buffer length          */
 } xfs_fsop_handlereq_t;
 
 /*
@@ -362,35 +365,35 @@ typedef struct xfs_fsop_handlereq {
  */
 
 typedef struct xfs_fsop_setdm_handlereq {
-       struct xfs_fsop_handlereq hreq; /* handle interface structure */
-       struct fsdmidata *data;         /* DMAPI data to set          */
+       struct xfs_fsop_handlereq       hreq;   /* handle information   */
+       struct fsdmidata                __user *data;   /* DMAPI data   */
 } xfs_fsop_setdm_handlereq_t;
 
 typedef struct xfs_attrlist_cursor {
-       __u32   opaque[4];
+       __u32           opaque[4];
 } xfs_attrlist_cursor_t;
 
 typedef struct xfs_fsop_attrlist_handlereq {
-       struct xfs_fsop_handlereq hreq; /* handle interface structure */
-       struct xfs_attrlist_cursor pos; /* opaque cookie, list offset */
-       __u32 flags;                    /* flags, use ROOT/USER names */
-       __u32 buflen;                   /* length of buffer supplied  */
-       void *buffer;                   /* attrlist data to return    */
+       struct xfs_fsop_handlereq       hreq; /* handle interface structure */
+       struct xfs_attrlist_cursor      pos; /* opaque cookie, list offset */
+       __u32                           flags;  /* which namespace to use */
+       __u32                           buflen; /* length of buffer supplied */
+       void                            __user *buffer; /* returned names */
 } xfs_fsop_attrlist_handlereq_t;
 
 typedef struct xfs_attr_multiop {
-       __u32   am_opcode;
-       __s32   am_error;
-       void    *am_attrname;
-       void    *am_attrvalue;
-       __u32   am_length;
-       __u32   am_flags;
+       __u32           am_opcode;
+       __s32           am_error;
+       void            __user *am_attrname;
+       void            __user *am_attrvalue;
+       __u32           am_length;
+       __u32           am_flags;
 } xfs_attr_multiop_t;
 
 typedef struct xfs_fsop_attrmulti_handlereq {
-       struct xfs_fsop_handlereq hreq; /* handle interface structure */
-       __u32 opcount;                  /* count of following multiop */
-       struct xfs_attr_multiop *ops;   /* attr_multi data to get/set */
+       struct xfs_fsop_handlereq       hreq; /* handle interface structure */
+       __u32                           opcount;/* count of following multiop */
+       struct xfs_attr_multiop         __user *ops; /* attr_multi data */
 } xfs_fsop_attrmulti_handlereq_t;
 
 /*
@@ -446,6 +449,13 @@ typedef struct xfs_handle {
 #define XFS_FSOP_GOING_FLAGS_LOGFLUSH          0x1     /* flush log but not data */
 #define XFS_FSOP_GOING_FLAGS_NOLOGFLUSH                0x2     /* don't flush log nor data */
 
+/*
+ * ioctl commands that are used by Linux filesystems
+ */
+#define XFS_IOC_GETXFLAGS      _IOR('f', 1, long)
+#define XFS_IOC_SETXFLAGS      _IOW('f', 2, long)
+#define XFS_IOC_GETVERSION     _IOR('v', 1, long)
+
 /*
  * ioctl commands that replace IRIX fcntl()'s
  * For 'documentation' purposed more than anything else,