[PATCH net-next v9 0/4] ethtool: provide the dim profile fine-tuning channel

2024-04-17 Thread Heng Qi
The NetDIM library provides excellent acceleration for many modern network cards. However, the default profiles of DIM limits its maximum capabilities for different NICs, so providing a way which the NIC can be custom configured is necessary. Currently, interaction with the driver is still based o

[PATCH net-next v9 3/4] virtio-net: refactor dim initialization/destruction

2024-04-17 Thread Heng Qi
Extract the initialization and destruction actions of dim for use in the next patch. Signed-off-by: Heng Qi --- drivers/net/virtio_net.c | 38 +++--- 1 file changed, 27 insertions(+), 11 deletions(-) diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.

[PATCH net-next v9 4/4] virtio-net: support dim profile fine-tuning

2024-04-17 Thread Heng Qi
Virtio-net has different types of back-end device implementations. In order to effectively optimize the dim library's gains for different device implementations, let's use the new interface params to fine-tune the profile list. Since the profile now exists in netdevice, adding a function similar t

[PATCH net-next v9 2/4] ethtool: provide customized dim profile management

2024-04-17 Thread Heng Qi
The NetDIM library, currently leveraged by an array of NICs, delivers excellent acceleration benefits. Nevertheless, NICs vary significantly in their dim profile list prerequisites. Specifically, virtio-net backends may present diverse sw or hw device implementation, making a one-size-fits-all par

[PATCH net-next v9 1/4] linux/dim: move useful macros to .h file

2024-04-17 Thread Heng Qi
These will be used in subsequent patches, including newly declared profile arrays. Signed-off-by: Heng Qi --- include/linux/dim.h | 13 + lib/dim/net_dim.c | 18 ++ 2 files changed, 19 insertions(+), 12 deletions(-) diff --git a/include/linux/dim.h b/include/linux/