diff options
author | Eric Dumazet <edumazet@google.com> | 2023-03-28 23:50:19 +0000 |
---|---|---|
committer | Paolo Abeni <pabeni@redhat.com> | 2023-03-30 13:40:00 +0200 |
commit | c59647c0dc679008886756a888368da1c6d4ccd3 (patch) | |
tree | e9085b988a2ac89d8c73f1388cac8f8fd0471b4d /include/linux/netdevice.h | |
parent | 8fcb76b934daff12cde76adeab3d502eeb0734b1 (diff) |
net: add softnet_data.in_net_rx_action
We want to make two optimizations in napi_schedule_rps() and
____napi_schedule() which require to know if these helpers are
called from net_rx_action(), instead of being called from
other contexts.
sd.in_net_rx_action is only read/written by the owning cpu.
Signed-off-by: Eric Dumazet <edumazet@google.com>
Reviewed-by: Jason Xing <kerneljasonxing@gmail.com>
Tested-by: Jason Xing <kerneljasonxing@gmail.com>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Diffstat (limited to 'include/linux/netdevice.h')
-rw-r--r-- | include/linux/netdevice.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index 18a5be6ddd0f..c8c634091a65 100644 --- a/include/linux/netdevice.h +++ b/include/linux/netdevice.h @@ -3188,6 +3188,7 @@ struct softnet_data { #ifdef CONFIG_RPS struct softnet_data *rps_ipi_list; #endif + bool in_net_rx_action; #ifdef CONFIG_NET_FLOW_LIMIT struct sd_flow_limit __rcu *flow_limit; #endif |