Commit abc3bc58 authored by Patrick McHardy's avatar Patrick McHardy Committed by David S. Miller

[NET]: Kill skb->tc_classid

Signed-off-by: default avatarPatrick McHardy <kaber@trash.net>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 8728b834
...@@ -196,7 +196,6 @@ struct skb_shared_info { ...@@ -196,7 +196,6 @@ struct skb_shared_info {
* @private: Data which is private to the HIPPI implementation * @private: Data which is private to the HIPPI implementation
* @tc_index: Traffic control index * @tc_index: Traffic control index
* @tc_verd: traffic control verdict * @tc_verd: traffic control verdict
* @tc_classid: traffic control classid
*/ */
struct sk_buff { struct sk_buff {
...@@ -275,9 +274,7 @@ struct sk_buff { ...@@ -275,9 +274,7 @@ struct sk_buff {
__u32 tc_index; /* traffic control index */ __u32 tc_index; /* traffic control index */
#ifdef CONFIG_NET_CLS_ACT #ifdef CONFIG_NET_CLS_ACT
__u32 tc_verd; /* traffic control verdict */ __u32 tc_verd; /* traffic control verdict */
__u32 tc_classid; /* traffic control classid */
#endif #endif
#endif #endif
......
...@@ -63,7 +63,7 @@ struct tc_action_ops ...@@ -63,7 +63,7 @@ struct tc_action_ops
__u32 type; /* TBD to match kind */ __u32 type; /* TBD to match kind */
__u32 capab; /* capabilities includes 4 bit version */ __u32 capab; /* capabilities includes 4 bit version */
struct module *owner; struct module *owner;
int (*act)(struct sk_buff **, struct tc_action *); int (*act)(struct sk_buff **, struct tc_action *, struct tcf_result *);
int (*get_stats)(struct sk_buff *, struct tc_action *); int (*get_stats)(struct sk_buff *, struct tc_action *);
int (*dump)(struct sk_buff *, struct tc_action *,int , int); int (*dump)(struct sk_buff *, struct tc_action *,int , int);
int (*cleanup)(struct tc_action *, int bind); int (*cleanup)(struct tc_action *, int bind);
......
...@@ -300,7 +300,6 @@ void __kfree_skb(struct sk_buff *skb) ...@@ -300,7 +300,6 @@ void __kfree_skb(struct sk_buff *skb)
skb->tc_index = 0; skb->tc_index = 0;
#ifdef CONFIG_NET_CLS_ACT #ifdef CONFIG_NET_CLS_ACT
skb->tc_verd = 0; skb->tc_verd = 0;
skb->tc_classid = 0;
#endif #endif
#endif #endif
...@@ -376,7 +375,6 @@ struct sk_buff *skb_clone(struct sk_buff *skb, unsigned int __nocast gfp_mask) ...@@ -376,7 +375,6 @@ struct sk_buff *skb_clone(struct sk_buff *skb, unsigned int __nocast gfp_mask)
n->tc_verd = CLR_TC_OK2MUNGE(n->tc_verd); n->tc_verd = CLR_TC_OK2MUNGE(n->tc_verd);
n->tc_verd = CLR_TC_MUNGED(n->tc_verd); n->tc_verd = CLR_TC_MUNGED(n->tc_verd);
C(input_dev); C(input_dev);
C(tc_classid);
#endif #endif
#endif #endif
......
...@@ -165,7 +165,7 @@ int tcf_action_exec(struct sk_buff *skb, struct tc_action *act, ...@@ -165,7 +165,7 @@ int tcf_action_exec(struct sk_buff *skb, struct tc_action *act,
while ((a = act) != NULL) { while ((a = act) != NULL) {
repeat: repeat:
if (a->ops && a->ops->act) { if (a->ops && a->ops->act) {
ret = a->ops->act(&skb, a); ret = a->ops->act(&skb, a, res);
if (TC_MUNGED & skb->tc_verd) { if (TC_MUNGED & skb->tc_verd) {
/* copied already, allow trampling */ /* copied already, allow trampling */
skb->tc_verd = SET_TC_OK2MUNGE(skb->tc_verd); skb->tc_verd = SET_TC_OK2MUNGE(skb->tc_verd);
...@@ -179,11 +179,6 @@ int tcf_action_exec(struct sk_buff *skb, struct tc_action *act, ...@@ -179,11 +179,6 @@ int tcf_action_exec(struct sk_buff *skb, struct tc_action *act,
act = a->next; act = a->next;
} }
exec_done: exec_done:
if (skb->tc_classid > 0) {
res->classid = skb->tc_classid;
res->class = 0;
skb->tc_classid = 0;
}
return ret; return ret;
} }
......
...@@ -135,7 +135,7 @@ tcf_gact_cleanup(struct tc_action *a, int bind) ...@@ -135,7 +135,7 @@ tcf_gact_cleanup(struct tc_action *a, int bind)
} }
static int static int
tcf_gact(struct sk_buff **pskb, struct tc_action *a) tcf_gact(struct sk_buff **pskb, struct tc_action *a, struct tcf_result *res)
{ {
struct tcf_gact *p = PRIV(a, gact); struct tcf_gact *p = PRIV(a, gact);
struct sk_buff *skb = *pskb; struct sk_buff *skb = *pskb;
......
...@@ -201,7 +201,7 @@ tcf_ipt_cleanup(struct tc_action *a, int bind) ...@@ -201,7 +201,7 @@ tcf_ipt_cleanup(struct tc_action *a, int bind)
} }
static int static int
tcf_ipt(struct sk_buff **pskb, struct tc_action *a) tcf_ipt(struct sk_buff **pskb, struct tc_action *a, struct tcf_result *res)
{ {
int ret = 0, result = 0; int ret = 0, result = 0;
struct tcf_ipt *p = PRIV(a, ipt); struct tcf_ipt *p = PRIV(a, ipt);
......
...@@ -158,7 +158,7 @@ tcf_mirred_cleanup(struct tc_action *a, int bind) ...@@ -158,7 +158,7 @@ tcf_mirred_cleanup(struct tc_action *a, int bind)
} }
static int static int
tcf_mirred(struct sk_buff **pskb, struct tc_action *a) tcf_mirred(struct sk_buff **pskb, struct tc_action *a, struct tcf_result *res)
{ {
struct tcf_mirred *p = PRIV(a, mirred); struct tcf_mirred *p = PRIV(a, mirred);
struct net_device *dev; struct net_device *dev;
......
...@@ -130,7 +130,7 @@ tcf_pedit_cleanup(struct tc_action *a, int bind) ...@@ -130,7 +130,7 @@ tcf_pedit_cleanup(struct tc_action *a, int bind)
} }
static int static int
tcf_pedit(struct sk_buff **pskb, struct tc_action *a) tcf_pedit(struct sk_buff **pskb, struct tc_action *a, struct tcf_result *res)
{ {
struct tcf_pedit *p = PRIV(a, pedit); struct tcf_pedit *p = PRIV(a, pedit);
struct sk_buff *skb = *pskb; struct sk_buff *skb = *pskb;
......
...@@ -284,7 +284,8 @@ static int tcf_act_police_cleanup(struct tc_action *a, int bind) ...@@ -284,7 +284,8 @@ static int tcf_act_police_cleanup(struct tc_action *a, int bind)
return 0; return 0;
} }
static int tcf_act_police(struct sk_buff **pskb, struct tc_action *a) static int tcf_act_police(struct sk_buff **pskb, struct tc_action *a,
struct tcf_result *res)
{ {
psched_time_t now; psched_time_t now;
struct sk_buff *skb = *pskb; struct sk_buff *skb = *pskb;
......
...@@ -44,7 +44,7 @@ static DEFINE_RWLOCK(simp_lock); ...@@ -44,7 +44,7 @@ static DEFINE_RWLOCK(simp_lock);
#include <net/pkt_act.h> #include <net/pkt_act.h>
#include <net/act_generic.h> #include <net/act_generic.h>
static int tcf_simp(struct sk_buff **pskb, struct tc_action *a) static int tcf_simp(struct sk_buff **pskb, struct tc_action *a, struct tcf_result *res)
{ {
struct sk_buff *skb = *pskb; struct sk_buff *skb = *pskb;
struct tcf_defact *p = PRIV(a, defact); struct tcf_defact *p = PRIV(a, defact);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment