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-15 23:08:31 -05:00
2020-06-16 16:01:53 +02:00
2020-07-05 15:25:58 -07:00
2020-07-16 16:36:46 -07:00
2020-06-25 22:25:13 -07:00
2020-07-19 18:16:40 -07:00
2020-06-25 00:50:31 +02:00
2020-06-25 00:50:31 +02:00
2020-06-13 13:12:38 -07:00
2020-07-15 20:28:39 -07:00
2020-07-14 12:18:01 -07:00
2020-06-11 12:22:41 -07:00
2020-07-17 12:42:47 -07:00
2020-07-15 20:34:02 -07:00
2020-07-19 18:16:40 -07:00
2020-06-11 08:03:24 +02:00
2020-06-25 08:23:22 -07:00
2020-06-11 08:03:24 +02:00
2020-07-04 09:35:43 -05:00
2020-07-08 10:48:35 -07:00
2020-06-29 07:45:09 -06:00
2020-06-22 22:22:58 +02:00
2020-07-08 01:03:31 +02:00
2020-06-30 10:46:38 -07:00
2020-07-11 00:46:00 -07:00
2020-07-07 11:58:57 -05:00
2020-06-11 15:14:53 +02:00
2020-07-14 10:20:31 -07:00
2020-06-25 16:17:05 +02:00
2020-06-15 23:08:31 -05:00
2020-07-09 16:28:44 -07:00
2020-07-07 13:34:11 -07:00
2020-07-19 18:16:40 -07:00
2020-06-16 15:35:02 +02:00
2020-07-08 10:48:35 -07:00
2020-06-15 14:10:09 +02:00
2020-07-08 10:48:35 -07:00
2020-06-25 08:24:32 -07:00
2020-06-11 15:14:36 +02:00
2020-06-11 15:14:36 +02:00
2020-06-11 12:55:20 -07:00
2020-06-11 15:15:28 +02:00
2020-07-10 13:54:00 -07:00
2020-07-10 18:16:22 -07:00
2020-06-30 15:44:03 +02:00
2020-06-15 23:08:30 -05:00
2020-06-17 15:29:11 +02:00
2020-07-08 12:39:05 -07:00
2020-07-19 18:16:40 -07:00
2020-07-10 09:45:15 -07:00
2020-06-15 23:08:31 -05:00
2020-06-10 16:05:54 -07:00
2020-06-11 15:15:06 +02:00
2020-07-20 17:00:02 -07:00
2020-06-16 18:59:45 +02:00
2020-06-19 09:20:28 +02:00
2020-07-19 19:20:22 -07:00
2020-06-19 13:41:59 -07:00
2020-06-25 10:46:24 +02:00
2020-07-14 13:46:42 -07:00
2020-07-07 15:48:38 -07:00
2020-06-23 15:11:19 -07:00
2020-06-23 10:08:31 +02:00
2020-06-10 14:04:39 -07:00
2020-06-11 15:15:29 +02:00
2020-07-15 20:34:11 -07:00
2020-06-28 17:01:20 +02:00
2020-06-11 15:15:24 +02:00
2020-06-12 14:51:41 -04:00
2020-07-08 15:59:57 -07:00
2020-06-15 23:08:31 -05:00
2020-06-26 15:40:16 +01:00
2020-06-10 11:28:35 -07:00
2020-06-20 13:17:47 -07:00
2020-06-11 13:25:53 -07:00
2020-06-15 23:08:31 -05:00
2020-06-27 15:20:03 -07:00
2020-06-23 16:39:23 -07:00
2020-06-14 11:39:31 -07:00
2020-06-22 16:28:34 -07:00
2020-06-26 13:40:09 -07:00
2020-06-10 13:42:09 -07:00
2020-06-10 19:14:18 -07:00
2020-06-26 00:27:37 -07:00
2020-06-09 15:40:50 -07:00
2020-07-19 18:16:40 -07:00
2020-07-10 13:54:00 -07:00
2020-07-19 18:16:40 -07:00
2020-07-15 07:45:25 -07:00
2020-06-11 13:33:48 -04:00
2020-06-30 15:57:34 -07:00
2020-06-16 20:45:08 -07:00
2020-06-11 15:17:57 +02:00
2020-06-30 16:58:27 -05:00
2020-07-01 08:22:08 -07:00
2020-06-20 22:14:53 +10:00
2020-07-08 12:39:05 -07:00
2020-06-25 13:01:39 -07:00
2020-06-13 09:56:21 -07:00
2020-06-15 17:38:53 +10:00
2020-07-06 16:07:25 +02:00
2020-07-14 12:18:01 -07:00
2020-06-15 23:08:32 -05:00
2020-06-14 11:39:31 -07:00
2020-06-11 15:19:17 +02:00
2020-07-15 20:28:42 -07:00
2020-06-30 10:46:39 -07:00
2020-06-28 17:01:20 +02:00
2020-06-28 17:01:20 +02:00
2020-06-10 19:14:18 -07:00
2020-06-26 00:27:37 -07:00
2020-07-19 18:16:40 -07:00
2020-06-30 12:18:08 -06:00
2020-06-24 11:21:03 -07:00
2020-06-15 23:08:32 -05:00
2020-06-18 11:37:03 +02:00
2020-06-15 14:37:02 +02:00
2020-06-18 12:10:37 -07:00
2020-07-04 09:35:36 -05:00
2020-07-07 11:58:59 -05:00
2020-06-26 00:27:38 -07:00