Re: Resource management for ndo_xdp_xmit (Was: [PATCH net] virtio_net: Account for tx bytes and packets on sending xdp_frames)
From: Saeed Mahameed <hidden>
Date: 2019-02-08 22:49:08
From: Saeed Mahameed <hidden>
Date: 2019-02-08 22:49:08
On Fri, 2019-02-08 at 17:55 +0100, Toke Høiland-Jørgensen wrote:
Saeed Mahameed [off-list ref] writes:quoted
But: 2) this won't totally solve our problem, since sometimes the driver can decide to recreate (change of configuration) hw resources on the fly while redirect/devmap is already happening, so we need some kind of a dev_map_notification or a flag with rcu synch, for when the driver want to make the xdp redirect resources unavailable.Good point, I'll make a note of this. Do you have a pointer to where the mlx5 driver does this kind of change currently?
example: ethtool -L to reduce/increase the number of rings e.g. @mlx5e_ethtool_set_ringparam or virtually anywhere mlx5e_switch_priv_channels is called when xdp prog redirect is attached to mlx5.
-Toke