Commit 0fe665d4 authored by Ioana Ciornei's avatar Ioana Ciornei Committed by David S. Miller

dpaa2-eth: fix draining of S/G cache

On link down, the draining of the S/G cache should be done on all
_possible_ CPUs not just the ones that are online in that moment.
Fix this by changing the iterator.

Fixes: d70446ee ("dpaa2-eth: send a scatter-gather FD instead of realloc-ing")
Reported-by: default avatarJakub Kicinski <kuba@kernel.org>
Signed-off-by: default avatarIoana Ciornei <ioana.ciornei@nxp.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent bc0c3ae4
...@@ -1261,7 +1261,7 @@ static void dpaa2_eth_sgt_cache_drain(struct dpaa2_eth_priv *priv) ...@@ -1261,7 +1261,7 @@ static void dpaa2_eth_sgt_cache_drain(struct dpaa2_eth_priv *priv)
u16 count; u16 count;
int k, i; int k, i;
for_each_online_cpu(k) { for_each_possible_cpu(k) {
sgt_cache = per_cpu_ptr(priv->sgt_cache, k); sgt_cache = per_cpu_ptr(priv->sgt_cache, k);
count = sgt_cache->count; count = sgt_cache->count;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment