From bbbee95dbac1a58d8ed9bcd9a13e3b62589bbe0e Mon Sep 17 00:00:00 2001 From: hselasky Date: Sat, 7 Mar 2015 18:33:28 +0000 Subject: MFC r279584: Updates for the Mellanox ethernet driver > List of fixes: * use correct format for GID printouts * double array indexing * spelling in printouts * void pointer arithmetic * allow more receive rings * correct maximum number of transmit rings * use "const" instead of "static" for constants * check for invalid VLAN tags * check for lack of IRQ resources > Added more hardware specific defines > Added more verbose printouts of firmware status codes Sponsored by: Mellanox Technologies --- sys/ofed/drivers/net/mlx4/en_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'sys/ofed/drivers/net/mlx4/en_main.c') diff --git a/sys/ofed/drivers/net/mlx4/en_main.c b/sys/ofed/drivers/net/mlx4/en_main.c index cbbf37d..757afe0 100644 --- a/sys/ofed/drivers/net/mlx4/en_main.c +++ b/sys/ofed/drivers/net/mlx4/en_main.c @@ -239,8 +239,8 @@ static void *mlx4_en_add(struct mlx4_dev *dev) DEF_RX_RINGS))); } else { mdev->profile.prof[i].rx_ring_num = rounddown_pow_of_two( - min_t(int, dev->caps.comp_pool/ - dev->caps.num_ports - 1 , MAX_MSIX_P_PORT - 1)); + min_t(int, dev->caps.comp_pool / + dev->caps.num_ports, MAX_MSIX_P_PORT)); } } -- cgit v1.1