PM: sleep: Constify static struct attribute_group

The only usage of suspend_attr_group is to put its address in an
array of pointers to const attribute_group structs.

Make it const to allow the compiler to put it into read-only memory.

Signed-off-by: Rikard Falkeborn <rikard.falkeborn@gmail.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
This commit is contained in:
Rikard Falkeborn 2021-02-01 23:57:35 +01:00 committed by Rafael J. Wysocki
parent eb23d91af5
commit 1556057413
1 changed files with 1 additions and 1 deletions

View File

@ -387,7 +387,7 @@ static struct attribute *suspend_attrs[] = {
NULL,
};
static struct attribute_group suspend_attr_group = {
static const struct attribute_group suspend_attr_group = {
.name = "suspend_stats",
.attrs = suspend_attrs,
};