diff options
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/list.h | 18 | ||||
| -rw-r--r-- | include/linux/pkt_cls.h | 21 | ||||
| -rw-r--r-- | include/linux/skbuff.h | 2 | ||||
| -rw-r--r-- | include/net/irda/irttp.h | 2 | ||||
| -rw-r--r-- | include/net/netrom.h | 3 | ||||
| -rw-r--r-- | include/net/xfrm.h | 1 |
6 files changed, 34 insertions, 13 deletions
diff --git a/include/linux/list.h b/include/linux/list.h index 92127ae0e995..33b863bcb7b9 100644 --- a/include/linux/list.h +++ b/include/linux/list.h @@ -677,6 +677,24 @@ static inline void hlist_add_after(struct hlist_node *n, pos && ({ n = pos->next; 1; }) && \ ({ tpos = hlist_entry(pos, typeof(*tpos), member); 1;}); \ pos = n) + +/** + * hlist_for_each_entry_rcu - iterate over rcu list of given type + * @pos: the type * to use as a loop counter. + * @pos: the &struct hlist_node to use as a loop counter. + * @head: the head for your list. + * @member: the name of the hlist_node within the struct. + * + * This list-traversal primitive may safely run concurrently with + * the _rcu list-mutation primitives such as hlist_add_rcu() + * as long as the traversal is guarded by rcu_read_lock(). + */ +#define hlist_for_each_entry_rcu(tpos, pos, head, member) \ + for (pos = (head)->first; \ + pos && ({ prefetch(pos->next); 1;}) && \ + ({ tpos = hlist_entry(pos, typeof(*tpos), member); 1;}); \ + pos = pos->next, ({ smp_read_barrier_depends(); 0; }) ) + #else #warning "don't include kernel headers in userspace" #endif /* __KERNEL__ */ diff --git a/include/linux/pkt_cls.h b/include/linux/pkt_cls.h index 60dd7903284e..9abc5b5a925c 100644 --- a/include/linux/pkt_cls.h +++ b/include/linux/pkt_cls.h @@ -117,8 +117,6 @@ enum struct tc_police { __u32 index; - int refcnt; - int bindcnt; int action; #define TC_POLICE_UNSPEC TC_ACT_UNSPEC #define TC_POLICE_OK TC_ACT_OK @@ -131,6 +129,9 @@ struct tc_police __u32 mtu; struct tc_ratespec rate; struct tc_ratespec peakrate; + int refcnt; + int bindcnt; + __u32 capab; }; struct tcf_t @@ -188,6 +189,7 @@ enum TCA_U32_POLICE, TCA_U32_ACT, TCA_U32_INDEV, + TCA_U32_PCNT, __TCA_U32_MAX }; @@ -199,7 +201,6 @@ struct tc_u32_key __u32 val; int off; int offmask; - __u32 kcnt; }; struct tc_u32_sel @@ -215,10 +216,16 @@ struct tc_u32_sel short hoff; __u32 hmask; struct tc_u32_key keys[0]; - unsigned long rcnt; - unsigned long rhit; }; +#ifdef CONFIG_CLS_U32_PERF +struct tc_u32_pcnt +{ + __u64 rcnt; + __u64 rhit; + __u64 kcnts[0]; +}; +#endif /* Flags */ #define TC_U32_TERMINAL 1 @@ -283,8 +290,8 @@ enum TCA_FW_UNSPEC, TCA_FW_CLASSID, TCA_FW_POLICE, - TCA_FW_INDEV, - TCA_FW_ACT, + TCA_FW_INDEV, /* used by CONFIG_NET_CLS_IND */ + TCA_FW_ACT, /* used by CONFIG_NET_CLS_ACT */ __TCA_FW_MAX }; diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h index 3d0ba45fa88d..11f514844817 100644 --- a/include/linux/skbuff.h +++ b/include/linux/skbuff.h @@ -233,7 +233,7 @@ struct sk_buff { * want to keep them across layers you have to do a skb_clone() * first. This is owned by whoever has the skb queued ATM. */ - char cb[48]; + char cb[40]; unsigned int len, data_len, diff --git a/include/net/irda/irttp.h b/include/net/irda/irttp.h index ef4727f6059b..600d5411da17 100644 --- a/include/net/irda/irttp.h +++ b/include/net/irda/irttp.h @@ -210,6 +210,4 @@ static inline int irttp_is_primary(struct tsap_cb *self) return(irlap_is_primary(self->lsap->lap->irlap)); } -extern struct irttp_cb *irttp; - #endif /* IRTTP_H */ diff --git a/include/net/netrom.h b/include/net/netrom.h index 8168780417d7..d968252feddf 100644 --- a/include/net/netrom.h +++ b/include/net/netrom.h @@ -112,9 +112,6 @@ struct nr_node { * nr_node & nr_neigh lists, refcounting and locking *********************************************************************/ -extern struct hlist_head nr_node_list; -extern struct hlist_head nr_neigh_list; - #define nr_node_hold(__nr_node) \ atomic_inc(&((__nr_node)->refcount)) diff --git a/include/net/xfrm.h b/include/net/xfrm.h index 6bb10bde3fc2..493b7237f68d 100644 --- a/include/net/xfrm.h +++ b/include/net/xfrm.h @@ -829,6 +829,7 @@ extern int xfrm6_tunnel_check_size(struct sk_buff *skb); extern u32 xfrm6_tunnel_alloc_spi(xfrm_address_t *saddr); extern void xfrm6_tunnel_free_spi(xfrm_address_t *saddr); extern u32 xfrm6_tunnel_spi_lookup(xfrm_address_t *saddr); +extern int xfrm6_output(struct sk_buff **pskb); #ifdef CONFIG_XFRM extern int xfrm4_rcv_encap(struct sk_buff *skb, __u16 encap_type); |
