Commit 4f89914
committed
KVM: s390: take srcu lock when getting/setting storage keys
The following warning was triggered by missing srcu locks around
the storage key handling functions.
=============================
WARNING: suspicious RCU usage
4.12.0+ torvalds#56 Not tainted
-----------------------------
./include/linux/kvm_host.h:572 suspicious rcu_dereference_check() usage!
rcu_scheduler_active = 2, debug_locks = 1
1 lock held by live_migration/4936:
#0: (&mm->mmap_sem){++++++}, at: [<0000000000141be0>]
kvm_arch_vm_ioctl+0x6b8/0x22d0
CPU: 8 PID: 4936 Comm: live_migration Not tainted 4.12.0+ torvalds#56
Hardware name: IBM 2964 NC9 704 (LPAR)
Call Trace:
([<000000000011378a>] show_stack+0xea/0xf0)
[<000000000055cc4c>] dump_stack+0x94/0xd8
[<000000000012ee70>] gfn_to_memslot+0x1a0/0x1b8
[<0000000000130b76>] gfn_to_hva+0x2e/0x48
[<0000000000141c3c>] kvm_arch_vm_ioctl+0x714/0x22d0
[<000000000013306c>] kvm_vm_ioctl+0x11c/0x7b8
[<000000000037e2c0>] do_vfs_ioctl+0xa8/0x6c8
[<000000000037e984>] SyS_ioctl+0xa4/0xb8
[<00000000008b20a4>] system_call+0xc4/0x27c
1 lock held by live_migration/4936:
#0: (&mm->mmap_sem){++++++}, at: [<0000000000141be0>]
kvm_arch_vm_ioctl+0x6b8/0x22d0
Signed-off-by: Christian Borntraeger <[email protected]>
Reviewed-by: Pierre Morel<[email protected]>1 parent f1ff89e commit 4f89914
1 file changed
+6
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1324 | 1324 | | |
1325 | 1325 | | |
1326 | 1326 | | |
1327 | | - | |
| 1327 | + | |
1328 | 1328 | | |
1329 | 1329 | | |
1330 | 1330 | | |
| |||
1342 | 1342 | | |
1343 | 1343 | | |
1344 | 1344 | | |
| 1345 | + | |
1345 | 1346 | | |
1346 | 1347 | | |
1347 | 1348 | | |
| |||
1353 | 1354 | | |
1354 | 1355 | | |
1355 | 1356 | | |
| 1357 | + | |
1356 | 1358 | | |
1357 | 1359 | | |
1358 | 1360 | | |
| |||
1370 | 1372 | | |
1371 | 1373 | | |
1372 | 1374 | | |
1373 | | - | |
| 1375 | + | |
1374 | 1376 | | |
1375 | 1377 | | |
1376 | 1378 | | |
| |||
1396 | 1398 | | |
1397 | 1399 | | |
1398 | 1400 | | |
| 1401 | + | |
1399 | 1402 | | |
1400 | 1403 | | |
1401 | 1404 | | |
| |||
1413 | 1416 | | |
1414 | 1417 | | |
1415 | 1418 | | |
| 1419 | + | |
1416 | 1420 | | |
1417 | 1421 | | |
1418 | 1422 | | |
| |||
0 commit comments