diff options
| author | Thomas Weißschuh <linux@weissschuh.net> | 2026-08-06 08:09:13 +0200 |
|---|---|---|
| committer | Guenter Roeck <linux@roeck-us.net> | 2026-08-10 08:59:43 -0700 |
| commit | 87fdc8d7bb64d6f6669fa8daf4c59940387df07e (patch) | |
| tree | 1e84b169fd5a53839b75ac3e421002ad334acfd9 /tools/perf/scripts/python | |
| parent | 52fcdd5639dc0cc2701a7d035e6d05adfd393f73 (diff) | |
hwmon: (sysfs) Allow drivers to register const attributes
Switch to the __DEVICE_ATTR() macro which can handle callbacks taking
both const and non-const attribute structure arguments.
Allow the step-wise migration of the drivers.
Also use container_of_const() over container_of() to avoid casting away
the constness accidentally.
Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
Link: https://lore.kernel.org/r/20260806-sysfs-const-attr-hwmon-v2-3-22fee8b85509@weissschuh.net
[groeck: Squashed 'hwmon: (core) Constify PEC device attribute']
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions
