[PATCH v6 0/7] pinctrl: Add generic pinctrl for board-level mux chips

Frank Li Frank.li at nxp.com
Mon May 11 12:38:33 PDT 2026


On Tue, May 05, 2026 at 02:50:17PM +0200, Linus Walleij wrote:
> Hi Frank!
>
> On Tue, May 5, 2026 at 1:55 AM Frank Li <Frank.Li at nxp.com> wrote:
>
> > Add a generic pinctrl binding for board-level pinmux chips that are
> > controlled through the multiplexer subsystem.
> >
> > On some boards, especially development boards, external mux chips are used
> > to switch SoC signals between different peripherals (e.g. MMC and UART).
> > The mux select lines are often driven by a GPIO expander over I2C,
> > as illustrated below:
> >
> >         ┌──────┐      ┌─────┐
> >         │ SOC  │      │     │    ┌───────┐
> >         │      │      │     │───►│ MMC   │
> >         │      │      │ MUX │    └───────┘
> >         │      ├─────►│     │    ┌───────┐
> >         │      │      │     │───►│ UART  │
> >         │      │      └─────┘    └───────┘
> >         │      │         ▲
> >         │      │    ┌────┴──────────────┐
> >         │ I2C  ├───►│ GPIO Expander     │
> >         └──────┘    └───────────────────┘
> >
> > Traditionally, gpio-hog is used to configure the onboard mux at boot.
> > However, the GPIO expander may probe later than consumer devices such as
> > MMC. As a result, the MUX might not be configured when the peripheral
> > driver probes, leading to initialization failures or data transfer errors.
> >
> > Introduce a generic pinctrl binding that models the board-level MUX as a
> > pin control provider and builds proper device links between the MUX, its
> > GPIO controller, and peripheral devices. This ensures correct probe
> > ordering and reliable mux configuration.
> >
> > The implementation leverages the standard multiplexer subsystem, which
> > provides broad support for onboard mux controllers and avoids the need for
> > per-driver custom MUX handling
> >
> > Signed-off-by: Frank Li <Frank.Li at nxp.com>
>
> I put the pinctrl patches on an immutable branch for testing again,
> if nothing explodes I will try to merge it for linux-next ASAP!

I fixed a build warning by missing doc 'np',
https://lore.kernel.org/imx/20260507152117.240612-1-Frank.Li@nxp.com/

Anything need me to do futher?

Frank

>
> Yours,
> Linus Walleij



More information about the linux-arm-kernel mailing list