Re: [PATCH net-next v22 4/9] mfd: an8855: Add support for Airoha AN8855 Switch
From: Christian Marangi (Ansuel)
Date: Tue Sep 22 2026 - 06:43:10 EST
Il giorno lun 21 set 2026 alle ore 22:44 Jakub Kicinski
<kuba@xxxxxxxxxx> ha scritto:
>
> On Tue, 15 Sep 2026 14:38:01 +0200 Christian Marangi wrote:
> > Add support for Airoha AN8855 Switch that provide support for a DSA
> > switch and a NVMEM provider.
> >
> > Also make use of the mdio-regmap driver and register a regmap for each
> > internal PHY of the switch.
> > This is needed to handle the double usage of the PHYs as both PHY and
> > Switch accessor.
>
> GCC spews warnings:
>
> drivers/mfd/airoha-an8855.c: In function ‘an8855_mdio_register’:
> drivers/mfd/airoha-an8855.c:438:48: warning: ‘-phy’ directive output may be truncated writing 4 bytes into a region of size between 1 and 61 [-Wformat-truncation=]
> 438 | snprintf(mrc.name, MII_BUS_ID_SIZE, "%s-phy%d", priv->bus->id, addr);
> | ^~~~
> In function ‘an8855_phy_bus_register’,
> inlined from ‘an8855_mdio_register’ at ../drivers/mfd/airoha-an8855.c:469:9:
> drivers/mfd/airoha-an8855.c:438:45: note: using the range [-2147483648, 2147483647] for directive argument
> 438 | snprintf(mrc.name, MII_BUS_ID_SIZE, "%s-phy%d", priv->bus->id, addr);
> | ^~~~~~~~~~
> drivers/mfd/airoha-an8855.c:438:9: note: ‘snprintf’ output between 6 and 76 bytes into a destination of size 61
> 438 | snprintf(mrc.name, MII_BUS_ID_SIZE, "%s-phy%d", priv->bus->id, addr);
> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
Hi,
I also didn't receive the email for the AI review... Did it broke also here?
If everything else is ok, should I send new revision or maybe we can pick this
and I can send followup for this warning?