diff options
author | Ma JieYue <jieyue.majy@alibaba-inc.com> | 2013-11-15 12:26:13 +0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-11-18 13:56:05 -0500 |
commit | fdcf77659c103388a67f40f2f8db239b57c1ce4e (patch) | |
tree | 3754bf21a8cdd5ce60dcb82b8c1052eb7439c463 /net/lapb | |
parent | 018c5bba052b3a383d83cf0c756da0e7bc748397 (diff) | |
download | op-kernel-dev-fdcf77659c103388a67f40f2f8db239b57c1ce4e.zip op-kernel-dev-fdcf77659c103388a67f40f2f8db239b57c1ce4e.tar.gz |
xen-netfront: fix missing rx_refill_timer when allocate memory failed
There was a bug in xennet_alloc_rx_buffers, when allocating page or
sk_buff failed, and at the same time rx_batch queue not empty,
the rx_refill_timer timer won't be scheduled. If finally the remaining
request buffers in rx ring less than what backend driver expected,
the backend driver would think of rx ring as full and start dropping packets.
In such situation, there is no way for the netfront driver to recover
automatically, so that the device can not work properly.
The patch fixes the problem by always scheduling rx_refill_timer timer when
alloc_page or __netdev_alloc_skb fails, no matter whether rx_batch queue is
empty or not. It ensures that the rx ring request buffers will finally meet
the backend needs.
Signed-off-by: Ma JieYue <jieyue.majy@alibaba-inc.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/lapb')
0 files changed, 0 insertions, 0 deletions