mirror of
https://github.com/torvalds/linux.git
synced 2024-11-11 14:42:24 +00:00
power: supply: core: Constify static struct attribute_group
The only usage of it is to put its address in an array of pointers to const static structs. Make it const to allow the compiler to put it in read-only memory. Signed-off-by: Rikard Falkeborn <rikard.falkeborn@gmail.com> Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
This commit is contained in:
parent
249aacc6a3
commit
2f7cf24f42
@ -374,7 +374,7 @@ static umode_t power_supply_attr_is_visible(struct kobject *kobj,
|
||||
return 0;
|
||||
}
|
||||
|
||||
static struct attribute_group power_supply_attr_group = {
|
||||
static const struct attribute_group power_supply_attr_group = {
|
||||
.attrs = __power_supply_attrs,
|
||||
.is_visible = power_supply_attr_is_visible,
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user