mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 02:32:09 -04:00
treewide: Use DEVICE_ATTR_RW
Convert DEVICE_ATTR uses to DEVICE_ATTR_RW 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*S_IWUSR|\s*S_IWUSR\s*\|\s*S_IRUGO\s*|\s*0644\s*)\)?\s*,\s*\1_show\s*,\s*\1_store\s*\)/DEVICE_ATTR_RW(\1)/g; print;}'
Signed-off-by: Joe Perches <[email protected]>
Acked-by: Felipe Balbi <[email protected]>
Acked-by: Andy Shevchenko <[email protected]>
Acked-by: Bartlomiej Zolnierkiewicz <[email protected]>
Acked-by: Zhang Rui <[email protected]>
Acked-by: Jarkko Nikula <[email protected]>
Acked-by: Jani Nikula <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
This commit is contained in:
parent
353c6ddaa9
commit
b6b996b6cd
14 changed files with 48 additions and 79 deletions
|
|
@ -600,7 +600,7 @@ static ssize_t vpm_show(struct device *dev, struct device_attribute *attr,
|
|||
static DEVICE_ATTR(devtype, 0444, devtype_show, NULL);
|
||||
static DEVICE_ATTR(cutype, 0444, cutype_show, NULL);
|
||||
static DEVICE_ATTR(modalias, 0444, modalias_show, NULL);
|
||||
static DEVICE_ATTR(online, 0644, online_show, online_store);
|
||||
static DEVICE_ATTR_RW(online);
|
||||
static DEVICE_ATTR(availability, 0444, available_show, NULL);
|
||||
static DEVICE_ATTR(logging, 0200, NULL, initiate_logging);
|
||||
static DEVICE_ATTR(vpm, 0444, vpm_show, NULL);
|
||||
|
|
|
|||
Loading…
Reference in a new issue