xref: /linux/include/net/tc_act/tc_vlan.h (revision c7e2b9689ef81362a8091592da6cb6a7723f377a)
1*c7e2b968SJiri Pirko /*
2*c7e2b968SJiri Pirko  * Copyright (c) 2014 Jiri Pirko <jiri@resnulli.us>
3*c7e2b968SJiri Pirko  *
4*c7e2b968SJiri Pirko  * This program is free software; you can redistribute it and/or modify
5*c7e2b968SJiri Pirko  * it under the terms of the GNU General Public License as published by
6*c7e2b968SJiri Pirko  * the Free Software Foundation; either version 2 of the License, or
7*c7e2b968SJiri Pirko  * (at your option) any later version.
8*c7e2b968SJiri Pirko  */
9*c7e2b968SJiri Pirko 
10*c7e2b968SJiri Pirko #ifndef __NET_TC_VLAN_H
11*c7e2b968SJiri Pirko #define __NET_TC_VLAN_H
12*c7e2b968SJiri Pirko 
13*c7e2b968SJiri Pirko #include <net/act_api.h>
14*c7e2b968SJiri Pirko 
15*c7e2b968SJiri Pirko #define VLAN_F_POP		0x1
16*c7e2b968SJiri Pirko #define VLAN_F_PUSH		0x2
17*c7e2b968SJiri Pirko 
18*c7e2b968SJiri Pirko struct tcf_vlan {
19*c7e2b968SJiri Pirko 	struct tcf_common	common;
20*c7e2b968SJiri Pirko 	int			tcfv_action;
21*c7e2b968SJiri Pirko 	__be16			tcfv_push_vid;
22*c7e2b968SJiri Pirko 	__be16			tcfv_push_proto;
23*c7e2b968SJiri Pirko };
24*c7e2b968SJiri Pirko #define to_vlan(a) \
25*c7e2b968SJiri Pirko 	container_of(a->priv, struct tcf_vlan, common)
26*c7e2b968SJiri Pirko 
27*c7e2b968SJiri Pirko #endif /* __NET_TC_VLAN_H */
28