[resend PATCH 1/2] dim: make dim_calc_stats() inputs const pointers

2024-10-30 Thread Caleb Sander Mateos
Make the start and end arguments to dim_calc_stats() const pointers to clarify that the function does not modify their values. Signed-off-by: Caleb Sander Mateos --- include/linux/dim.h | 3 ++- lib/dim/dim.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/include

[resend PATCH 2/2] dim: pass dim_sample to net_dim() by reference

2024-10-30 Thread Caleb Sander Mateos
the caller to reuse the struct dim_sample already on the stack, pass the struct dim_sample by reference to net_dim(). Signed-off-by: Caleb Sander Mateos --- Documentation/networking/net_dim.rst | 2 +- drivers/net/ethernet/amazon/ena/ena_netdev.c | 2 +- drivers/net