From: Geliang Tang Date: Tue, 20 Dec 2016 14:02:16 +0000 (+0800) Subject: net_sched: sch_netem: use rb_entry() X-Git-Tag: v4.14-rc1~1807^2~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7f7cd56c33937c6afa8a3d1f10a804c314e5b308;p=platform%2Fkernel%2Flinux-rpi.git net_sched: sch_netem: use rb_entry() To make the code clearer, use rb_entry() instead of container_of() to deal with rbtree. Signed-off-by: Geliang Tang Signed-off-by: David S. Miller --- diff --git a/net/sched/sch_netem.c b/net/sched/sch_netem.c index 9f7b380cf0a3..b7e4097bfdab 100644 --- a/net/sched/sch_netem.c +++ b/net/sched/sch_netem.c @@ -152,7 +152,7 @@ struct netem_skb_cb { static struct sk_buff *netem_rb_to_skb(struct rb_node *rb) { - return container_of(rb, struct sk_buff, rbnode); + return rb_entry(rb, struct sk_buff, rbnode); } static inline struct netem_skb_cb *netem_skb_cb(struct sk_buff *skb)