Whamcloud - gitweb
LU-216 ldiskfs: use proper arguments for ldiskfs_free_blocks
[fs/lustre-release.git] / libcfs / libcfs / winnt / winnt-module.c
index a0feb7d..e44f28f 100644 (file)
@@ -1,6 +1,4 @@
-/* -*- mode: c; c-basic-offset: 8; indent-tabs-mode: nil; -*-
- * vim:expandtab:shiftwidth=8:tabstop=8:
- *
+/*
  * GPL HEADER START
  *
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -51,7 +49,7 @@ int libcfs_ioctl_getdata(char *buf, char *end, void *arg)
         hdr = (struct libcfs_ioctl_hdr *)buf;
         data = (struct libcfs_ioctl_data *)buf;
 
-        err = cfs_copy_from_user(buf, (void *)arg, sizeof(*hdr));
+       err = copy_from_user(buf, (void *)arg, sizeof(*hdr));
         if (err)
                 RETURN(err);
 
@@ -70,7 +68,7 @@ int libcfs_ioctl_getdata(char *buf, char *end, void *arg)
                 RETURN(-EINVAL);
         }
 
-        err = cfs_copy_from_user(buf, (void *)arg, hdr->ioc_len);
+       err = copy_from_user(buf, (void *)arg, hdr->ioc_len);
         if (err)
                 RETURN(err);
 
@@ -91,16 +89,16 @@ int libcfs_ioctl_getdata(char *buf, char *end, void *arg)
 
 int libcfs_ioctl_popdata(void *arg, void *data, int size)
 {
-       if (cfs_copy_to_user((char *)arg, data, size))
+       if (copy_to_user((char *)arg, data, size))
                return -EFAULT;
        return 0;
 }
-                                                                                                                                                                       
-extern struct cfs_psdev_ops          libcfs_psdev_ops;
 
-static int 
-libcfs_psdev_open(struct inode *in, cfs_file_t * file)
-{ 
+extern struct cfs_psdev_ops libcfs_psdev_ops;
+
+static int
+libcfs_psdev_open(struct inode *in, struct file *file)
+{
        struct libcfs_device_userstate **pdu = NULL;
        int    rc = 0;
 
@@ -113,8 +111,8 @@ libcfs_psdev_open(struct inode *in, cfs_file_t * file)
 }
 
 /* called when closing /dev/device */
-static int 
-libcfs_psdev_release(struct inode *in, cfs_file_t * file)
+static int
+libcfs_psdev_release(struct inode *in, struct file *file)
 {
        struct libcfss_device_userstate *pdu;
        int    rc = 0;
@@ -127,9 +125,9 @@ libcfs_psdev_release(struct inode *in, cfs_file_t * file)
        return rc;
 }
 
-static int 
-libcfs_ioctl(cfs_file_t * file, unsigned int cmd, ulong_ptr_t arg)
-{ 
+static int
+libcfs_ioctl(struct file *file, unsigned int cmd, ulong_ptr_t arg)
+{
        struct cfs_psdev_file    pfile;
        int    rc = 0;
 
@@ -176,7 +174,7 @@ static struct file_operations libcfs_fops = {
     /* release:*/ libcfs_psdev_release
 };
 
-cfs_psdev_t libcfs_dev = { 
+struct miscdevice libcfs_dev = {
        LIBCFS_MINOR, 
        "lnet", 
        &libcfs_fops