aboutsummaryrefslogtreecommitdiffstats
path: root/include/net/netns/packet.h
diff options
context:
space:
mode:
authorstephen hemminger <shemminger@vyatta.com>2010-02-22 02:57:18 -0500
committerDavid S. Miller <davem@davemloft.net>2010-02-22 18:45:56 -0500
commit808f5114a9206fee855117d416440e1071ab375c (patch)
treecec3f04220909b77c0880029b63862553ad5161c /include/net/netns/packet.h
parent1cc523271ef0b6305c565a143e3d48f6fff826dd (diff)
packet: convert socket list to RCU (v3)
Convert AF_PACKET to use RCU, eliminating one more reader/writer lock. There is no need for a real sk_del_node_init_rcu(), because sk_del_node_init is doing the equivalent thing to hlst_del_init_rcu already; but added some comments to try and make that obvious. Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/netns/packet.h')
-rw-r--r--include/net/netns/packet.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/net/netns/packet.h b/include/net/netns/packet.h
index 637daf698884..cb4e894c0f8d 100644
--- a/include/net/netns/packet.h
+++ b/include/net/netns/packet.h
@@ -4,11 +4,11 @@
4#ifndef __NETNS_PACKET_H__ 4#ifndef __NETNS_PACKET_H__
5#define __NETNS_PACKET_H__ 5#define __NETNS_PACKET_H__
6 6
7#include <linux/list.h> 7#include <linux/rculist.h>
8#include <linux/spinlock.h> 8#include <linux/spinlock.h>
9 9
10struct netns_packet { 10struct netns_packet {
11 rwlock_t sklist_lock; 11 spinlock_t sklist_lock;
12 struct hlist_head sklist; 12 struct hlist_head sklist;
13}; 13};
14 14