linux 2.6.16.38 w/ vs2.0.3-rc1
[linux-2.6.git] / fs / xfs / linux-2.6 / xfs_ioctl32.c
index 270db0f..a7c9ba1 100644 (file)
@@ -15,6 +15,7 @@
  * along with this program; if not, write the Free Software Foundation,
  * Inc.,  51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
  */
+#include <linux/config.h>
 #include <linux/compat.h>
 #include <linux/init.h>
 #include <linux/ioctl.h>
@@ -71,7 +72,7 @@ xfs_ioctl32_flock(
            copy_in_user(&p->l_pid,     &p32->l_pid,    sizeof(u32)) ||
            copy_in_user(&p->l_pad,     &p32->l_pad,    4*sizeof(u32)))
                return -EFAULT;
-
+       
        return (unsigned long)p;
 }
 
@@ -106,15 +107,11 @@ xfs_ioctl32_bulkstat(
 #endif
 
 STATIC long
-xfs_compat_ioctl(
-       int             mode,
-       struct file     *file,
-       unsigned        cmd,
-       unsigned long   arg)
+__linvfs_compat_ioctl(int mode, struct file *f, unsigned cmd, unsigned long arg)
 {
-       struct inode    *inode = file->f_dentry->d_inode;
-       bhv_vnode_t     *vp = vn_from_inode(inode);
        int             error;
+       struct          inode *inode = f->f_dentry->d_inode;
+       vnode_t         *vp = LINVFS_GET_VP(inode);
 
        switch (cmd) {
        case XFS_IOC_DIOINFO:
@@ -192,26 +189,26 @@ xfs_compat_ioctl(
                return -ENOIOCTLCMD;
        }
 
-       error = bhv_vop_ioctl(vp, inode, file, mode, cmd, (void __user *)arg);
+       VOP_IOCTL(vp, inode, f, mode, cmd, (void __user *)arg, error);
        VMODIFY(vp);
 
        return error;
 }
 
 long
-xfs_file_compat_ioctl(
-       struct file             *file,
+linvfs_compat_ioctl(
+       struct file             *f,
        unsigned                cmd,
        unsigned long           arg)
 {
-       return xfs_compat_ioctl(0, file, cmd, arg);
+       return __linvfs_compat_ioctl(0, f, cmd, arg);
 }
 
 long
-xfs_file_compat_invis_ioctl(
-       struct file             *file,
+linvfs_compat_invis_ioctl(
+       struct file             *f,
        unsigned                cmd,
        unsigned long           arg)
 {
-       return xfs_compat_ioctl(IO_INVIS, file, cmd, arg);
+       return __linvfs_compat_ioctl(IO_INVIS, f, cmd, arg);
 }