mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 03:27:44 -04:00
treewide: Use DEVICE_ATTR_RO
Convert DEVICE_ATTR uses to DEVICE_ATTR_RO where possible.
Done with perl script:
$ git grep -w --name-only DEVICE_ATTR | \
xargs perl -i -e 'local $/; while (<>) { s/\bDEVICE_ATTR\s*\(\s*(\w+)\s*,\s*\(?(?:\s*S_IRUGO\s*|\s*0444\s*)\)?\s*,\s*\1_show\s*,\s*NULL\s*\)/DEVICE_ATTR_RO(\1)/g; print;}'
Signed-off-by: Joe Perches <[email protected]>
Acked-by: Rafael J. Wysocki <[email protected]>
Acked-by: Robert Jarzmik <[email protected]>
Acked-by: Sagi Grimberg <[email protected]>
Acked-by: Zhang Rui <[email protected]>
Acked-by: Harald Freudenberger <[email protected]>
Acked-by: Jani Nikula <[email protected]>
Acked-by: Corey Minyard <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
This commit is contained in:
parent
b6b996b6cd
commit
c828a89203
15 changed files with 54 additions and 57 deletions
|
|
@ -396,10 +396,10 @@ create_s32_tzp_attr(offset);
|
|||
* All the attributes created for tzp (create_s32_tzp_attr) also are always
|
||||
* present on the sysfs interface.
|
||||
*/
|
||||
static DEVICE_ATTR(type, 0444, type_show, NULL);
|
||||
static DEVICE_ATTR(temp, 0444, temp_show, NULL);
|
||||
static DEVICE_ATTR_RO(type);
|
||||
static DEVICE_ATTR_RO(temp);
|
||||
static DEVICE_ATTR_RW(policy);
|
||||
static DEVICE_ATTR(available_policies, S_IRUGO, available_policies_show, NULL);
|
||||
static DEVICE_ATTR_RO(available_policies);
|
||||
static DEVICE_ATTR_RW(sustainable_power);
|
||||
|
||||
/* These thermal zone device attributes are created based on conditions */
|
||||
|
|
|
|||
Loading…
Reference in a new issue