Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

hwmon: (ltc4245) 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.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>

+4 -4
+4 -4
drivers/hwmon/ltc4245.c
··· 362 362 case hwmon_in_input: 363 363 if (channel > 9 && !data->use_extra_gpios) 364 364 return 0; 365 - return S_IRUGO; 365 + return 0444; 366 366 case hwmon_in_min_alarm: 367 367 if (channel > 8) 368 368 return 0; 369 - return S_IRUGO; 369 + return 0444; 370 370 default: 371 371 return 0; 372 372 } ··· 374 374 switch (attr) { 375 375 case hwmon_curr_input: 376 376 case hwmon_curr_max_alarm: 377 - return S_IRUGO; 377 + return 0444; 378 378 default: 379 379 return 0; 380 380 } 381 381 case hwmon_power: 382 382 switch (attr) { 383 383 case hwmon_power_input: 384 - return S_IRUGO; 384 + return 0444; 385 385 default: 386 386 return 0; 387 387 }