Thread (40 messages) 40 messages, 6 authors, 2025-01-22

Re: [PATCH v1 00/21] hwmon: Fix the type of 'config' in struct hwmon_channel_info to u64

From: Guenter Roeck <linux@roeck-us.net>
Date: 2025-01-21 17:37:57
Also in: arm-scmi, linux-arm-kernel, linux-hwmon, linux-media, linux-rdma, linux-rtc, lkml, platform-driver-x86

On 1/21/25 09:20, Russell King (Oracle) wrote:
[ ... ]
1. convert *all* drivers that defines a config array to be defined by
    their own macro in hwmon.h, and then switch that macro to make the
    definitions be a u64 array at the same time as switching struct
     hwmon_channel_info.config

2. convert *all* drivers to use HWMON_CHANNEL_INFO() unconditionally,
    and switch that along with struct hwmon_channel_info.config.

3. add a new member to struct hwmon_channel_info such as
    "const u64 *config64" and then gradually convert drivers to use it.
    Once everyone is converted over, then remove "const u32 *config",
    optionally rename "config64" back to "config" and then re-patch all
    drivers. That'll be joyful, with multiple patches to drivers that
    need to be merged in sync with hwmon changes - and last over several
    kernel release cycles.
Alternatively, add another sensor type for the overflowing field, such as
hwmon_power_2 (or whatever), and use it for the additional attributes.
This is not going to be an easy change!
Neither is it necessary at this time.

Guenter
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help