[PATCH net-next v3 2/2] net: dsa: mt7530: simplify core operations
Arınç ÜNAL
arinc.unal at arinc9.com
Tue Apr 23 02:12:45 PDT 2024
On 23/04/2024 11:40, Paolo Abeni wrote:
> On Thu, 2024-04-18 at 08:35 +0300, Arınç ÜNAL wrote:
>> /* Select the Function : DATA with no post increment */
>> ret = bus->write(bus, MT753X_CTRL_PHY_ADDR(priv->mdiodev->addr),
>> - MII_MMD_CTRL, devad | MII_MMD_CTRL_NOINCR);
>> + MII_MMD_CTRL, MDIO_MMD_VEND2 | MII_MMD_CTRL_NOINCR);
>> if (ret < 0)
>> goto err;
>
> What about a possible follow-up, moving the above writes in a separate
> helper (say, 'core_select_register' or the like) and reusing it here
> and in core_rmw() ?
There's a possibility where the Clause 45 access method could be used here
which would make this redundant. I will do your suggestion if that won't
work out.
>
> Not blocking this series, I'm applying it.
Cheers.
Arınç
More information about the Linux-mediatek
mailing list