diff options
author | Geliang Tang <geliangtang@gmail.com> | 2017-03-24 15:14:36 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-03-24 22:42:52 +0100 |
commit | 3b1af93cf193ca4a94df5f01f480a9d820a194bb (patch) | |
tree | 45d13f8322a623acdebc49ca5c060867fae67a82 /net/sched/cls_flow.c | |
parent | Merge branch 'mlxsw-query-resources' (diff) | |
download | linux-3b1af93cf193ca4a94df5f01f480a9d820a194bb.tar.xz linux-3b1af93cf193ca4a94df5f01f480a9d820a194bb.zip |
net_sched: use setup_deferrable_timer
Use setup_deferrable_timer() instead of init_timer_deferrable() to
simplify the code.
Signed-off-by: Geliang Tang <geliangtang@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sched/cls_flow.c')
-rw-r--r-- | net/sched/cls_flow.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/net/sched/cls_flow.c b/net/sched/cls_flow.c index 3d6b9286c203..ca193af8634a 100644 --- a/net/sched/cls_flow.c +++ b/net/sched/cls_flow.c @@ -508,9 +508,8 @@ static int flow_change(struct net *net, struct sk_buff *in_skb, get_random_bytes(&fnew->hashrnd, 4); } - fnew->perturb_timer.function = flow_perturbation; - fnew->perturb_timer.data = (unsigned long)fnew; - init_timer_deferrable(&fnew->perturb_timer); + setup_deferrable_timer(&fnew->perturb_timer, flow_perturbation, + (unsigned long)fnew); tcf_exts_change(tp, &fnew->exts, &e); tcf_em_tree_change(tp, &fnew->ematches, &t); |