Re: [PATCH net-next] net: stmmac: xgmac3+: add FPE handshaking support

From: Serge Semin
Date: Tue Dec 12 2023 - 04:08:17 EST


On Tue, Dec 12, 2023 at 07:22:24AM +0000, Jianheng Zhang wrote:
> Hi Andrew,
>
> > > +static int dwxgmac3_fpe_irq_status(void __iomem *ioaddr, struct net_device *dev)
> > > +{
> > > + u32 value;
> > > + int status;
> > >
> > > - writel(value, ioaddr + XGMAC_FPE_CTRL_STS);
> > > - return;
> > > + status = FPE_EVENT_UNKNOWN;
> > > +
> > > + /* Reads from the XGMAC_FPE_CTRL_STS register should only be performed
> > > + * here, since the status flags of MAC_FPE_CTRL_STS are "clear on read"
> > > + */
> > > + value = readl(ioaddr + XGMAC_FPE_CTRL_STS);
> > > +
> > > + if (value & XGMAC_TRSP) {
> > > + status |= FPE_EVENT_TRSP;
> > > + netdev_info(dev, "FPE: Respond mPacket is transmitted\n");
> >
> > netdev_info()? Is this going to spam the logs? Should it be netdev_dbg()
>
> Yes, netdev_dbg() should be better, let me fix it in the next patch.

Please do not forget to keep this change in the refactoring patch (if
one will be introduced). So instead of preserving the DW QoS Eth FPE
code snipped with netdev_info() utilized, the common FPE
implementation would have the netdev_dbg() calls.

-Serge(y)

>
> Jianheng
> >
> > Andrew
>