net sched actions: skbedit add support for mod-ing skb pkt_type
Extremely useful for setting packet type to host so i dont have to modify the dst mac address using pedit (which requires that i know the mac address) Example usage: tc filter add dev eth0 parent ffff: protocol ip pref 9 u32 \ match ip src 5.5.5.5/32 \ flowid 1:5 action skbedit ptype host This will tag all packets incoming from 5.5.5.5 with type PACKET_HOST Signed-off-by: Jamal Hadi Salim <jhs@mojatatu.com> Acked-by: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
8b10cab64c
commit
ff202ee1ed
@@ -24,11 +24,11 @@
|
||||
|
||||
struct tcf_skbedit {
|
||||
struct tcf_common common;
|
||||
u32 flags;
|
||||
u32 priority;
|
||||
u32 mark;
|
||||
u16 queue_mapping;
|
||||
/* XXX: 16-bit pad here? */
|
||||
u32 flags;
|
||||
u32 priority;
|
||||
u32 mark;
|
||||
u16 queue_mapping;
|
||||
u16 ptype;
|
||||
};
|
||||
#define to_skbedit(a) \
|
||||
container_of(a->priv, struct tcf_skbedit, common)
|
||||
|
Reference in New Issue
Block a user