Paul E. McKenney
fc043bd90c
fs/btrfs: Add cond_resched() for try_release_extent_mapping() stalls
...
[ Upstream commit 9f47eb5461aaeb6cb8696f9d11503ae90e4d5cb0 ]
Very large I/Os can cause the following RCU CPU stall warning:
RIP: 0010:rb_prev+0x8/0x50
Code: 49 89 c0 49 89 d1 48 89 c2 48 89 f8 e9 e5 fd ff ff 4c 89 48 10 c3 4c =
89 06 c3 4c 89 40 10 c3 0f 1f 00 48 8b 0f 48 39 cf 74 38 <48> 8b 47 10 48 85 c0 74 22 48 8b 50 08 48 85 d2 74 0c 48 89 d0 48
RSP: 0018:ffffc9002212bab0 EFLAGS: 00000287 ORIG_RAX: ffffffffffffff13
RAX: ffff888821f93630 RBX: ffff888821f93630 RCX: ffff888821f937e0
RDX: 0000000000000000 RSI: 0000000000102000 RDI: ffff888821f93630
RBP: 0000000000103000 R08: 000000000006c000 R09: 0000000000000238
R10: 0000000000102fff R11: ffffc9002212bac8 R12: 0000000000000001
R13: ffffffffffffffff R14: 0000000000102000 R15: ffff888821f937e0
__lookup_extent_mapping+0xa0/0x110
try_release_extent_mapping+0xdc/0x220
btrfs_releasepage+0x45/0x70
shrink_page_list+0xa39/0xb30
shrink_inactive_list+0x18f/0x3b0
shrink_lruvec+0x38e/0x6b0
shrink_node+0x14d/0x690
do_try_to_free_pages+0xc6/0x3e0
try_to_free_mem_cgroup_pages+0xe6/0x1e0
reclaim_high.constprop.73+0x87/0xc0
mem_cgroup_handle_over_high+0x66/0x150
exit_to_usermode_loop+0x82/0xd0
do_syscall_64+0xd4/0x100
entry_SYSCALL_64_after_hwframe+0x44/0xa9
On a PREEMPT=n kernel, the try_release_extent_mapping() function's
"while" loop might run for a very long time on a large I/O. This commit
therefore adds a cond_resched() to this loop, providing RCU any needed
quiescent states.
Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-08-21 11:01:58 +02:00
..
2019-10-17 13:42:10 -07:00
2019-08-06 18:29:35 +02:00
2018-05-30 07:50:16 +02:00
2020-01-29 10:24:34 +01:00
2019-12-21 10:40:46 +01:00
2016-10-15 12:09:13 -07:00
2018-12-01 09:44:19 +01:00
2020-08-21 11:01:58 +02:00
2020-06-03 08:16:36 +02:00
2020-05-27 16:41:48 +02:00
2020-07-31 16:44:04 +02:00
2019-08-06 18:29:38 +02:00
2020-05-27 16:41:45 +02:00
2018-11-13 11:17:03 -08:00
2019-07-21 09:05:59 +02:00
2019-05-08 07:19:10 +02:00
2019-03-23 13:19:47 +01:00
2020-06-30 15:38:25 -04:00
2020-03-11 07:53:06 +01:00
2016-10-10 20:16:43 -07:00
2018-11-27 16:09:38 +01:00
2020-01-29 10:24:03 +01:00
2020-04-24 07:59:14 +02:00
2020-08-21 11:01:52 +02:00
2020-08-21 11:01:48 +02:00
2020-06-20 10:24:13 +02:00
2018-12-17 09:38:34 +01:00
2020-07-22 09:10:53 +02:00
2020-06-30 15:38:28 -04:00
2019-11-28 18:28:50 +01:00
2020-04-24 07:58:59 +02:00
2016-10-10 20:16:43 -07:00
2016-10-10 20:16:43 -07:00
2019-05-31 06:48:12 -07:00
2017-11-30 08:39:04 +00:00
2020-04-24 07:59:03 +02:00
2019-05-08 07:19:09 +02:00
2020-01-29 10:24:19 +01:00
2019-11-25 09:52:23 +01:00
2018-11-13 11:17:02 -08:00
2016-10-10 20:16:43 -07:00
2016-10-10 20:16:43 -07:00
2019-03-13 14:04:52 -07:00
2020-07-31 16:44:02 +02:00
2018-02-03 17:05:38 +01:00
2020-06-30 15:38:22 -04:00
2020-06-20 10:24:09 +02:00
2019-02-06 17:33:30 +01:00
2016-10-30 13:09:42 -04:00
2020-06-30 15:38:44 -04:00
2016-10-10 20:16:43 -07:00
2016-09-27 21:06:21 -04:00
2020-02-28 15:42:43 +01:00
2020-06-20 10:24:11 +02:00
2020-06-20 10:24:11 +02:00
2020-01-12 11:24:20 +01:00
2020-01-04 13:40:50 +01:00
2016-10-10 20:16:43 -07:00
2020-02-28 15:42:41 +01:00
2017-06-17 06:41:56 +02:00
2018-09-05 09:20:03 +02:00
2018-09-05 09:20:10 +02:00
2018-12-17 09:38:32 +01:00
2016-09-27 21:06:21 -04:00
2020-02-14 16:31:00 -05:00
2020-02-28 15:42:30 +01:00
2019-05-25 18:26:56 +02:00
2020-08-21 11:01:49 +02:00
2018-12-21 14:11:31 +01:00
2016-10-10 20:16:43 -07:00
2017-01-09 08:32:24 +01:00
2020-06-03 08:16:42 +02:00
2019-07-10 09:55:38 +02:00
2018-06-26 08:08:09 +08:00
2019-11-06 12:18:04 +01:00
2020-06-30 15:38:30 -04:00
2019-04-05 22:29:08 +02:00
2020-05-20 08:15:32 +02:00
2018-02-25 11:05:55 +01:00
2020-06-30 15:38:35 -04:00
2016-09-27 21:20:53 -04:00
2017-07-05 14:40:26 +02:00
2018-02-28 10:18:33 +01:00
2019-03-27 14:13:04 +09:00
2019-03-05 17:57:05 +01:00
2019-03-13 14:04:58 -07:00
2019-02-12 19:44:59 +01:00
2020-05-20 08:15:41 +02:00
2018-01-31 12:55:52 +01:00
2020-05-27 16:41:40 +02:00
2020-06-20 10:24:09 +02:00
2020-04-02 17:20:27 +02:00
2017-09-20 08:20:01 +02:00
2017-09-20 08:19:59 +02:00
2016-10-07 18:46:29 -07:00
2020-04-02 17:20:38 +02:00
2020-01-12 11:24:13 +01:00
2018-02-22 15:43:48 +01:00
2017-07-21 07:42:22 +02:00
2017-10-18 09:35:39 +02:00
2020-03-11 07:53:07 +01:00
2020-05-02 17:23:10 +02:00
2018-02-17 13:21:15 +01:00
2020-03-20 09:07:44 +01:00
2019-06-11 12:22:45 +02:00
2020-05-02 17:23:20 +02:00
2017-03-15 10:02:43 +08:00
2017-01-26 08:24:37 +01:00
2019-06-11 12:22:49 +02:00
2020-01-04 13:41:06 +01:00
2016-10-11 15:06:30 -07:00
2016-10-07 18:46:30 -07:00
2019-06-11 12:22:45 +02:00
2017-06-14 15:06:01 +02:00
2019-02-06 17:33:29 +01:00
2017-05-08 07:47:54 +02:00
2019-09-06 10:19:37 +02:00
2016-10-08 11:06:08 -04:00
2020-08-21 11:01:55 +02:00