Verify in fwd_port_input() that we are not passed packets that are shared.
This commit is contained in:
1 parent
cdbc9a4a81
commit
ae0af9b03d
3 files changed
+19
No files matched your search
@@ -68,6 +68,7 @@ int run_flow_through_tables(struct sw_chain *chain, struct sk_buff *skb,
|
||||
void fwd_port_input(struct sw_chain *chain, struct sk_buff *skb,
|
||||
struct net_bridge_port *p)
|
||||
{
|
||||
WARN_ON_ONCE(skb_shared(skb));
|
||||
if (run_flow_through_tables(chain, skb, p))
|
||||
dp_output_control(chain->dp, skb, fwd_save_skb(skb),
|
||||
chain->dp->miss_send_len,
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
#ifndef _ASM_GENERIC_BUG_H
|
||||
#define _ASM_GENERIC_BUG_H
|
||||
|
||||
#include <linux/compiler.h>
|
||||
|
||||
#define WARN_ON_ONCE(condition) ({ \
|
||||
static int __warned; \
|
||||
int __ret_warn_once = !!(condition); \
|
||||
\
|
||||
if (unlikely(__ret_warn_once) && !__warned) { \
|
||||
WARN_ON(1); \
|
||||
__warned = 1; \
|
||||
} \
|
||||
unlikely(__ret_warn_once); \
|
||||
})
|
||||
|
||||
#endif
|
||||
@@ -3,6 +3,7 @@
|
||||
|
||||
#include_next <linux/kernel.h>
|
||||
#include <linux/config.h>
|
||||
#include <asm/bug.h>
|
||||
|
||||
/**
|
||||
* container_of - cast a member of a structure out to the containing structure
|
||||
|
||||
Reference in new issue
Block a user