OpenWrt – Diff between revs 2 and 3

Subversion Repositories:
Rev:
Show entire fileIgnore whitespace
Rev 2 Rev 3
Line 9... Line 9...
9 Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> 9 Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
10 --- 10 ---
Line 11... Line 11...
11   11  
12 --- a/include/linux/netfilter.h 12 --- a/include/linux/netfilter.h
13 +++ b/include/linux/netfilter.h 13 +++ b/include/linux/netfilter.h
14 @@ -313,8 +313,6 @@ struct nf_afinfo { 14 @@ -276,8 +276,6 @@ struct nf_afinfo {
15 unsigned short family; 15 unsigned short family;
16 int (*route)(struct net *net, struct dst_entry **dst, 16 int (*route)(struct net *net, struct dst_entry **dst,
17 struct flowi *fl, bool strict); 17 struct flowi *fl, bool strict);
18 - void (*saveroute)(const struct sk_buff *skb, 18 - void (*saveroute)(const struct sk_buff *skb,
Line 123... Line 123...
123 .reroute = nf_ip_reroute, 123 .reroute = nf_ip_reroute,
124 .route_key_size = sizeof(struct ip_rt_info), 124 .route_key_size = sizeof(struct ip_rt_info),
125 }; 125 };
126 --- a/net/ipv6/netfilter.c 126 --- a/net/ipv6/netfilter.c
127 +++ b/net/ipv6/netfilter.c 127 +++ b/net/ipv6/netfilter.c
128 @@ -70,31 +70,6 @@ int ip6_route_me_harder(struct net *net, 128 @@ -69,31 +69,6 @@ int ip6_route_me_harder(struct net *net,
129 } 129 }
130 EXPORT_SYMBOL(ip6_route_me_harder); 130 EXPORT_SYMBOL(ip6_route_me_harder);
Line 131... Line 131...
131 131
132 -/* 132 -/*
Line 155... Line 155...
155 -} 155 -}
156 - 156 -
157 static int nf_ip6_reroute(struct net *net, struct sk_buff *skb, 157 static int nf_ip6_reroute(struct net *net, struct sk_buff *skb,
158 const struct nf_queue_entry *entry) 158 const struct nf_queue_entry *entry)
159 { 159 {
160 @@ -202,7 +177,6 @@ static const struct nf_ipv6_ops ipv6ops 160 @@ -201,7 +176,6 @@ static const struct nf_ipv6_ops ipv6ops
161 static const struct nf_afinfo nf_ip6_afinfo = { 161 static const struct nf_afinfo nf_ip6_afinfo = {
162 .family = AF_INET6, 162 .family = AF_INET6,
163 .route = nf_ip6_route, 163 .route = nf_ip6_route,
164 - .saveroute = nf_ip6_saveroute, 164 - .saveroute = nf_ip6_saveroute,
165 .reroute = nf_ip6_reroute, 165 .reroute = nf_ip6_reroute,
Line 174... Line 174...
174 +#include <linux/netfilter_ipv4.h> 174 +#include <linux/netfilter_ipv4.h>
175 +#include <linux/netfilter_ipv6.h> 175 +#include <linux/netfilter_ipv6.h>
176 #include <linux/netfilter_bridge.h> 176 #include <linux/netfilter_bridge.h>
177 #include <linux/seq_file.h> 177 #include <linux/seq_file.h>
178 #include <linux/rcupdate.h> 178 #include <linux/rcupdate.h>
179 @@ -108,6 +110,35 @@ void nf_queue_nf_hook_drop(struct net *n 179 @@ -111,6 +113,35 @@ unsigned int nf_queue_nf_hook_drop(struc
180 } 180 }
181 EXPORT_SYMBOL_GPL(nf_queue_nf_hook_drop); 181 EXPORT_SYMBOL_GPL(nf_queue_nf_hook_drop);
Line 182... Line 182...
182 182
183 +static void nf_ip_saveroute(const struct sk_buff *skb, 183 +static void nf_ip_saveroute(const struct sk_buff *skb,
Line 210... Line 210...
210 +} 210 +}
211 + 211 +
212 static int __nf_queue(struct sk_buff *skb, const struct nf_hook_state *state, 212 static int __nf_queue(struct sk_buff *skb, const struct nf_hook_state *state,
213 const struct nf_hook_entries *entries, 213 const struct nf_hook_entries *entries,
214 unsigned int index, unsigned int queuenum) 214 unsigned int index, unsigned int queuenum)
215 @@ -144,7 +175,16 @@ static int __nf_queue(struct sk_buff *sk 215 @@ -147,7 +178,16 @@ static int __nf_queue(struct sk_buff *sk
Line 216... Line 216...
216 216
217 nf_queue_entry_get_refs(entry); 217 nf_queue_entry_get_refs(entry);
218 skb_dst_force(skb); 218 skb_dst_force(skb);
219 - afinfo->saveroute(skb, entry); 219 - afinfo->saveroute(skb, entry);