diff options
author | Don Fry <brazilnut@us.ibm.com> | 2006-06-29 16:53:23 -0400 |
---|---|---|
committer | Jeff Garzik <jeff@garzik.org> | 2006-07-05 14:07:15 -0400 |
commit | 6dcd60c2c78ca87163730472ddea6aa1a7754b61 (patch) | |
tree | 12a0fc054765024198bf2940397ddd3a8f59f696 /drivers | |
parent | f2622a2b16f27d0087c913115dc15ee70797d58b (diff) |
[PATCH] pcnet32: Fix off-by-one in get_ringparam
Fix off-by-one in pcnet32_get_ringparam
Signed-off-by: Don Fry <brazilnut@us.ibm.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/pcnet32.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/pcnet32.c b/drivers/net/pcnet32.c index 971bd6e91e4f..5fcd4d94871d 100644 --- a/drivers/net/pcnet32.c +++ b/drivers/net/pcnet32.c | |||
@@ -515,10 +515,10 @@ static void pcnet32_get_ringparam(struct net_device *dev, | |||
515 | { | 515 | { |
516 | struct pcnet32_private *lp = dev->priv; | 516 | struct pcnet32_private *lp = dev->priv; |
517 | 517 | ||
518 | ering->tx_max_pending = TX_MAX_RING_SIZE - 1; | 518 | ering->tx_max_pending = TX_MAX_RING_SIZE; |
519 | ering->tx_pending = lp->tx_ring_size - 1; | 519 | ering->tx_pending = lp->tx_ring_size; |
520 | ering->rx_max_pending = RX_MAX_RING_SIZE - 1; | 520 | ering->rx_max_pending = RX_MAX_RING_SIZE; |
521 | ering->rx_pending = lp->rx_ring_size - 1; | 521 | ering->rx_pending = lp->rx_ring_size; |
522 | } | 522 | } |
523 | 523 | ||
524 | static int pcnet32_set_ringparam(struct net_device *dev, | 524 | static int pcnet32_set_ringparam(struct net_device *dev, |