Re: [PATCH] hwmon: (pmbus/core) notify on the hwmon device, not the i2c client

Guenter Roeck <[email protected]>
Newsgroups org.kernel.vger.linux-hwmon,dev.linux.lists.sashiko-reviews
Message-ID <[email protected]>
On 7/23/26 09:18, Vincent Jardin wrote:
> Hi Bot,
> 
>> Pre-existing issues:
>> - [High] Type confusion in pmbus_notify() causes out-of-bounds read and dropped hardware alarms.
>    ...
>> [Severity: High]
>> This isn't a bug introduced by this patch, but I noticed a potential type
>> confusion issue here while reviewing the notification logic.
>>
>> Does the loop in pmbus_notify() safely handle heterogeneous attribute types?
>    ...
>> If so, it seems this could prematurely clear bits from flags via
>> flags &= ~smask and silently drop legitimate hardware alarms before
>> reaching the actual boolean alarm attribute.
> 
> It seems you are right and they are pre-existing behaviours.
> 
> However, this fix is independent of this behaviour. It moves
> the notification target from i2c client kobject to the hwmon
> kobject device.
> 

My conclusion as well. I'll apply your patch and try to find a fix
for the above problem.

Thanks,
Guenter
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.