summaryrefslogtreecommitdiffstats
path: root/net/sched/act_police.c
diff options
context:
space:
mode:
authorPatrick McHardy <kaber@trash.net>2007-03-23 19:29:25 +0100
committerDavid S. Miller <davem@sunset.davemloft.net>2007-04-26 07:27:55 +0200
commit3bebcda28077375470dd60545b71bba2f83335fd (patch)
treea0d610788ccfe8d3b50d6ebf3df014e98f6387bc /net/sched/act_police.c
parent[NET_SCHED]: turn PSCHED_TDIFF_SAFE into inline function (diff)
downloadlinux-3bebcda28077375470dd60545b71bba2f83335fd.tar.xz
linux-3bebcda28077375470dd60545b71bba2f83335fd.zip
[NET_SCHED]: turn PSCHED_GET_TIME into inline function
Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sched/act_police.c')
-rw-r--r--net/sched/act_police.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/net/sched/act_police.c b/net/sched/act_police.c
index 65d60a3f7761..616f465f407e 100644
--- a/net/sched/act_police.c
+++ b/net/sched/act_police.c
@@ -241,7 +241,7 @@ override:
if (ret != ACT_P_CREATED)
return ret;
- PSCHED_GET_TIME(police->tcfp_t_c);
+ police->tcfp_t_c = psched_get_time();
police->tcf_index = parm->index ? parm->index :
tcf_hash_new_index(&police_idx_gen, &police_hash_info);
h = tcf_hash(police->tcf_index, POL_TAB_MASK);
@@ -296,8 +296,7 @@ static int tcf_act_police(struct sk_buff *skb, struct tc_action *a,
return police->tcfp_result;
}
- PSCHED_GET_TIME(now);
-
+ now = psched_get_time();
toks = psched_tdiff_bounded(now, police->tcfp_t_c,
police->tcfp_burst);
if (police->tcfp_P_tab) {
@@ -495,7 +494,7 @@ struct tcf_police *tcf_police_locate(struct rtattr *rta, struct rtattr *est)
}
if (police->tcfp_P_tab)
police->tcfp_ptoks = L2T_P(police, police->tcfp_mtu);
- PSCHED_GET_TIME(police->tcfp_t_c);
+ police->tcfp_t_c = psched_get_time();
police->tcf_index = parm->index ? parm->index :
tcf_police_new_index();
police->tcf_action = parm->action;
@@ -543,7 +542,7 @@ int tcf_police(struct sk_buff *skb, struct tcf_police *police)
return police->tcfp_result;
}
- PSCHED_GET_TIME(now);
+ now = psched_get_time();
toks = psched_tdiff_bounded(now, police->tcfp_t_c,
police->tcfp_burst);
if (police->tcfp_P_tab) {