Skip to content

Commit

Permalink
PM / QoS: constify *_attribute_group.
Browse files Browse the repository at this point in the history
File size before:
   text	   data	    bss	    dec	    hex	filename
   3890	   1152	      8	   5050	   13ba	drivers/base/power/sysfs.o

File size After adding 'const':
   text	   data	    bss	    dec	    hex	filename
   4250	    800	      8	   5058	   13c2	drivers/base/power/sysfs.o

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
Acked-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
  • Loading branch information
Arvind Yadav authored and Rafael J. Wysocki committed Jun 27, 2017
1 parent c0bc126 commit dbb1d8b
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions drivers/base/power/sysfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -607,7 +607,7 @@ static struct attribute *power_attrs[] = {
#endif /* CONFIG_PM_ADVANCED_DEBUG */
NULL,
};
static struct attribute_group pm_attr_group = {
static const struct attribute_group pm_attr_group = {
.name = power_group_name,
.attrs = power_attrs,
};
Expand All @@ -629,7 +629,7 @@ static struct attribute *wakeup_attrs[] = {
#endif
NULL,
};
static struct attribute_group pm_wakeup_attr_group = {
static const struct attribute_group pm_wakeup_attr_group = {
.name = power_group_name,
.attrs = wakeup_attrs,
};
Expand All @@ -644,7 +644,7 @@ static struct attribute *runtime_attrs[] = {
&dev_attr_autosuspend_delay_ms.attr,
NULL,
};
static struct attribute_group pm_runtime_attr_group = {
static const struct attribute_group pm_runtime_attr_group = {
.name = power_group_name,
.attrs = runtime_attrs,
};
Expand All @@ -653,7 +653,7 @@ static struct attribute *pm_qos_resume_latency_attrs[] = {
&dev_attr_pm_qos_resume_latency_us.attr,
NULL,
};
static struct attribute_group pm_qos_resume_latency_attr_group = {
static const struct attribute_group pm_qos_resume_latency_attr_group = {
.name = power_group_name,
.attrs = pm_qos_resume_latency_attrs,
};
Expand All @@ -662,7 +662,7 @@ static struct attribute *pm_qos_latency_tolerance_attrs[] = {
&dev_attr_pm_qos_latency_tolerance_us.attr,
NULL,
};
static struct attribute_group pm_qos_latency_tolerance_attr_group = {
static const struct attribute_group pm_qos_latency_tolerance_attr_group = {
.name = power_group_name,
.attrs = pm_qos_latency_tolerance_attrs,
};
Expand All @@ -672,7 +672,7 @@ static struct attribute *pm_qos_flags_attrs[] = {
&dev_attr_pm_qos_remote_wakeup.attr,
NULL,
};
static struct attribute_group pm_qos_flags_attr_group = {
static const struct attribute_group pm_qos_flags_attr_group = {
.name = power_group_name,
.attrs = pm_qos_flags_attrs,
};
Expand Down

0 comments on commit dbb1d8b

Please sign in to comment.