summaryrefslogtreecommitdiffstats
path: root/net/sched/sch_cbq.c
diff options
context:
space:
mode:
authorYang Yingliang <yangyingliang@huawei.com>2014-03-12 10:20:32 +0800
committerDavid S. Miller <davem@davemloft.net>2014-03-13 15:39:20 -0400
commitd59b7d8059ddc4f9ac1f0904d28ea62a252e8de7 (patch)
tree7aa563d736287fe18daace9bbe0919c240715dab /net/sched/sch_cbq.c
parent31c14a97039f6706205648602c81426f878906d0 (diff)
downloadlinux-d59b7d8059ddc4f9ac1f0904d28ea62a252e8de7.tar.bz2
net_sched: return nla_nest_end() instead of skb->len
nla_nest_end() already has return skb->len, so replace return skb->len with return nla_nest_end instead(). Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sched/sch_cbq.c')
-rw-r--r--net/sched/sch_cbq.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/net/sched/sch_cbq.c b/net/sched/sch_cbq.c
index 2f80d01d42a6..ead526467cca 100644
--- a/net/sched/sch_cbq.c
+++ b/net/sched/sch_cbq.c
@@ -1563,8 +1563,7 @@ static int cbq_dump(struct Qdisc *sch, struct sk_buff *skb)
goto nla_put_failure;
if (cbq_dump_attr(skb, &q->link) < 0)
goto nla_put_failure;
- nla_nest_end(skb, nest);
- return skb->len;
+ return nla_nest_end(skb, nest);
nla_put_failure:
nla_nest_cancel(skb, nest);
@@ -1599,8 +1598,7 @@ cbq_dump_class(struct Qdisc *sch, unsigned long arg,
goto nla_put_failure;
if (cbq_dump_attr(skb, cl) < 0)
goto nla_put_failure;
- nla_nest_end(skb, nest);
- return skb->len;
+ return nla_nest_end(skb, nest);
nla_put_failure:
nla_nest_cancel(skb, nest);