Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
Merge in overtime fixes, no conflicts. Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
@@ -10,6 +10,8 @@
|
||||
#include <linux/netfilter/nf_conntrack_tuple_common.h>
|
||||
#include <net/flow_offload.h>
|
||||
#include <net/dst.h>
|
||||
#include <linux/if_pppox.h>
|
||||
#include <linux/ppp_defs.h>
|
||||
|
||||
struct nf_flowtable;
|
||||
struct nf_flow_rule;
|
||||
@@ -317,4 +319,20 @@ int nf_flow_rule_route_ipv6(struct net *net, const struct flow_offload *flow,
|
||||
int nf_flow_table_offload_init(void);
|
||||
void nf_flow_table_offload_exit(void);
|
||||
|
||||
static inline __be16 nf_flow_pppoe_proto(const struct sk_buff *skb)
|
||||
{
|
||||
__be16 proto;
|
||||
|
||||
proto = *((__be16 *)(skb_mac_header(skb) + ETH_HLEN +
|
||||
sizeof(struct pppoe_hdr)));
|
||||
switch (proto) {
|
||||
case htons(PPP_IP):
|
||||
return htons(ETH_P_IP);
|
||||
case htons(PPP_IPV6):
|
||||
return htons(ETH_P_IPV6);
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
#endif /* _NF_FLOW_TABLE_H */
|
||||
|
||||
Reference in New Issue
Block a user