diff options
author | Eilon Greenstein <eilong@broadcom.com> | 2009-07-05 00:18:14 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-07-05 21:03:23 -0400 |
commit | 1e9d9987598fa58f4bd8e72ee152c879136d6723 (patch) | |
tree | 15c61f48a069adc093a472fb5bcce8265c474481 /drivers/net/bnx2x_main.c | |
parent | 3799cf47e3497a472b05f88e7a52a14931597d78 (diff) |
bnx2x: Fix the maximal values of coalescing timeouts.
This patch properly defines the maximum values for rx/tx coalescing timeouts.
Signed-off-by: Vlad Zolotarov <vladz@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_main.c')
-rw-r--r-- | drivers/net/bnx2x_main.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/bnx2x_main.c b/drivers/net/bnx2x_main.c index 5737b7519005..6c67be679764 100644 --- a/drivers/net/bnx2x_main.c +++ b/drivers/net/bnx2x_main.c | |||
@@ -9069,12 +9069,12 @@ static int bnx2x_set_coalesce(struct net_device *dev, | |||
9069 | struct bnx2x *bp = netdev_priv(dev); | 9069 | struct bnx2x *bp = netdev_priv(dev); |
9070 | 9070 | ||
9071 | bp->rx_ticks = (u16) coal->rx_coalesce_usecs; | 9071 | bp->rx_ticks = (u16) coal->rx_coalesce_usecs; |
9072 | if (bp->rx_ticks > 3000) | 9072 | if (bp->rx_ticks > BNX2X_MAX_COALESCE_TOUT) |
9073 | bp->rx_ticks = 3000; | 9073 | bp->rx_ticks = BNX2X_MAX_COALESCE_TOUT; |
9074 | 9074 | ||
9075 | bp->tx_ticks = (u16) coal->tx_coalesce_usecs; | 9075 | bp->tx_ticks = (u16) coal->tx_coalesce_usecs; |
9076 | if (bp->tx_ticks > 0x3000) | 9076 | if (bp->tx_ticks > BNX2X_MAX_COALESCE_TOUT) |
9077 | bp->tx_ticks = 0x3000; | 9077 | bp->tx_ticks = BNX2X_MAX_COALESCE_TOUT; |
9078 | 9078 | ||
9079 | if (netif_running(dev)) | 9079 | if (netif_running(dev)) |
9080 | bnx2x_update_coalesce(bp); | 9080 | bnx2x_update_coalesce(bp); |