aboutsummaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorSubash Abhinov Kasiviswanathan <subashab@codeaurora.org>2015-04-02 10:25:37 -0600
committerGerrit - the friendly Code Review server <code-review@localhost>2015-04-05 03:33:09 -0700
commit3ddd0a373a646bd90837311ebfc39b91cce5538e (patch)
tree6d61c4969a0928c81ad6309b716571ff06bbacac /net
parentaa74259cfb99daa1eaf01f2f38ab66031e7f215e (diff)
downloadqcom-msm-v3.10-3ddd0a373a646bd90837311ebfc39b91cce5538e.tar.gz
net: rps: fix data stall after hotplug
When RPS is enabled, IPI is triggered to enqueue the backlog NAPI to the poll list. If the CPU which was found to online in get_rps_cpus is hotplugged after the NAPI_STATE_SCHED bit is set on enqueue_to_backlog but before the IPI is delivered in in net_rps_action_and_irq_enable, the poll list does not have the backlog NAPI queued. As a consequence of this, dev_cpu_callback does not clear the NAPI_STATE_SCHED bit on hotplug. Since NAPI_STATE_SCHED is set even after the cpu comes back up, packets get enqueued onto the input packet queue but are never processed since the IPI will not be triggered. This patch handles this race by unconditionally resetting the NAPI state for the backlog NAPI on the offline CPU in dev_cpu_callback. CRs-fixed: 817709 Change-Id: Ie73a21f4bb689948bfbbe1de10a1e9143e4424d2 Signed-off-by: Subash Abhinov Kasiviswanathan <subashab@codeaurora.org>
Diffstat (limited to 'net')
-rw-r--r--net/core/dev.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/net/core/dev.c b/net/core/dev.c
index 70a789058a1..6769c64a10c 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -6025,12 +6025,11 @@ static int dev_cpu_callback(struct notifier_block *nfb,
poll_list);
list_del_init(&napi->poll_list);
- if (napi->poll == process_backlog)
- napi->state = 0;
- else
+ if (napi->poll != process_backlog)
____napi_schedule(sd, napi);
}
+ oldsd->backlog.state = 0;
raise_softirq_irqoff(NET_TX_SOFTIRQ);
local_irq_enable();