Re: [PATCH v3 RESEND 2/2] scsi: mpt3sas: add hwmon support

From: Louis Sautier

Date: Thu Jun 11 2026 - 12:40:30 EST


On Wed, 10 Jun 2026 08:22:22 +0800, Damien Le Moal wrote:
> > +config SCSI_MPT3SAS_HWMON
> > + bool "LSI MPT Fusion SAS hwmon support"
> > + depends on SCSI_MPT3SAS && HWMON
> > + depends on !(SCSI_MPT3SAS=y && HWMON=m)
> > + help
> > + Say Y here to expose the IOC and board temperature sensors of
> > + LSI / Broadcom SAS HBAs (such as the 9300, 9400, and 9500 series)
> > + through hwmon.
>
> Why do you need this ?

I was following the logic used by NVME_HWMON to prevent issues with
SCSI_MPT3SAS=y and HWMON=m.

> > + struct mpt3sas_hwmon *hwmon;
>
> This should be conditionally defined with "#ifdef CONFIG_HWMON". Then you can
> simply drop the config entry you added.

If I dropped SCSI_MPT3SAS_HWMON, I would use
"#if IS_REACHABLE(CONFIG_HWMON)" to match what i915_hwmon.h and
xe_hwmon.h do and properly handle the SCSI_MPT3SAS=y and HWMON=m case.
What do you think?

> > +static int
>
> Again... Not going to comment on the others.

Noted, I will fix all of them in v4.