2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-19 02:34:01 +08:00

hwmon: (applesmc) Replace S_<PERMS> with octal values

Replace S_<PERMS> with octal values.

The conversion was done automatically with coccinelle. The semantic patches
and the scripts used to generate this commit log are available at
https://github.com/groeck/coccinelle-patches/hwmon/.

This patch does not introduce functional changes. It was verified by
compiling the old and new files and comparing text and data sizes.

Cc: Henrik Rydberg <rydberg@bitmath.org>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
This commit is contained in:
Guenter Roeck 2018-12-10 14:02:03 -08:00
parent a7818350f6
commit 71ee4a4000

View File

@ -1128,7 +1128,7 @@ static int applesmc_create_nodes(struct applesmc_node_group *groups, int num)
attr = &node->sda.dev_attr.attr; attr = &node->sda.dev_attr.attr;
sysfs_attr_init(attr); sysfs_attr_init(attr);
attr->name = node->name; attr->name = node->name;
attr->mode = S_IRUGO | (grp->store ? S_IWUSR : 0); attr->mode = 0444 | (grp->store ? 0200 : 0);
ret = sysfs_create_file(&pdev->dev.kobj, attr); ret = sysfs_create_file(&pdev->dev.kobj, attr);
if (ret) { if (ret) {
attr->name = NULL; attr->name = NULL;