Guest User

Untitled

a guest
May 7th, 2019
88
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. [ 3934.858064] ======================================================
  2. [ 3934.858076] WARNING: possible circular locking dependency detected
  3. [ 3934.858088] 5.0.0-btrfs-next-46 #1 Not tainted
  4. [ 3934.858096] ------------------------------------------------------
  5. [ 3934.858110] fsstress/30964 is trying to acquire lock:
  6. [ 3934.858120] 0000000033cd48fb ((wq_completion)"dio/%s"sb->s_id){+.+.}, at: flush_workqueue+0x84/0x550
  7. [ 3934.858140]
  8. but task is already holding lock:
  9. [ 3934.858151] 00000000ac5e6832 (&ei->dio_sem){++++}, at: btrfs_direct_IO+0x391/0x420 [btrfs]
  10. [ 3934.858185]
  11. which lock already depends on the new lock.
  12.  
  13. [ 3934.858200]
  14. the existing dependency chain (in reverse order) is:
  15. [ 3934.858213]
  16. -> #3 (&ei->dio_sem){++++}:
  17. [ 3934.858238] btrfs_sync_file+0x1c9/0x440 [btrfs]
  18. [ 3934.858258] btrfs_file_write_iter+0x45b/0x5c0 [btrfs]
  19. [ 3934.858270] __vfs_write+0x129/0x1c0
  20. [ 3934.858279] vfs_write+0xc2/0x1b0
  21. [ 3934.858287] ksys_write+0x55/0xc0
  22. [ 3934.858295] do_syscall_64+0x60/0x1b0
  23. [ 3934.858305] entry_SYSCALL_64_after_hwframe+0x49/0xbe
  24. [ 3934.858315]
  25. -> #2 (&sb->s_type->i_mutex_key#14){+.+.}:
  26. [ 3934.858339] btrfs_sync_file+0x1aa/0x440 [btrfs]
  27. [ 3934.858350] dio_complete+0x231/0x270
  28. [ 3934.858359] process_one_work+0x21e/0x5c0
  29. [ 3934.858369] worker_thread+0x4f/0x3b0
  30. [ 3934.858377] kthread+0x103/0x140
  31. [ 3934.858386] ret_from_fork+0x3a/0x50
  32. [ 3934.858394]
  33. -> #1 ((work_completion)(&dio->complete_work)){+.+.}:
  34. [ 3934.858410] worker_thread+0x4f/0x3b0
  35. [ 3934.858419] kthread+0x103/0x140
  36. [ 3934.858432] ret_from_fork+0x3a/0x50
  37. [ 3934.858441]
  38. -> #0 ((wq_completion)"dio/%s"sb->s_id){+.+.}:
  39. [ 3934.858455] flush_workqueue+0xa7/0x550
  40. [ 3934.858464] drain_workqueue+0xc5/0x190
  41. [ 3934.858473] destroy_workqueue+0x17/0x230
  42. [ 3934.858485] sb_init_dio_done_wq+0x50/0x60
  43. [ 3934.858497] do_blockdev_direct_IO+0xe8f/0x2c90
  44. [ 3934.858518] btrfs_direct_IO+0x14d/0x420 [btrfs]
  45. [ 3934.858797] generic_file_direct_write+0xcc/0x160
  46. [ 3934.859082] btrfs_file_write_iter+0x20b/0x5c0 [btrfs]
  47. [ 3934.859359] aio_write+0x13c/0x1f0
  48. [ 3934.859644] io_submit_one+0x496/0x9c0
  49. [ 3934.859915] __x64_sys_io_submit+0xa4/0x280
  50. [ 3934.860188] do_syscall_64+0x60/0x1b0
  51. [ 3934.860453] entry_SYSCALL_64_after_hwframe+0x49/0xbe
  52. [ 3934.860718]
  53. other info that might help us debug this:
  54.  
  55. [ 3934.861473] Chain exists of:
  56. (wq_completion)"dio/%s"sb->s_id --> &sb->s_type->i_mutex_key#14 --> &ei->dio_sem
  57.  
  58. [ 3934.862214] Possible unsafe locking scenario:
  59.  
  60. [ 3934.862716] CPU0 CPU1
  61. [ 3934.862963] ---- ----
  62. [ 3934.863204] lock(&ei->dio_sem);
  63. [ 3934.863450] lock(&sb->s_type->i_mutex_key#14);
  64. [ 3934.863710] lock(&ei->dio_sem);
  65. [ 3934.863953] lock((wq_completion)"dio/%s"sb->s_id);
  66. [ 3934.864197]
  67. *** DEADLOCK ***
  68.  
  69. [ 3934.864909] 1 lock held by fsstress/30964:
  70. [ 3934.865150] #0: 00000000ac5e6832 (&ei->dio_sem){++++}, at: btrfs_direct_IO+0x391/0x420 [btrfs]
  71. [ 3934.865420]
  72. stack backtrace:
  73. [ 3934.865938] CPU: 2 PID: 30964 Comm: fsstress Not tainted 5.0.0-btrfs-next-46 #1
  74. [ 3934.866196] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.11.2-0-gf9626ccb91-prebuilt.qemu-project.org 04/01/2014
  75. [ 3934.866738] Call Trace:
  76. [ 3934.867013] dump_stack+0x7d/0xbb
  77. [ 3934.867287] print_circular_bug.isra.35+0x1d7/0x1e4
  78. [ 3934.867573] __lock_acquire+0x11f9/0x1400
  79. [ 3934.867853] ? flush_workqueue+0x84/0x550
  80. [ 3934.868133] ? lock_acquire+0xa6/0x190
  81. [ 3934.868405] lock_acquire+0xa6/0x190
  82. [ 3934.868684] ? flush_workqueue+0x84/0x550
  83. [ 3934.868964] flush_workqueue+0xa7/0x550
  84. [ 3934.869239] ? flush_workqueue+0x84/0x550
  85. [ 3934.869513] ? drain_workqueue+0xc5/0x190
  86. [ 3934.869781] drain_workqueue+0xc5/0x190
  87. [ 3934.870052] destroy_workqueue+0x17/0x230
  88. [ 3934.870324] sb_init_dio_done_wq+0x50/0x60
  89. [ 3934.870596] do_blockdev_direct_IO+0xe8f/0x2c90
  90. [ 3934.870869] ? __lock_acquire+0x33b/0x1400
  91. [ 3934.871140] ? _raw_spin_unlock+0x24/0x30
  92. [ 3934.871423] ? btrfs_endio_direct_read+0xb0/0xb0 [btrfs]
  93. [ 3934.871709] ? btrfs_swap_activate+0x620/0x620 [btrfs]
  94. [ 3934.871980] ? __lock_acquire+0x33b/0x1400
  95. [ 3934.872261] ? btrfs_direct_IO+0x14d/0x420 [btrfs]
  96. [ 3934.872542] btrfs_direct_IO+0x14d/0x420 [btrfs]
  97. [ 3934.872825] ? btrfs_endio_direct_read+0xb0/0xb0 [btrfs]
  98. [ 3934.873101] generic_file_direct_write+0xcc/0x160
  99. [ 3934.873375] ? current_time+0x47/0x80
  100. [ 3934.873657] btrfs_file_write_iter+0x20b/0x5c0 [btrfs]
  101. [ 3934.873946] aio_write+0x13c/0x1f0
  102. [ 3934.874222] ? io_submit_one+0x96/0x9c0
  103. [ 3934.874492] ? lock_acquire+0xa6/0x190
  104. [ 3934.874755] ? __might_fault+0x3e/0x90
  105. [ 3934.875015] ? __might_fault+0x3e/0x90
  106. [ 3934.875273] ? io_submit_one+0x496/0x9c0
  107. [ 3934.875539] io_submit_one+0x496/0x9c0
  108. [ 3934.875813] ? __x64_sys_io_submit+0xa4/0x280
  109. [ 3934.876077] __x64_sys_io_submit+0xa4/0x280
  110. [ 3934.876338] ? do_syscall_64+0x60/0x1b0
  111. [ 3934.876598] ? __ia32_compat_sys_io_submit+0x260/0x260
  112. [ 3934.876859] do_syscall_64+0x60/0x1b0
  113. [ 3934.877119] entry_SYSCALL_64_after_hwframe+0x49/0xbe
  114. [ 3934.877384] RIP: 0033:0x7faaea038717
  115. [ 3934.877650] Code: 00 75 08 8b 47 0c 39 47 08 74 08 e9 c3 ff ff ff 0f 1f 00 31 c0 c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 00 b8 d1 00 00 00 0f 05 <c3> 0f 1f 84 00 00 00 00 00 b8 d2 00 00 00 0f 05 c3 0f 1f 84 00 00
  116. [ 3934.878219] RSP: 002b:00007ffc454e3c28 EFLAGS: 00000206 ORIG_RAX: 00000000000000d1
  117. [ 3934.878503] RAX: ffffffffffffffda RBX: 00007ffc454e3c90 RCX: 00007faaea038717
  118. [ 3934.878792] RDX: 00007ffc454e3c48 RSI: 0000000000000001 RDI: 00007faaea879000
  119. [ 3934.879089] RBP: 0000000000000001 R08: 0000000000000003 R09: 0000000000002040
  120. [ 3934.879366] R10: 000000000000000f R11: 0000000000000206 R12: 000000000000000a
  121. [ 3934.879636] R13: 0000000000000003 R14: 00000000002e4000 R15: 0000000000001000
RAW Paste Data