diff options
author | Aaro Koskinen <aaro.koskinen@iki.fi> | 2013-09-05 21:43:59 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-09-17 07:39:27 -0700 |
commit | ed12cd612a0ca95162c0505a3fcd94fd047a8928 (patch) | |
tree | 4a34452f03952e22cfe3721d19431255cebd5ded /drivers | |
parent | ae18c5c62570247eab1178e2db28539a653ac5b5 (diff) | |
download | linux-ed12cd612a0ca95162c0505a3fcd94fd047a8928.tar.gz linux-ed12cd612a0ca95162c0505a3fcd94fd047a8928.tar.bz2 linux-ed12cd612a0ca95162c0505a3fcd94fd047a8928.zip |
staging: octeon-ethernet: make dropped packets to consume NAPI budget
We should count also dropped packets, otherwise the NAPI handler may
end up running too long.
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Acked-by: Jason A. Donenfeld <Jason@zx2c4.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/staging/octeon/ethernet-rx.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/octeon/ethernet-rx.c b/drivers/staging/octeon/ethernet-rx.c index 34afc16bc493..10e54165d89c 100644 --- a/drivers/staging/octeon/ethernet-rx.c +++ b/drivers/staging/octeon/ethernet-rx.c @@ -303,6 +303,7 @@ static int cvm_oct_napi_poll(struct napi_struct *napi, int budget) if (backlog > budget * cores_in_use && napi != NULL) cvm_oct_enable_one_cpu(); } + rx_count++; skb_in_hw = USE_SKBUFFS_IN_HW && work->word2.s.bufs == 1; if (likely(skb_in_hw)) { @@ -429,7 +430,6 @@ static int cvm_oct_napi_poll(struct napi_struct *napi, int budget) #endif } netif_receive_skb(skb); - rx_count++; } else { /* Drop any packet received for a device that isn't up */ /* |