aboutsummaryrefslogtreecommitdiffstats
path: root/include/net
diff options
context:
space:
mode:
authorPatrick McHardy <kaber@trash.net>2008-01-31 07:41:14 -0500
committerDavid S. Miller <davem@davemloft.net>2008-01-31 22:27:57 -0500
commitffaa9c100bd75c81744a2b7800a45daba53db0eb (patch)
treeb4f856b426895feba2ae299b91ec6b6f124978b3 /include/net
parent0794935e21a18e7c171b604c31219b60ad9749a9 (diff)
[NETFILTER]: nf_conntrack: reorder struct nf_conntrack_l4proto
Reorder struct nf_conntrack_l4proto so all members used during packet processing are in the same cacheline. Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net')
-rw-r--r--include/net/netfilter/nf_conntrack_l4proto.h19
1 files changed, 9 insertions, 10 deletions
diff --git a/include/net/netfilter/nf_conntrack_l4proto.h b/include/net/netfilter/nf_conntrack_l4proto.h
index fb50c217ba0a..84892cc1d603 100644
--- a/include/net/netfilter/nf_conntrack_l4proto.h
+++ b/include/net/netfilter/nf_conntrack_l4proto.h
@@ -23,9 +23,6 @@ struct nf_conntrack_l4proto
23 /* L4 Protocol number. */ 23 /* L4 Protocol number. */
24 u_int8_t l4proto; 24 u_int8_t l4proto;
25 25
26 /* Protocol name */
27 const char *name;
28
29 /* Try to fill in the third arg: dataoff is offset past network protocol 26 /* Try to fill in the third arg: dataoff is offset past network protocol
30 hdr. Return true if possible. */ 27 hdr. Return true if possible. */
31 int (*pkt_to_tuple)(const struct sk_buff *skb, 28 int (*pkt_to_tuple)(const struct sk_buff *skb,
@@ -38,13 +35,6 @@ struct nf_conntrack_l4proto
38 int (*invert_tuple)(struct nf_conntrack_tuple *inverse, 35 int (*invert_tuple)(struct nf_conntrack_tuple *inverse,
39 const struct nf_conntrack_tuple *orig); 36 const struct nf_conntrack_tuple *orig);
40 37
41 /* Print out the per-protocol part of the tuple. Return like seq_* */
42 int (*print_tuple)(struct seq_file *s,
43 const struct nf_conntrack_tuple *);
44
45 /* Print out the private part of the conntrack. */
46 int (*print_conntrack)(struct seq_file *s, const struct nf_conn *);
47
48 /* Returns verdict for packet, or -1 for invalid. */ 38 /* Returns verdict for packet, or -1 for invalid. */
49 int (*packet)(struct nf_conn *conntrack, 39 int (*packet)(struct nf_conn *conntrack,
50 const struct sk_buff *skb, 40 const struct sk_buff *skb,
@@ -65,6 +55,13 @@ struct nf_conntrack_l4proto
65 enum ip_conntrack_info *ctinfo, 55 enum ip_conntrack_info *ctinfo,
66 int pf, unsigned int hooknum); 56 int pf, unsigned int hooknum);
67 57
58 /* Print out the per-protocol part of the tuple. Return like seq_* */
59 int (*print_tuple)(struct seq_file *s,
60 const struct nf_conntrack_tuple *);
61
62 /* Print out the private part of the conntrack. */
63 int (*print_conntrack)(struct seq_file *s, const struct nf_conn *);
64
68 /* convert protoinfo to nfnetink attributes */ 65 /* convert protoinfo to nfnetink attributes */
69 int (*to_nlattr)(struct sk_buff *skb, struct nlattr *nla, 66 int (*to_nlattr)(struct sk_buff *skb, struct nlattr *nla,
70 const struct nf_conn *ct); 67 const struct nf_conn *ct);
@@ -87,6 +84,8 @@ struct nf_conntrack_l4proto
87 struct ctl_table *ctl_compat_table; 84 struct ctl_table *ctl_compat_table;
88#endif 85#endif
89#endif 86#endif
87 /* Protocol name */
88 const char *name;
90 89
91 /* Module (if any) which this is connected to. */ 90 /* Module (if any) which this is connected to. */
92 struct module *me; 91 struct module *me;