summaryrefslogtreecommitdiff
path: root/include/linux/netdevice.h
diff options
context:
space:
mode:
authorSubash Abhinov Kasiviswanathan <subashab@codeaurora.org>2016-01-25 18:09:54 -0700
committerDavid Keitel <dkeitel@codeaurora.org>2016-03-22 11:05:56 -0700
commit09a36c1368e96140cd49dd9556f9d6e04c828c38 (patch)
treead55cd22a44238d10dbcec9f47e511cbe0a273b7 /include/linux/netdevice.h
parent12fae71b184dade2cedf154bbc8fd7870c5cd71c (diff)
net: Add the get current NAPI context API
Commit 69235aa80090 ("net: Remove the get current NAPI context API") removed the definition of get_current_napi_context() as rmnet_data was no longer using it. However, the rmnet_data change to use its NAPI in multiple contexts was prone to race in hotplug scenarios. Add back get_current_napi_context() and current_napi to the softnet_data struct CRs-Fixed: 966095 Change-Id: I7cf1c5e39a5ccbd7a74a096b11efd179a4d0d034 Signed-off-by: Subash Abhinov Kasiviswanathan <subashab@codeaurora.org> [subashab@codeaurora.org: resolve trivial merge conflicts] Signed-off-by: Subash Abhinov Kasiviswanathan <subashab@codeaurora.org>
Diffstat (limited to 'include/linux/netdevice.h')
-rw-r--r--include/linux/netdevice.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index 3143c847bddb..f2416b530c9a 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -2518,6 +2518,7 @@ extern int netdev_flow_limit_table_len;
*/
struct softnet_data {
struct list_head poll_list;
+ struct napi_struct *current_napi;
struct sk_buff_head process_queue;
/* stats */
@@ -3012,6 +3013,7 @@ struct sk_buff *napi_get_frags(struct napi_struct *napi);
gro_result_t napi_gro_frags(struct napi_struct *napi);
struct packet_offload *gro_find_receive_by_type(__be16 type);
struct packet_offload *gro_find_complete_by_type(__be16 type);
+extern struct napi_struct *get_current_napi_context(void);
static inline void napi_free_frags(struct napi_struct *napi)
{