Re: [PATCH 2/3] net: renesas: rswitch: add offloading for L2 switching

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Jul 04, 2025 at 11:02:55AM +0200, Nikita Yushchenko wrote:
> > >   	struct phy *serdes;
> > > +
> > > +	struct net_device *brdev;	/* master bridge device */
> > 
> > How many ports does this device have? If it is just two, this might
> > work. But for a multi-port device, you need to keep this in the port
> > structure.
> 
> Having per-device (not per port) brdev was designed by me.  Reasoning is
> that hw L2 forwarding support lacks any sort of source port based filtering,
> which makes it unusable to offload more than one bridge device. Either you
> allow hardware to forward destination MAC to a port, or you have to send it
> to CPU. You can't make it forward only if src and dst ports are in the same
> brdev.

This needs to be part of the commit message, since it is not
obvious. I think some comments in the code would also be good, where
it decides there is a bridge in use, and so it needs to reject the
offload for another bridge. This limitation is very unusual, pretty
much a design error, so it needs calling out.

	Andrew




[Index of Archives]     [Linux Samsung SOC]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux