diff options
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/mach-pxa/sharpsl_pm.c | 4 | ||||
-rw-r--r-- | arch/sh/drivers/push-switch.c | 2 | ||||
-rw-r--r-- | arch/tile/kernel/sysfs.c | 10 |
3 files changed, 8 insertions, 8 deletions
diff --git a/arch/arm/mach-pxa/sharpsl_pm.c b/arch/arm/mach-pxa/sharpsl_pm.c index 398ba9ba2632..ef9fd9b759cb 100644 --- a/arch/arm/mach-pxa/sharpsl_pm.c +++ b/arch/arm/mach-pxa/sharpsl_pm.c @@ -802,8 +802,8 @@ static ssize_t battery_voltage_show(struct device *dev, struct device_attribute return sprintf(buf, "%d\n", sharpsl_pm.battstat.mainbat_voltage); } -static DEVICE_ATTR(battery_percentage, 0444, battery_percentage_show, NULL); -static DEVICE_ATTR(battery_voltage, 0444, battery_voltage_show, NULL); +static DEVICE_ATTR_RO(battery_percentage); +static DEVICE_ATTR_RO(battery_voltage); extern void (*apm_get_power_status)(struct apm_power_info *); diff --git a/arch/sh/drivers/push-switch.c b/arch/sh/drivers/push-switch.c index a17181160233..762bc5619910 100644 --- a/arch/sh/drivers/push-switch.c +++ b/arch/sh/drivers/push-switch.c @@ -24,7 +24,7 @@ static ssize_t switch_show(struct device *dev, struct push_switch_platform_info *psw_info = dev->platform_data; return sprintf(buf, "%s\n", psw_info->name); } -static DEVICE_ATTR(switch, S_IRUGO, switch_show, NULL); +static DEVICE_ATTR_RO(switch); static void switch_timer(struct timer_list *t) { diff --git a/arch/tile/kernel/sysfs.c b/arch/tile/kernel/sysfs.c index af5024f0fb5a..b09456a3d77a 100644 --- a/arch/tile/kernel/sysfs.c +++ b/arch/tile/kernel/sysfs.c @@ -38,7 +38,7 @@ static ssize_t chip_width_show(struct device *dev, { return sprintf(page, "%u\n", smp_width); } -static DEVICE_ATTR(chip_width, 0444, chip_width_show, NULL); +static DEVICE_ATTR_RO(chip_width); static ssize_t chip_height_show(struct device *dev, struct device_attribute *attr, @@ -46,7 +46,7 @@ static ssize_t chip_height_show(struct device *dev, { return sprintf(page, "%u\n", smp_height); } -static DEVICE_ATTR(chip_height, 0444, chip_height_show, NULL); +static DEVICE_ATTR_RO(chip_height); static ssize_t chip_serial_show(struct device *dev, struct device_attribute *attr, @@ -54,7 +54,7 @@ static ssize_t chip_serial_show(struct device *dev, { return get_hv_confstr(page, HV_CONFSTR_CHIP_SERIAL_NUM); } -static DEVICE_ATTR(chip_serial, 0444, chip_serial_show, NULL); +static DEVICE_ATTR_RO(chip_serial); static ssize_t chip_revision_show(struct device *dev, struct device_attribute *attr, @@ -62,7 +62,7 @@ static ssize_t chip_revision_show(struct device *dev, { return get_hv_confstr(page, HV_CONFSTR_CHIP_REV); } -static DEVICE_ATTR(chip_revision, 0444, chip_revision_show, NULL); +static DEVICE_ATTR_RO(chip_revision); static ssize_t type_show(struct device *dev, @@ -71,7 +71,7 @@ static ssize_t type_show(struct device *dev, { return sprintf(page, "tilera\n"); } -static DEVICE_ATTR(type, 0444, type_show, NULL); +static DEVICE_ATTR_RO(type); #define HV_CONF_ATTR(name, conf) \ static ssize_t name ## _show(struct device *dev, \ |