summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorEric Dumazet <edumazet@google.com>2015-11-18 06:31:02 -0800
committerDavid S. Miller <davem@davemloft.net>2015-11-18 16:17:42 -0500
commit34cbe27e811c591c854a39c0dee1b461bb796953 (patch)
treef9371f25907985feef0b5e9c9d8b0f7ba1eb2432 /include
parent6180d9de61a5c461f9e3efef5417a844701dbbb2 (diff)
net: napi_hash_del() returns a boolean status
napi_hash_del() will soon be used from both drivers (if they want) or core networking stack. Callers are responsibles to ensure an RCU grace period is respected before freeing napi structure : napi_hash_del() can signal if this RCU grace period is needed or not. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include')
-rw-r--r--include/linux/netdevice.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index 838935d1cdbb..e5c33b29471b 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -474,9 +474,10 @@ void napi_hash_add(struct napi_struct *napi);
* @napi: napi context
*
* Warning: caller must observe rcu grace period
- * before freeing memory containing @napi
+ * before freeing memory containing @napi, if
+ * this function returns true.
*/
-void napi_hash_del(struct napi_struct *napi);
+bool napi_hash_del(struct napi_struct *napi);
/**
* napi_disable - prevent NAPI from scheduling