[PATCH v8 0/6] mfd: Add support for NXP MC33978/MC34978 MSDI

Oleksij Rempel posted 6 patches 4 days, 1 hour ago
There is a newer version of this series
.../bindings/pinctrl/nxp,mc33978.yaml         | 158 +++
drivers/hwmon/Kconfig                         |  10 +
drivers/hwmon/Makefile                        |   1 +
drivers/hwmon/mc33978-hwmon.c                 | 548 ++++++++++
drivers/mfd/Kconfig                           |  15 +
drivers/mfd/Makefile                          |   2 +
drivers/mfd/mc33978.c                         | 988 ++++++++++++++++++
drivers/mux/Kconfig                           |  14 +
drivers/mux/Makefile                          |   2 +
drivers/mux/mc33978-mux.c                     | 136 +++
drivers/pinctrl/Kconfig                       |  14 +
drivers/pinctrl/Makefile                      |   1 +
drivers/pinctrl/core.c                        |  41 +-
drivers/pinctrl/pinconf.c                     |   9 +-
drivers/pinctrl/pinctrl-mc33978.c             | 839 +++++++++++++++
include/linux/mfd/mc33978.h                   |  92 ++
16 files changed, 2863 insertions(+), 7 deletions(-)
create mode 100644 Documentation/devicetree/bindings/pinctrl/nxp,mc33978.yaml
create mode 100644 drivers/hwmon/mc33978-hwmon.c
create mode 100644 drivers/mfd/mc33978.c
create mode 100644 drivers/mux/mc33978-mux.c
create mode 100644 drivers/pinctrl/pinctrl-mc33978.c
create mode 100644 include/linux/mfd/mc33978.h
[PATCH v8 0/6] mfd: Add support for NXP MC33978/MC34978 MSDI
Posted by Oleksij Rempel 4 days, 1 hour ago
changes v7:
- drop gpiolib irq fix and make pinctrl more robust against NULL point
  dereference.

This series adds support for the NXP MC33978/MC34978 Multiple Switch Detection
Interface (MSDI) via the MFD framework.

Architecture overview:
* mfd: Core driver handling 2-frame pipelined SPI, regulator sequencing, and
  linear irq_domain. Harvests status bits from SPI MISO MSB.
* pinctrl: Exposes 22 physical switch inputs as standard GPIOs. Proxies IRQs to
  the MFD domain.
* hwmon: Exposes thermal limits, VBATP/VDDQ voltage boundaries, and dynamic
  fault alarms.
* mux: Controls the 24-to-1 AMUX routing analog signals (switch voltages,
  temperature, VBATP) to an external ADC.

Initial pinctrl implementation by David Jander, reworked into this MFD
architecture.

Best regards,
Oleksij

David Jander (1):
  pinctrl: add NXP MC33978/MC34978 pinctrl driver

Oleksij Rempel (5):
  dt-bindings: pinctrl: add NXP MC33978/MC34978 MSDI
  mfd: add NXP MC33978/MC34978 core driver
  pinctrl: core: Make pin group callbacks optional for pin-only drivers
  hwmon: add NXP MC33978/MC34978 driver
  mux: add NXP MC33978/MC34978 AMUX driver

 .../bindings/pinctrl/nxp,mc33978.yaml         | 158 +++
 drivers/hwmon/Kconfig                         |  10 +
 drivers/hwmon/Makefile                        |   1 +
 drivers/hwmon/mc33978-hwmon.c                 | 548 ++++++++++
 drivers/mfd/Kconfig                           |  15 +
 drivers/mfd/Makefile                          |   2 +
 drivers/mfd/mc33978.c                         | 988 ++++++++++++++++++
 drivers/mux/Kconfig                           |  14 +
 drivers/mux/Makefile                          |   2 +
 drivers/mux/mc33978-mux.c                     | 136 +++
 drivers/pinctrl/Kconfig                       |  14 +
 drivers/pinctrl/Makefile                      |   1 +
 drivers/pinctrl/core.c                        |  41 +-
 drivers/pinctrl/pinconf.c                     |   9 +-
 drivers/pinctrl/pinctrl-mc33978.c             | 839 +++++++++++++++
 include/linux/mfd/mc33978.h                   |  92 ++
 16 files changed, 2863 insertions(+), 7 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/pinctrl/nxp,mc33978.yaml
 create mode 100644 drivers/hwmon/mc33978-hwmon.c
 create mode 100644 drivers/mfd/mc33978.c
 create mode 100644 drivers/mux/mc33978-mux.c
 create mode 100644 drivers/pinctrl/pinctrl-mc33978.c
 create mode 100644 include/linux/mfd/mc33978.h

