---Problem Description--- There can be rcu stalls when running lots of large guests with storage keys:
[1377614.579833] rcu: INFO: rcu_sched self-detected stall on CPU [1377614.579845] rcu: 18-....: (2099 ticks this GP) idle=54e/1/0x4000000000000002 softirq=35598716/35598716 fqs=998 [1377614.579895] (t=2100 jiffies g=155867385 q=20879) [1377614.579898] Task dump for CPU 18: [1377614.579899] CPU 1/KVM R running task 0 1030947 256019 0x06000004 [1377614.579902] Call Trace: [1377614.579912] ([<0000001f1f4b4f52>] show_stack+0x7a/0xc0) [1377614.579918] [<0000001f1ec8e96c>] sched_show_task.part.0+0xdc/0x100 [1377614.579919] [<0000001f1f4b7248>] rcu_dump_cpu_stacks+0xc0/0x100 [1377614.579924] [<0000001f1ecdd10c>] rcu_sched_clock_irq+0x75c/0x980 [1377614.579926] [<0000001f1eceb26c>] update_process_times+0x3c/0x80 [1377614.579931] [<0000001f1ecfcfea>] tick_sched_handle.isra.0+0x4a/0x70 [1377614.579932] [<0000001f1ecfd28e>] tick_sched_timer+0x5e/0xc0 [1377614.579933] [<0000001f1ecec294>] __hrtimer_run_queues+0x114/0x2f0 [1377614.579935] [<0000001f1ececfdc>] hrtimer_interrupt+0x12c/0x2a0 [1377614.579938] [<0000001f1ebecb6a>] do_IRQ+0xaa/0xb0 [1377614.579942] [<0000001f1f4c6d08>] ext_int_handler+0x130/0x134 [1377614.579945] [<0000001f1ec0af10>] ptep_zap_key+0x40/0x60
Contact Information = <email address hidden>
---uname output--- RELEASE: 5.4.0-90-generic VERSION: #101-Ubuntu SMP Fri Oct 15 19:59:45 UTC 2021
== Comment: #1 - Christian Borntraeger <email address hidden> - 2022-05-24 03:59:37 == This is a test patch that might address the rcu stalls.
== Comment: #2 - Christian Borntraeger <email address hidden> - 2022-05-24 04:00:22 == This is a 2nd patch that reduces the cost of key setting.
---Problem Description---
There can be rcu stalls when running lots of large guests with storage keys:
[1377614.579833] rcu: INFO: rcu_sched self-detected stall on CPU 1/0x40000000000 00002 softirq= 35598716/ 35598716 fqs=998 4f52>] show_stack+ 0x7a/0xc0) 96c>] sched_show_ task.part. 0+0xdc/ 0x100 248>] rcu_dump_ cpu_stacks+ 0xc0/0x100 10c>] rcu_sched_ clock_irq+ 0x75c/0x980 26c>] update_ process_ times+0x3c/ 0x80 fea>] tick_sched_ handle. isra.0+ 0x4a/0x70 28e>] tick_sched_ timer+0x5e/ 0xc0 294>] __hrtimer_ run_queues+ 0x114/0x2f0 fdc>] hrtimer_ interrupt+ 0x12c/0x2a0 b6a>] do_IRQ+0xaa/0xb0 d08>] ext_int_ handler+ 0x130/0x134 f10>] ptep_zap_ key+0x40/ 0x60
[1377614.579845] rcu: 18-....: (2099 ticks this GP) idle=54e/
[1377614.579895] (t=2100 jiffies g=155867385 q=20879)
[1377614.579898] Task dump for CPU 18:
[1377614.579899] CPU 1/KVM R running task 0 1030947 256019 0x06000004
[1377614.579902] Call Trace:
[1377614.579912] ([<0000001f1f4b
[1377614.579918] [<0000001f1ec8e
[1377614.579919] [<0000001f1f4b7
[1377614.579924] [<0000001f1ecdd
[1377614.579926] [<0000001f1eceb
[1377614.579931] [<0000001f1ecfc
[1377614.579932] [<0000001f1ecfd
[1377614.579933] [<0000001f1ecec
[1377614.579935] [<0000001f1ecec
[1377614.579938] [<0000001f1ebec
[1377614.579942] [<0000001f1f4c6
[1377614.579945] [<0000001f1ec0a
Contact Information = <email address hidden>
---uname output---
RELEASE: 5.4.0-90-generic
VERSION: #101-Ubuntu SMP Fri Oct 15 19:59:45 UTC 2021
== Comment: #1 - Christian Borntraeger <email address hidden> - 2022-05-24 03:59:37 ==
This is a test patch that might address the rcu stalls.
== Comment: #2 - Christian Borntraeger <email address hidden> - 2022-05-24 04:00:22 ==
This is a 2nd patch that reduces the cost of key setting.