diff mbox series

[08/11] touchscreen: melfas: Use octal permissions

Message ID 20180721191029.25658-7-harshitjain6751@gmail.com (mailing list archive)
State Rejected
Headers show
Series [01/11] touchscreen: ft5x06: Use octal permissions | expand

Commit Message

Harshit Jain July 21, 2018, 7:09 p.m. UTC
WARNING: Symbolic permissions 'S_IWUSR' are not preferred. Consider using octal permissions '0200'.
+static DEVICE_ATTR(update_fw, S_IWUSR, NULL, mip4_sysfs_fw_update);

WARNING: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'.
+static DEVICE_ATTR(fw_version, S_IRUGO, mip4_sysfs_read_fw_version, NULL);

WARNING: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'.
+static DEVICE_ATTR(hw_version, S_IRUGO, mip4_sysfs_read_hw_version, NULL);

WARNING: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'.
+static DEVICE_ATTR(product_id, S_IRUGO, mip4_sysfs_read_product_id, NULL);

WARNING: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'.
+static DEVICE_ATTR(ic_name, S_IRUGO, mip4_sysfs_read_ic_name, NULL);

Signed-off-by: dev-harsh1998 <harshitjain6751@gmail.com>
---
 drivers/input/touchscreen/melfas_mip4.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
diff mbox series

Patch

diff --git a/drivers/input/touchscreen/melfas_mip4.c b/drivers/input/touchscreen/melfas_mip4.c
index 430a2bc5f7ca..f7fd940e61ea 100644
--- a/drivers/input/touchscreen/melfas_mip4.c
+++ b/drivers/input/touchscreen/melfas_mip4.c
@@ -1332,7 +1332,7 @@  static ssize_t mip4_sysfs_fw_update(struct device *dev,
 	return count;
 }
 
-static DEVICE_ATTR(update_fw, S_IWUSR, NULL, mip4_sysfs_fw_update);
+static DEVICE_ATTR(update_fw, 0200, NULL, mip4_sysfs_fw_update);
 
 static ssize_t mip4_sysfs_read_fw_version(struct device *dev,
 					  struct device_attribute *attr,
@@ -1354,7 +1354,7 @@  static ssize_t mip4_sysfs_read_fw_version(struct device *dev,
 	return count;
 }
 
-static DEVICE_ATTR(fw_version, S_IRUGO, mip4_sysfs_read_fw_version, NULL);
+static DEVICE_ATTR(fw_version, 0444, mip4_sysfs_read_fw_version, NULL);
 
 static ssize_t mip4_sysfs_read_hw_version(struct device *dev,
 					  struct device_attribute *attr,
@@ -1379,7 +1379,7 @@  static ssize_t mip4_sysfs_read_hw_version(struct device *dev,
 	return count;
 }
 
-static DEVICE_ATTR(hw_version, S_IRUGO, mip4_sysfs_read_hw_version, NULL);
+static DEVICE_ATTR(hw_version, 0444, mip4_sysfs_read_hw_version, NULL);
 
 static ssize_t mip4_sysfs_read_product_id(struct device *dev,
 					  struct device_attribute *attr,
@@ -1398,7 +1398,7 @@  static ssize_t mip4_sysfs_read_product_id(struct device *dev,
 	return count;
 }
 
-static DEVICE_ATTR(product_id, S_IRUGO, mip4_sysfs_read_product_id, NULL);
+static DEVICE_ATTR(product_id, 0444, mip4_sysfs_read_product_id, NULL);
 
 static ssize_t mip4_sysfs_read_ic_name(struct device *dev,
 					  struct device_attribute *attr,
@@ -1418,7 +1418,7 @@  static ssize_t mip4_sysfs_read_ic_name(struct device *dev,
 	return count;
 }
 
-static DEVICE_ATTR(ic_name, S_IRUGO, mip4_sysfs_read_ic_name, NULL);
+static DEVICE_ATTR(ic_name, 0444, mip4_sysfs_read_ic_name, NULL);
 
 static struct attribute *mip4_attrs[] = {
 	&dev_attr_fw_version.attr,