From: Florian Westphal Date: Tue, 14 Jun 2016 04:16:27 +0000 (+0200) Subject: htb: call qdisc_root with rcu read lock held X-Git-Tag: v4.7-rc6~25^2~59 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=0ee13627f963f9c5c9544ed19d82854836d5e676;p=platform%2Fkernel%2Flinux-exynos.git htb: call qdisc_root with rcu read lock held saw a debug splat: net/include/net/sch_generic.h:287 suspicious rcu_dereference_check() usage! other info that might help us debug this: rcu_scheduler_active = 1, debug_locks = 0 2 locks held by kworker/2:1/710: #0: ("events"){.+.+.+}, at: [] #1: ((&q->work)){+.+...}, at: [] process_one_work+0x14d/0x690 Workqueue: events htb_work_func Call Trace: [] dump_stack+0x85/0xc2 [] lockdep_rcu_suspicious+0xe7/0x120 [] htb_work_func+0x67/0x70 Signed-off-by: Florian Westphal Acked-by: Cong Wang Signed-off-by: David S. Miller --- diff --git a/net/sched/sch_htb.c b/net/sched/sch_htb.c index d4b4218..62f9d81 100644 --- a/net/sched/sch_htb.c +++ b/net/sched/sch_htb.c @@ -1007,7 +1007,9 @@ static void htb_work_func(struct work_struct *work) struct htb_sched *q = container_of(work, struct htb_sched, work); struct Qdisc *sch = q->watchdog.qdisc; + rcu_read_lock(); __netif_schedule(qdisc_root(sch)); + rcu_read_unlock(); } static int htb_init(struct Qdisc *sch, struct nlattr *opt)