summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorErnestas Kulik <ernestas.kulik@gmail.com>2017-01-24 20:40:49 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2017-01-27 11:40:56 +0300
commitb40b4bc5fb06e957ab800a08a0b4d00b6e667ba4 (patch)
tree48465896cfff27cabdcf3511959f9c6fbe421d90
parent74e3bb75315ce62a4567f2871276bab32802e8b4 (diff)
downloadlinux-b40b4bc5fb06e957ab800a08a0b4d00b6e667ba4.tar.xz
staging: lustre: libcfs: use octal permissions
Using octal permissions instead of symbolic ones is preferred. Signed-off-by: Ernestas Kulik <ernestas.kulik@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/staging/lustre/lnet/libcfs/module.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/staging/lustre/lnet/libcfs/module.c b/drivers/staging/lustre/lnet/libcfs/module.c
index 161e04226521..c388550c2d10 100644
--- a/drivers/staging/lustre/lnet/libcfs/module.c
+++ b/drivers/staging/lustre/lnet/libcfs/module.c
@@ -488,10 +488,10 @@ static const struct file_operations lnet_debugfs_file_operations_wo = {
static const struct file_operations *lnet_debugfs_fops_select(umode_t mode)
{
- if (!(mode & S_IWUGO))
+ if (!(mode & 0222))
return &lnet_debugfs_file_operations_ro;
- if (!(mode & S_IRUGO))
+ if (!(mode & 0444))
return &lnet_debugfs_file_operations_wo;
return &lnet_debugfs_file_operations_rw;