RE: [EXT] Re: [net-next] net: mvpp2: Add reserved port private flag configuration

From: Stefan Chulski
Date: Thu Mar 11 2021 - 03:14:02 EST


> > From: Stefan Chulski <stefanc@xxxxxxxxxxx>
> >
> > According to Armada SoC architecture and design, all the PPv2 ports
> > which are populated on the same communication processor silicon die
> > (CP11x) share the same Classifier and Parser engines.
> >
> > Armada is an embedded platform and therefore there is a need to
> > reserve some of the PPv2 ports for different use cases.
> >
> > For example, a port can be reserved for a CM3 CPU running FreeRTOS for
> > management purposes or by user-space data plane application.
> >
> > During port reservation all common configurations are preserved and
> > only RXQ, TXQ, and interrupt vectors are disabled.
>
> If a port is reserved for use by the CM3, what are the implications for Linux
> running on the AP? Should Linux have knowledge of the port?
> What configurations of the port should be permitted?

In reserved mode all port TXQ's closed(Linux won't transmit any packet from this ports) and
RX interrupts disabled(Linux won't receive any packet). We still can change port MAC address, do port UP/DOWN from Linux running on the AP.
Only permitted configurations Is MTU change.
Driver .ndo_change_mtu callback has logic that switch between percpu_pools and shared pools buffer mode, we should avoid this since buffer management not done by Kernel.

> I think describing how a port reserved for use by the CM3 CPU should appear
> to Linux is particularly important for the commit commentry to cover.

Ok, I would add more info to commit message.

Thanks,
Stefan.