diff options
author | Dmitry Kravkov <dmitry@broadcom.com> | 2010-09-12 01:48:28 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-09-13 23:02:53 -0400 |
commit | 251415808306a19be93ec93268e2985f10d3db8b (patch) | |
tree | 176b64ef9f742ae0ebcfa4eceae44859e01e4a1e /drivers/net/bnx2x/bnx2x.h | |
parent | 441993da47777d961300c070fe1210600af48ad8 (diff) |
bnx2x: Spread rx buffers between allocated queues
Default number of rx buffers will be divided equally
between allocated queues. This will decrease amount of
pre-allocated buffers on systems with multiple CPUs.
User can override this behavior with ethtool -G.
Minimum amount of rx buffers per queue set to 128.
Reported-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: Dmitry Kravkov <dmitry@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/bnx2x/bnx2x.h')
-rw-r--r-- | drivers/net/bnx2x/bnx2x.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/net/bnx2x/bnx2x.h b/drivers/net/bnx2x/bnx2x.h index b6aaf22a1b84..64329c5fbdea 100644 --- a/drivers/net/bnx2x/bnx2x.h +++ b/drivers/net/bnx2x/bnx2x.h | |||
@@ -20,8 +20,8 @@ | |||
20 | * (you will need to reboot afterwards) */ | 20 | * (you will need to reboot afterwards) */ |
21 | /* #define BNX2X_STOP_ON_ERROR */ | 21 | /* #define BNX2X_STOP_ON_ERROR */ |
22 | 22 | ||
23 | #define DRV_MODULE_VERSION "1.52.53-6" | 23 | #define DRV_MODULE_VERSION "1.52.53-7" |
24 | #define DRV_MODULE_RELDATE "2010/09/07" | 24 | #define DRV_MODULE_RELDATE "2010/09/12" |
25 | #define BNX2X_BC_VER 0x040200 | 25 | #define BNX2X_BC_VER 0x040200 |
26 | 26 | ||
27 | #if defined(CONFIG_VLAN_8021Q) || defined(CONFIG_VLAN_8021Q_MODULE) | 27 | #if defined(CONFIG_VLAN_8021Q) || defined(CONFIG_VLAN_8021Q_MODULE) |
@@ -369,6 +369,7 @@ struct bnx2x_fastpath { | |||
369 | #define NUM_RX_BD (RX_DESC_CNT * NUM_RX_RINGS) | 369 | #define NUM_RX_BD (RX_DESC_CNT * NUM_RX_RINGS) |
370 | #define MAX_RX_BD (NUM_RX_BD - 1) | 370 | #define MAX_RX_BD (NUM_RX_BD - 1) |
371 | #define MAX_RX_AVAIL (MAX_RX_DESC_CNT * NUM_RX_RINGS - 2) | 371 | #define MAX_RX_AVAIL (MAX_RX_DESC_CNT * NUM_RX_RINGS - 2) |
372 | #define MIN_RX_AVAIL 128 | ||
372 | #define NEXT_RX_IDX(x) ((((x) & RX_DESC_MASK) == \ | 373 | #define NEXT_RX_IDX(x) ((((x) & RX_DESC_MASK) == \ |
373 | (MAX_RX_DESC_CNT - 1)) ? (x) + 3 : (x) + 1) | 374 | (MAX_RX_DESC_CNT - 1)) ? (x) + 3 : (x) + 1) |
374 | #define RX_BD(x) ((x) & MAX_RX_BD) | 375 | #define RX_BD(x) ((x) & MAX_RX_BD) |