diff options
author | Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> | 2011-11-02 21:49:55 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2011-11-03 21:59:40 -0400 |
commit | 9372cacb300df3ee0a8be8a25bea15d16a95c583 (patch) | |
tree | 3e9f4e7dc2ca6df4560b2cf9f51edcda44742e5f /drivers/net/ethernet/emulex | |
parent | 1610c79f1e9545d0a64dc6bb4f9affdfcf1d5726 (diff) |
be2net: Prevent CQ full condition for Lancer
Indicate to HW that the CQ is cleaned up before posting new RX buffers.
This prevents the HW to go into CQ full error condition.
Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/emulex')
-rw-r--r-- | drivers/net/ethernet/emulex/benet/be_main.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/ethernet/emulex/benet/be_main.c b/drivers/net/ethernet/emulex/benet/be_main.c index 21804972fa2f..30606f5ec0d0 100644 --- a/drivers/net/ethernet/emulex/benet/be_main.c +++ b/drivers/net/ethernet/emulex/benet/be_main.c | |||
@@ -1905,6 +1905,8 @@ loop_continue: | |||
1905 | be_rx_stats_update(rxo, rxcp); | 1905 | be_rx_stats_update(rxo, rxcp); |
1906 | } | 1906 | } |
1907 | 1907 | ||
1908 | be_cq_notify(adapter, rx_cq->id, false, work_done); | ||
1909 | |||
1908 | /* Refill the queue */ | 1910 | /* Refill the queue */ |
1909 | if (work_done && atomic_read(&rxo->q.used) < RX_FRAGS_REFILL_WM) | 1911 | if (work_done && atomic_read(&rxo->q.used) < RX_FRAGS_REFILL_WM) |
1910 | be_post_rx_frags(rxo, GFP_ATOMIC); | 1912 | be_post_rx_frags(rxo, GFP_ATOMIC); |
@@ -1912,10 +1914,8 @@ loop_continue: | |||
1912 | /* All consumed */ | 1914 | /* All consumed */ |
1913 | if (work_done < budget) { | 1915 | if (work_done < budget) { |
1914 | napi_complete(napi); | 1916 | napi_complete(napi); |
1915 | be_cq_notify(adapter, rx_cq->id, true, work_done); | 1917 | /* Arm CQ */ |
1916 | } else { | 1918 | be_cq_notify(adapter, rx_cq->id, true, 0); |
1917 | /* More to be consumed; continue with interrupts disabled */ | ||
1918 | be_cq_notify(adapter, rx_cq->id, false, work_done); | ||
1919 | } | 1919 | } |
1920 | return work_done; | 1920 | return work_done; |
1921 | } | 1921 | } |