Whamcloud - gitweb
b=16774 cancel unused osc locks before replay.
[fs/lustre-release.git] / libcfs / libcfs / linux / linux-module.c
index 88eab3e..d290172 100644 (file)
@@ -26,7 +26,7 @@
  * GPL HEADER END
  */
 /*
- * Copyright  2008 Sun Microsystems, Inc. All rights reserved
+ * Copyright (c) 2008, 2010, Oracle and/or its affiliates. All rights reserved.
  * Use is subject to license terms.
  */
 /*
@@ -84,7 +84,7 @@ int libcfs_ioctl_getdata(char *buf, char *end, void *arg)
 
         if (data->ioc_inllen2)
                 data->ioc_inlbuf2 = &data->ioc_bulk[0] +
-                        size_round(data->ioc_inllen1);
+                        cfs_size_round(data->ioc_inllen1);
 
         RETURN(0);
 }
@@ -138,7 +138,7 @@ libcfs_ioctl(struct inode *inode, struct file *file,
        struct cfs_psdev_file    pfile;
        int    rc = 0;
 
-       if (current->fsuid != 0)
+       if (current_fsuid() != 0)
                return -EACCES;
 
        if ( _IOC_TYPE(cmd) != IOC_LIBCFS_TYPE ||