Jiri Pirko
a8b7b2d0b3
sched: sch_api: add missing rcu read lock to silence the warning
...
In case the qdisc_match_from_root function() is called from non-rcu path
with rtnl mutex held, a suspiciout rcu usage warning appears:
[ 241.504354] =============================
[ 241.504358] WARNING: suspicious RCU usage
[ 241.504366] 5.8.0-rc4-custom-01521-g72a7c7d549c3 #32 Not tainted
[ 241.504370] -----------------------------
[ 241.504378] net/sched/sch_api.c:270 RCU-list traversed in non-reader section!!
[ 241.504382]
other info that might help us debug this:
[ 241.504388]
rcu_scheduler_active = 2, debug_locks = 1
[ 241.504394] 1 lock held by tc/1391:
[ 241.504398] #0 : ffffffff85a27850 (rtnl_mutex){+.+.}-{3:3}, at: rtnetlink_rcv_msg+0x49a/0xbd0
[ 241.504431]
stack backtrace:
[ 241.504440] CPU: 0 PID: 1391 Comm: tc Not tainted 5.8.0-rc4-custom-01521-g72a7c7d549c3 #32
[ 241.504446] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.13.0-2.fc32 04/01/2014
[ 241.504453] Call Trace:
[ 241.504465] dump_stack+0x100/0x184
[ 241.504482] lockdep_rcu_suspicious+0x153/0x15d
[ 241.504499] qdisc_match_from_root+0x293/0x350
Fix this by passing the rtnl held lockdep condition down to
hlist_for_each_entry_rcu()
Reported-by: Ido Schimmel <idosch@mellanox.com>
Signed-off-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2020-07-20 17:00:02 -07:00
..
2020-06-20 21:29:27 -07:00
2020-03-30 13:45:04 -07:00
2020-07-03 14:34:53 -07:00
2020-07-11 00:46:00 -07:00
2020-07-11 00:46:00 -07:00
2020-07-03 14:34:53 -07:00
2020-06-19 12:53:30 -07:00
2020-06-25 19:29:51 -07:00
2020-01-17 10:58:15 +01:00
2019-10-30 18:07:51 -07:00
2019-05-30 11:26:32 -07:00
2019-05-30 11:26:32 -07:00
2019-05-30 11:26:32 -07:00
2020-06-19 12:53:30 -07:00
2020-07-03 14:34:53 -07:00
2019-11-05 14:03:11 -08:00
2020-06-19 12:53:30 -07:00
2020-06-19 12:53:30 -07:00
2020-02-17 14:17:02 -08:00
2019-11-05 18:20:55 -08:00
2020-07-11 00:46:00 -07:00
2019-10-30 18:07:51 -07:00
2019-11-26 15:42:43 -08:00
2020-06-19 12:53:30 -07:00
2020-07-16 16:48:34 -07:00
2020-01-27 10:51:43 +01:00
2020-01-27 10:51:43 +01:00
2019-05-30 11:26:32 -07:00
2020-07-03 14:34:53 -07:00
2020-07-11 00:46:00 -07:00
2020-01-27 10:51:43 +01:00
2020-06-19 12:53:30 -07:00
2020-03-16 01:59:32 -07:00
2019-05-30 11:26:32 -07:00
2019-05-30 11:26:32 -07:00
2020-02-01 12:25:06 -08:00
2020-06-22 20:55:09 -07:00
2020-06-19 20:19:24 -07:00
2020-07-13 17:20:40 -07:00
2019-05-30 11:26:32 -07:00
2020-07-03 14:34:53 -07:00
2020-07-03 14:34:53 -07:00
2020-07-03 14:34:53 -07:00
2020-02-29 21:27:02 -08:00
2019-05-30 11:26:32 -07:00
2019-05-30 11:26:32 -07:00
2020-07-13 17:20:40 -07:00
2020-07-01 17:43:27 -07:00
2020-05-01 16:08:19 -07:00
2020-07-20 17:00:02 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-02-19 17:49:48 -08:00
2019-12-03 11:53:55 -08:00
2019-12-06 11:58:45 -08:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00
2020-07-16 16:48:34 -07:00