--
2.47.3
Re: [PATCH v8 0/6] mfd: Add support for NXP MC33978/MC34978 MSDI
Posted by Guenter Roeck 3 days, 19 hours ago
Hi Oleksij,

On 3/29/26 02:05, Oleksij Rempel wrote:
> changes v7:
> - drop gpiolib irq fix and make pinctrl more robust against NULL point
>    dereference.
> 
> This series adds support for the NXP MC33978/MC34978 Multiple Switch Detection
> Interface (MSDI) via the MFD framework.
> 
> Architecture overview:
> * mfd: Core driver handling 2-frame pipelined SPI, regulator sequencing, and
>    linear irq_domain. Harvests status bits from SPI MISO MSB.
> * pinctrl: Exposes 22 physical switch inputs as standard GPIOs. Proxies IRQs to
>    the MFD domain.
> * hwmon: Exposes thermal limits, VBATP/VDDQ voltage boundaries, and dynamic
>    fault alarms.
> * mux: Controls the 24-to-1 AMUX routing analog signals (switch voltages,
>    temperature, VBATP) to an external ADC.
> 
> Initial pinctrl implementation by David Jander, reworked into this MFD
> architecture.
> 

I Acked the hwmon driver, but Sashiko is still not happy with several of the other
patches in the series:

https://sashiko.dev/#/patchset/20260329090601.532477-1-o.rempel%40pengutronix.de

If the remaining issues are false positives, please let Roman and/or me know.

Thanks,
Guenter
Re: [PATCH v8 0/6] mfd: Add support for NXP MC33978/MC34978 MSDI
Posted by Rob Herring 1 day, 19 hours ago
On Sun, Mar 29, 2026 at 08:34:31AM -0700, Guenter Roeck wrote:
> Hi Oleksij,
> 
> On 3/29/26 02:05, Oleksij Rempel wrote:
> > changes v7:
> > - drop gpiolib irq fix and make pinctrl more robust against NULL point
> >    dereference.
> > 
> > This series adds support for the NXP MC33978/MC34978 Multiple Switch Detection
> > Interface (MSDI) via the MFD framework.
> > 
> > Architecture overview:
> > * mfd: Core driver handling 2-frame pipelined SPI, regulator sequencing, and
> >    linear irq_domain. Harvests status bits from SPI MISO MSB.
> > * pinctrl: Exposes 22 physical switch inputs as standard GPIOs. Proxies IRQs to
> >    the MFD domain.
> > * hwmon: Exposes thermal limits, VBATP/VDDQ voltage boundaries, and dynamic
> >    fault alarms.
> > * mux: Controls the 24-to-1 AMUX routing analog signals (switch voltages,
> >    temperature, VBATP) to an external ADC.
> > 
> > Initial pinctrl implementation by David Jander, reworked into this MFD
> > architecture.
> > 
> 
> I Acked the hwmon driver, but Sashiko is still not happy with several of the other
> patches in the series:
> 
> https://sashiko.dev/#/patchset/20260329090601.532477-1-o.rempel%40pengutronix.de
> 
> If the remaining issues are false positives, please let Roman and/or me know.

The binding issue is valid. However, it's an issue with many GPIO 
controller bindings that's been on my todo to address. Generally, there 
is only a reference to the provider schema when there's child nodes. 
Originally, there wheren't child nodes for GPIO, but then we added hog 
nodes. Changing things probably entails changes to gpio.yaml, so there's 
really nothing to do on this binding yet.

I really hope this sashiko stuff gains support soon in a form I can 
review first and email out rather than dropping links into threads. It 
is not a great workflow as-is.

Rob