mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-11 04:18:39 +08:00
hwmon: (core) Make hwmon_class const
Now that the driver core allows for struct class to be in read-only memory, mark hwmon_class as const. Signed-off-by: Thomas Weißschuh <linux@weissschuh.net> Link: https://lore.kernel.org/r/20240614-class-const-hwmon-v1-1-27b910d06a90@weissschuh.net Signed-off-by: Guenter Roeck <linux@roeck-us.net>
This commit is contained in:
parent
dc5abc2ff0
commit
52115fc329
@ -137,7 +137,7 @@ static void hwmon_dev_release(struct device *dev)
|
||||
kfree(hwdev);
|
||||
}
|
||||
|
||||
static struct class hwmon_class = {
|
||||
static const struct class hwmon_class = {
|
||||
.name = "hwmon",
|
||||
.dev_groups = hwmon_dev_attr_groups,
|
||||
.dev_release = hwmon_dev_release,
|
||||
|
Loading…
Reference in New Issue
Block a user