On Wed, 2019-09-18 at 10:41 -0700, Florian Fainelli wrote: > > > The other part of the problem seems to be that the CPU port has no > > > network device > > > representation in Linux, so there's no interface to configure the egress > > > limits via tc. > > > This has been discussed before, but it seems there hasn't been any > > > consensous regarding how > > > we want to proceed? > > You have the DSA master network device which is on the other side of the > switch,
We thought it might be intutive to allow configuration of this via tc on the DSA master device (eth0, the i.MX FEC in our case). You'd specify ingress policing via tc, and the kernel would try to hw-offload that to the switch's CPU egress side first, maybe fall back to offload on the SoC's network controler and finally use the normal SW implementation. If that sounds reasonable, the next question would be how to express matching on switchdev information (such as the ingress port or vlan priority). Regards, Jan