Suppress race in kernfs_refresh_inode

==================================================================
ThreadSanitizer: data-race in kernfs_refresh_inode

Write of size 2 by thread T577 (K825):
 [<ffffffff81301d0d>] kernfs_refresh_inode+0x3d/0x130 fs/kernfs/inode.c:267
 [<ffffffff81301ed2>] kernfs_iop_permission+0x52/0x80 fs/kernfs/inode.c:379
 [<     inlined    >] __inode_permission+0xb7/0x110 do_inode_permission fs/namei.c:375
 [<ffffffff81256fc7>] __inode_permission+0xb7/0x110 fs/namei.c:409
 [<ffffffff8125704a>] inode_permission+0x2a/0x90 fs/namei.c:460
 [<     inlined    >] link_path_walk+0x367/0x1cd0 may_lookup fs/namei.c:1496
 [<ffffffff8125a667>] link_path_walk+0x367/0x1cd0 fs/namei.c:1758
 [<ffffffff81260a84>] path_openat+0xe4/0xb10 fs/namei.c:3206
 [<ffffffff81263a01>] do_filp_open+0x51/0xd0 fs/namei.c:3259
 [<ffffffff812451a3>] do_sys_open+0x183/0x2c0 fs/open.c:998
 [<     inlined    >] SyS_open+0x35/0x50 SYSC_open fs/open.c:1016
 [<ffffffff81245315>] SyS_open+0x35/0x50 fs/open.c:1011
 [<ffffffff81e0a3e9>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = ffffe8ffffd010b0

Previous read of size 2 by thread T286 (K819):
 [<     inlined    >] generic_permission+0x31/0x220 acl_permission_check fs/namei.c:286
 [<ffffffff81256d21>] generic_permission+0x31/0x220 fs/namei.c:330
 [<ffffffff81301ee9>] kernfs_iop_permission+0x69/0x80 fs/kernfs/inode.c:382
 [<     inlined    >] __inode_permission+0xb7/0x110 do_inode_permission fs/namei.c:375
 [<ffffffff81256fc7>] __inode_permission+0xb7/0x110 fs/namei.c:409
 [<ffffffff8125704a>] inode_permission+0x2a/0x90 fs/namei.c:460
 [<     inlined    >] link_path_walk+0x367/0x1cd0 may_lookup fs/namei.c:1496
 [<ffffffff8125a667>] link_path_walk+0x367/0x1cd0 fs/namei.c:1758
 [<ffffffff81260a84>] path_openat+0xe4/0xb10 fs/namei.c:3206
 [<ffffffff81263a01>] do_filp_open+0x51/0xd0 fs/namei.c:3259
 [<ffffffff812451a3>] do_sys_open+0x183/0x2c0 fs/open.c:998
 [<     inlined    >] SyS_open+0x35/0x50 SYSC_open fs/open.c:1016
 [<ffffffff81245315>] SyS_open+0x35/0x50 fs/open.c:1011
 [<ffffffff81e0a3e9>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = 0

DBG: addr: ffff8800db447478
DBG: first offset: 0, second offset: 0
DBG: T577 clock: {T577: 2715294, T286: 2574182}
DBG: T286 clock: {T286: 2574192}
==================================================================
Suppress race in owner_running

The first stack in the report is wrong (addr2line is off by 1 line). Should be:
 [<     inlined    >] mutex_spin_on_owner+0x2d/0xd0 owner_running kernel/locking/mutex.c:212
 [<ffffffff810d119d>] mutex_spin_on_owner+0x2d/0xd0 kernel/locking/mutex.c:234

==================================================================
ThreadSanitizer: data-race in mutex_spin_on_owner

Read of size 8 by thread T573 (K821):
 [<     inlined    >] mutex_spin_on_owner+0x2d/0xd0 __rcu_read_lock include/linux/rcupdate.h:240
 [<     inlined    >] mutex_spin_on_owner+0x2d/0xd0 rcu_read_lock include/linux/rcupdate.h:910
 [<ffffffff810d119d>] mutex_spin_on_owner+0x2d/0xd0 kernel/locking/mutex.c:233
 [<ffffffff810d1300>] mutex_optimistic_spin+0xc0/0x2a0 kernel/locking/mutex.c:340 (discriminator 1)
 [<     inlined    >] __mutex_lock_slowpath+0x32/0x1c0 __mutex_lock_common kernel/locking/mutex.c:509
 [<ffffffff81e06d52>] __mutex_lock_slowpath+0x32/0x1c0 kernel/locking/mutex.c:832
 [<     inlined    >] mutex_lock+0x34/0x70 __mutex_fastpath_lock ./arch/x86/include/asm/mutex_64.h:28
 [<ffffffff81e06f14>] mutex_lock+0x34/0x70 kernel/locking/mutex.c:104
 [<     inlined    >] link_path_walk+0x1282/0x1cd0 lookup_slow fs/namei.c:1470
 [<     inlined    >] link_path_walk+0x1282/0x1cd0 walk_component fs/namei.c:1551
 [<ffffffff8125b582>] link_path_walk+0x1282/0x1cd0 fs/namei.c:1805
 [<ffffffff81260a84>] path_openat+0xe4/0xb10 fs/namei.c:3206
 [<ffffffff81263a01>] do_filp_open+0x51/0xd0 fs/namei.c:3259
 [<ffffffff812451a3>] do_sys_open+0x183/0x2c0 fs/open.c:998
 [<     inlined    >] SyS_open+0x35/0x50 SYSC_open fs/open.c:1016
 [<ffffffff81245315>] SyS_open+0x35/0x50 fs/open.c:1011
 [<ffffffff81e0a3e9>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = ffffe8ffffd810b0

Previous write of size 8 by thread T579 (K827):
 [<     inlined    >] mutex_lock+0x55/0x70 mutex_set_owner kernel/locking/mutex.h:22
 [<ffffffff81e06f35>] mutex_lock+0x55/0x70 kernel/locking/mutex.c:106
 [<     inlined    >] link_path_walk+0x1282/0x1cd0 lookup_slow fs/namei.c:1470
 [<     inlined    >] link_path_walk+0x1282/0x1cd0 walk_component fs/namei.c:1551
 [<ffffffff8125b582>] link_path_walk+0x1282/0x1cd0 fs/namei.c:1805
 [<ffffffff8125e857>] path_lookupat+0x87/0x1bd0 fs/namei.c:1957
 [<ffffffff812603e3>] filename_lookup+0x43/0x110 fs/namei.c:2000
 [<ffffffff8126238c>] user_path_parent+0x4c/0x70 fs/namei.c:2185
 [<ffffffff812627d4>] do_unlinkat+0xa4/0x4c0 fs/namei.c:3730
 [<     inlined    >] SyS_unlink+0x22/0x40 SYSC_unlink fs/namei.c:3804
 [<ffffffff81264422>] SyS_unlink+0x22/0x40 fs/namei.c:3802
 [<ffffffff81e0a3e9>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = 0

DBG: addr: ffff8801bee19b58
DBG: first offset: 0, second offset: 0
DBG: T573 clock: {T573: 76448, T579: 1407239}
DBG: T579 clock: {T579: 1407249}
==================================================================
Merge branch 'tsan-fixes' into tsan-dev
Suppress race in mutex_spin_on_owner

==================================================================
ThreadSanitizer: data-race in mutex_spin_on_owner

Read of size 8 by thread T571 (K819):
 [<ffffffff810d1206>] mutex_spin_on_owner+0x96/0xb0 kernel/locking/mutex.c:247
 [<ffffffff810d12e0>] mutex_optimistic_spin+0xc0/0x2a0 kernel/locking/mutex.c:340 (discriminator 1)
 [<     inlined    >] __mutex_lock_slowpath+0x32/0x1c0 __mutex_lock_common kernel/locking/mutex.c:509
 [<ffffffff81e06d32>] __mutex_lock_slowpath+0x32/0x1c0 kernel/locking/mutex.c:832
 [<     inlined    >] mutex_lock+0x34/0x70 __mutex_fastpath_lock ./arch/x86/include/asm/mutex_64.h:28
 [<ffffffff81e06ef4>] mutex_lock+0x34/0x70 kernel/locking/mutex.c:104
 [<     inlined    >] link_path_walk+0x1282/0x1cd0 lookup_slow fs/namei.c:1470
 [<     inlined    >] link_path_walk+0x1282/0x1cd0 walk_component fs/namei.c:1551
 [<ffffffff8125b562>] link_path_walk+0x1282/0x1cd0 fs/namei.c:1805
 [<ffffffff8125e837>] path_lookupat+0x87/0x1bd0 fs/namei.c:1957
 [<ffffffff812603c3>] filename_lookup+0x43/0x110 fs/namei.c:2000
udevadm (816) used greatest stack depth: 12752 bytes left
 [<ffffffff8126236c>] user_path_parent+0x4c/0x70 fs/namei.c:2185
 [<ffffffff812627b4>] do_unlinkat+0xa4/0x4c0 fs/namei.c:3730
 [<     inlined    >] SyS_unlink+0x22/0x40 SYSC_unlink fs/namei.c:3804
 [<ffffffff81264402>] SyS_unlink+0x22/0x40 fs/namei.c:3802
 [<ffffffff81e0a3e9>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = ffffe8ffffd810b0

Previous write of size 8 by thread T572 (K820):
 [<     inlined    >] mutex_unlock+0x1e/0x50 mutex_clear_owner kernel/locking/mutex.h:27
 [<ffffffff81e0707e>] mutex_unlock+0x1e/0x50 kernel/locking/mutex.c:423
 [<     inlined    >] link_path_walk+0x12b9/0x1cd0 lookup_slow fs/namei.c:1472
 [<     inlined    >] link_path_walk+0x12b9/0x1cd0 walk_component fs/namei.c:1551
 [<ffffffff8125b599>] link_path_walk+0x12b9/0x1cd0 fs/namei.c:1805
 [<ffffffff81260a64>] path_openat+0xe4/0xb10 fs/namei.c:3206
 [<ffffffff812639e1>] do_filp_open+0x51/0xd0 fs/namei.c:3259
 [<ffffffff81245183>] do_sys_open+0x183/0x2c0 fs/open.c:998
 [<     inlined    >] SyS_open+0x35/0x50 SYSC_open fs/open.c:1016
 [<ffffffff812452f5>] SyS_open+0x35/0x50 fs/open.c:1011
 [<ffffffff81e0a3e9>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = 0

DBG: addr: ffff8801bed55638
DBG: first offset: 0, second offset: 0
DBG: T571 clock: {T571: 65537, T572: 57402}
DBG: T572 clock: {T572: 57568}
==================================================================
Suppress races in owner_running && rwsem_spin_on_owner

See the previous two commits about similar races in mutex.

==================================================================
ThreadSanitizer: data-race in rwsem_spin_on_owner

Read of size 8 by thread T568 (K815):
 [<     inlined    >] rwsem_spin_on_owner+0x2d/0xd0 __rcu_read_lock include/linux/rcupdate.h:240
 [<     inlined    >] rwsem_spin_on_owner+0x2d/0xd0 rcu_read_lock include/linux/rcupdate.h:910
 [<ffffffff810d3cbd>] rwsem_spin_on_owner+0x2d/0xd0 kernel/locking/rwsem-xadd.c:330
 [<     inlined    >] rwsem_down_write_failed+0x10f/0x4c0 rwsem_optimistic_spin kernel/locking/rwsem-xadd.c:363
 [<ffffffff81e081af>] rwsem_down_write_failed+0x10f/0x4c0 kernel/locking/rwsem-xadd.c:416
 [<ffffffff8151f153>] call_rwsem_down_write_failed+0x13/0x20 arch/x86/lib/rwsem.S:105
 [<     inlined    >] anon_vma_fork+0x122/0x200 anon_vma_lock_write include/linux/rmap.h:122
 [<ffffffff8120ca52>] anon_vma_fork+0x122/0x200 mm/rmap.c:310
 [<     inlined    >] copy_process.part.41+0x2885/0x2dd0 dup_mmap kernel/fork.c:424
 [<     inlined    >] copy_process.part.41+0x2885/0x2dd0 dup_mm kernel/fork.c:864
 [<     inlined    >] copy_process.part.41+0x2885/0x2dd0 copy_mm kernel/fork.c:918
 [<ffffffff81080335>] copy_process.part.41+0x2885/0x2dd0 kernel/fork.c:1391
 [<     inlined    >] do_fork+0xfa/0x570 copy_process kernel/fork.c:1210
 [<ffffffff81080a9a>] do_fork+0xfa/0x570 kernel/fork.c:1657
 [<     inlined    >] SyS_clone+0x33/0x50 SYSC_clone kernel/fork.c:1754
 [<ffffffff81081013>] SyS_clone+0x33/0x50 kernel/fork.c:1748
 [<ffffffff81e0a729>] stub_clone+0x69/0x90 arch/x86/kernel/entry_64.S:624
DBG: cpu = ffffe8ffffc010b0

Previous write of size 8 by thread T580 (K828):
 [<     inlined    >] down_write+0x63/0x80 rwsem_set_owner kernel/locking/rwsem.c:19
 [<ffffffff81e07753>] down_write+0x63/0x80 kernel/locking/rwsem.c:82
 [<     inlined    >] unlink_anon_vmas+0x92/0x2d0 lock_anon_vma_root mm/rmap.c:225
 [<ffffffff8120c212>] unlink_anon_vmas+0x92/0x2d0 mm/rmap.c:335
 [<ffffffff811f8ec9>] free_pgtables+0x59/0x1d0 mm/memory.c:539
 [<ffffffff81202008>] unmap_region+0x138/0x1a0 mm/mmap.c:2402 (discriminator 8)
 [<ffffffff81205943>] do_munmap+0x3a3/0x670 mm/mmap.c:2598
 [<ffffffff81205c61>] vm_munmap+0x51/0x70 mm/mmap.c:2612
 [<     inlined    >] SyS_munmap+0x29/0x40 SYSC_munmap mm/mmap.c:2621
 [<ffffffff81207359>] SyS_munmap+0x29/0x40 mm/mmap.c:2618
 [<ffffffff81e0a3e9>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = 0

DBG: addr: ffff8801be917428
DBG: first offset: 0, second offset: 0
DBG: T568 clock: {T568: 906791, T580: 13256}
DBG: T580 clock: {T580: 13445}
==================================================================
Merge branch 'tsan-fixes' into tsan-dev
Fix another race in skb_queue_tail

==================================================================
ThreadSanitizer: data-race in skb_queue_tail

Write of size 8 by thread T315 (K864):
 [<     inlined    >] skb_queue_tail+0x63/0xc0 __skb_insert include/linux/skbuff.h:1351
 [<     inlined    >] skb_queue_tail+0x63/0xc0 __skb_queue_before include/linux/skbuff.h:1457
 [<     inlined    >] skb_queue_tail+0x63/0xc0 __skb_queue_tail include/linux/skbuff.h:1491
 [<ffffffff81abf763>] skb_queue_tail+0x63/0xc0 net/core/skbuff.c:2335
 [<ffffffff81c2bb7c>] unix_stream_sendmsg+0x2dc/0x7a0 net/unix/af_unix.c:1711
 [<     inlined    >] sock_sendmsg+0x119/0x150 __sock_sendmsg_nosec net/socket.c:643
 [<     inlined    >] sock_sendmsg+0x119/0x150 __sock_sendmsg net/socket.c:651
 [<ffffffff81ab4589>] sock_sendmsg+0x119/0x150 net/socket.c:662
 [<ffffffff81ab4db9>] SYSC_sendto+0x1e9/0x2d0 net/socket.c:1818
 [<ffffffff81ab5ec4>] SyS_sendto+0x44/0x60 net/socket.c:1783
 [<ffffffff81e0a3a9>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = ffffe8ffffd810b0

Previous read of size 8 by thread T314 (K863):
 [<     inlined    >] unix_poll+0xe0/0x170 skb_queue_empty include/linux/skbuff.h:992
 [<ffffffff81c29f20>] unix_poll+0xe0/0x170 net/unix/af_unix.c:2195
 [<ffffffff81ab3f1d>] sock_poll+0x9d/0x210 net/socket.c:1168
 [<     inlined    >] SyS_epoll_ctl+0x74d/0x1230 ep_item_poll fs/eventpoll.c:800
 [<     inlined    >] SyS_epoll_ctl+0x74d/0x1230 ep_insert fs/eventpoll.c:1310
 [<     inlined    >] SyS_epoll_ctl+0x74d/0x1230 SYSC_epoll_ctl fs/eventpoll.c:1924
 [<ffffffff812b5d0d>] SyS_epoll_ctl+0x74d/0x1230 fs/eventpoll.c:1823
 [<ffffffff81e0a3a9>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = 0

DBG: addr: ffff8801c1ba8950
DBG: first offset: 0, second offset: 0
DBG: T315 clock: {T315: 96367, T314: 136382}
DBG: T314 clock: {T314: 136552}
==================================================================
Merge branch 'tsan-fixes' into tsan-dev
Add comment to kt_mtx_pre_lock
Suppress race in shmem_mknod

==================================================================
ThreadSanitizer: data-race in shmem_mknod

Write of size 8 by thread T572 (K820):
 [<ffffffff811db16a>] shmem_mknod+0xca/0x120 mm/shmem.c:2224
 [<ffffffff811db253>] shmem_create+0x33/0x50 mm/shmem.c:2272
 [<ffffffff81259126>] vfs_create+0x156/0x1f0 fs/namei.c:2529
 [<     inlined    >] do_last+0x1458/0x1d10 lookup_open fs/namei.c:2868
 [<ffffffff8125ded8>] do_last+0x1458/0x1d10 fs/namei.c:2955
 [<ffffffff81260a64>] path_openat+0x104/0xb10 fs/namei.c:3210
 [<ffffffff812639c1>] do_filp_open+0x51/0xd0 fs/namei.c:3259
 [<ffffffff81245163>] do_sys_open+0x183/0x2c0 fs/open.c:998
 [<     inlined    >] SyS_open+0x35/0x50 SYSC_open fs/open.c:1016
 [<ffffffff812452d5>] SyS_open+0x35/0x50 fs/open.c:1011
 [<ffffffff81e0a3e9>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = ffffe8ffffd810b0

Previous read of size 8 by thread T573 (K821):
 [<ffffffff8124dc92>] generic_fillattr+0xf2/0x1a0 fs/stat.c:29
 [<ffffffff8124dddd>] vfs_getattr_nosec+0x9d/0xa0 fs/stat.c:59
 [<ffffffff8124df5e>] vfs_getattr+0x4e/0x70 fs/stat.c:72
 [<ffffffff8124e05c>] vfs_fstatat+0x6c/0xb0 fs/stat.c:110
 [<     inlined    >] SYSC_newstat+0x2d/0x60 vfs_stat fs/stat.c:123
 [<ffffffff8124e91d>] SYSC_newstat+0x2d/0x60 fs/stat.c:270
 [<ffffffff8124edb1>] SyS_newstat+0x21/0x40 fs/stat.c:266
 [<ffffffff81e0a3e9>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = 0

DBG: addr: ffff8800db031dc0
DBG: first offset: 0, second offset: 0
DBG: T572 clock: {T572: 373949, T573: 235706}
DBG: T573 clock: {T573: 237677}
==================================================================
Merge branch 'tsan-fixes' into tsan-dev
Fix race in ext4_es_lookup_extent

==================================================================
ThreadSanitizer: data-race in ext4_es_lookup_extent

Read of size 8 by thread T353 (K902):
 [<ffffffff8138376a>] ext4_es_lookup_extent+0x13a/0x3a0 fs/ext4/extents_status.c:787
 [<ffffffff81318b35>] ext4_map_blocks+0x85/0x850 fs/ext4/inode.c:493
 [<ffffffff81319c90>] ext4_getblk+0x70/0x240 fs/ext4/inode.c:734
 [<ffffffff81319e95>] ext4_bread+0x35/0xe0 fs/ext4/inode.c:785
 [<ffffffff81326af6>] __ext4_read_dirblock+0x36/0x590 fs/ext4/namei.c:99
 [<ffffffff81329e3b>] ext4_dx_find_entry+0x18b/0x220 fs/ext4/namei.c:1353
 [<ffffffff8132a695>] ext4_find_entry+0x7c5/0x810 fs/ext4/namei.c:1235
 [<ffffffff8132b0bb>] ext4_lookup+0x6b/0x1d0 fs/ext4/namei.c:1397
 [<ffffffff81255802>] lookup_real+0x52/0xa0 fs/namei.c:1346
 [<ffffffff8125794d>] __lookup_hash+0x5d/0x80 fs/namei.c:1364
 [<     inlined    >] path_lookupat+0x1300/0x1bd0 lookup_slow fs/namei.c:1471
 [<     inlined    >] path_lookupat+0x1300/0x1bd0 walk_component fs/namei.c:1551
 [<     inlined    >] path_lookupat+0x1300/0x1bd0 lookup_last fs/namei.c:1926
 [<ffffffff8125f8f0>] path_lookupat+0x1300/0x1bd0 fs/namei.c:1960
 [<ffffffff81260203>] filename_lookup+0x43/0x110 fs/namei.c:2000
 [<ffffffff812636a0>] user_path_at_empty+0x60/0xd0 fs/namei.c:2151
 [<ffffffff81263742>] user_path_at+0x32/0x50 fs/namei.c:2162
 [<ffffffff8124deaa>] vfs_fstatat+0x5a/0xb0 fs/stat.c:106
 [<     inlined    >] SYSC_newstat+0x2d/0x60 vfs_stat fs/stat.c:123
 [<ffffffff8124e77d>] SYSC_newstat+0x2d/0x60 fs/stat.c:270
 [<ffffffff8124ec11>] SyS_newstat+0x21/0x40 fs/stat.c:266
 [<ffffffff81e09ca9>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = ffffe8ffffd010b0

Previous write of size 8 by thread T355 (K904):
 [<ffffffff8138377d>] ext4_es_lookup_extent+0x14d/0x3a0 fs/ext4/extents_status.c:787
 [<ffffffff81318b35>] ext4_map_blocks+0x85/0x850 fs/ext4/inode.c:493
 [<ffffffff813193f8>] _ext4_get_block+0xf8/0x310 fs/ext4/inode.c:697
 [<ffffffff81319646>] ext4_get_block+0x36/0x50 fs/ext4/inode.c:716
 [<ffffffff812ab874>] do_mpage_readpage+0x644/0x920 fs/mpage.c:204
 [<ffffffff812abd03>] mpage_readpages+0x1b3/0x220 fs/mpage.c:374
 [<ffffffff81315522>] ext4_readpages+0x62/0x90 fs/ext4/inode.c:2839
 [<     inlined    >] __do_page_cache_readahead+0x291/0x3b0 read_pages mm/readahead.c:121
 [<ffffffff811cb1b1>] __do_page_cache_readahead+0x291/0x3b0 mm/readahead.c:200
 [<     inlined    >] ondemand_readahead+0x15b/0x3d0 ra_submit mm/internal.h:35
 [<ffffffff811cb42b>] ondemand_readahead+0x15b/0x3d0 mm/readahead.c:472
 [<ffffffff811cb8c6>] page_cache_sync_readahead+0x66/0xa0 mm/readahead.c:504
 [<     inlined    >] generic_file_read_iter+0x72c/0x860 do_generic_file_read mm/filemap.c:1496
 [<ffffffff811babcc>] generic_file_read_iter+0x72c/0x860 mm/filemap.c:1738
 [<ffffffff81245adb>] new_sync_read+0xfb/0x150 fs/read_write.c:406
 [<ffffffff81246820>] vfs_read+0xe0/0x260 fs/read_write.c:430
 [<ffffffff8124f831>] kernel_read+0x81/0xc0 fs/exec.c:803
 [<ffffffff8124fc95>] prepare_binprm+0x185/0x280 fs/exec.c:1299
 [<ffffffff812525ab>] do_execve_common.isra.30+0x6bb/0xa40 fs/exec.c:1496
 [<     inlined    >] SyS_execve+0x39/0x50 do_execve fs/exec.c:1555
 [<     inlined    >] SyS_execve+0x39/0x50 SYSC_execve fs/exec.c:1609
 [<ffffffff81252e39>] SyS_execve+0x39/0x50 fs/exec.c:1604
 [<ffffffff81e0a239>] stub_execve+0x69/0xa0 arch/x86/kernel/entry_64.S:648
DBG: cpu = 0

DBG: addr: ffff8800db817440
DBG: first offset: 0, second offset: 0
DBG: T353 clock: {T353: 220767, T355: 194534}
DBG: T355 clock: {T355: 195420}
==================================================================
Fix race in ext4_es_lru_add

==================================================================
ThreadSanitizer: data-race in ext4_es_lru_add

Read of size 8 by thread T355 (K904):
 [<     inlined    >] ext4_es_lru_add+0x68/0x130 list_empty include/linux/list.h:189
 [<ffffffff81383dd8>] ext4_es_lru_add+0x68/0x130 fs/ext4/extents_status.c:1235
 [<ffffffff81363d97>] ext4_ext_map_blocks+0x397/0x1fc0 fs/ext4/extents.c:4623 (discriminator 4)
 [<ffffffff81318d75>] ext4_map_blocks+0x2c5/0x850 fs/ext4/inode.c:523
 [<ffffffff813193f8>] _ext4_get_block+0xf8/0x310 fs/ext4/inode.c:697
 [<ffffffff81319646>] ext4_get_block+0x36/0x50 fs/ext4/inode.c:716
 [<ffffffff812ab874>] do_mpage_readpage+0x644/0x920 fs/mpage.c:204
 [<ffffffff812abd03>] mpage_readpages+0x1b3/0x220 fs/mpage.c:374
 [<ffffffff81315522>] ext4_readpages+0x62/0x90 fs/ext4/inode.c:2839
 [<     inlined    >] __do_page_cache_readahead+0x291/0x3b0 read_pages mm/readahead.c:121
 [<ffffffff811cb1b1>] __do_page_cache_readahead+0x291/0x3b0 mm/readahead.c:200
 [<     inlined    >] filemap_fault+0x5d0/0x640 ra_submit mm/internal.h:35
 [<     inlined    >] filemap_fault+0x5d0/0x640 do_sync_mmap_readahead mm/filemap.c:1821
 [<ffffffff811bbd20>] filemap_fault+0x5d0/0x640 mm/filemap.c:1898
 [<ffffffff811f8080>] __do_fault+0xa0/0x120 mm/memory.c:2715
 [<ffffffff811fb43b>] do_cow_fault.isra.72+0x7b/0x280 mm/memory.c:2944
 [<     inlined    >] handle_mm_fault+0x5f1/0xe40 do_nonlinear_fault mm/memory.c:3087
 [<     inlined    >] handle_mm_fault+0x5f1/0xe40 handle_pte_fault mm/memory.c:3217
 [<     inlined    >] handle_mm_fault+0x5f1/0xe40 __handle_mm_fault mm/memory.c:3337
 [<ffffffff811fd521>] handle_mm_fault+0x5f1/0xe40 mm/memory.c:3366
 [<ffffffff8106f8cc>] __do_page_fault+0x21c/0x8a0 arch/x86/mm/fault.c:1239
 [<ffffffff8106ff7b>] do_page_fault+0x2b/0x40 arch/x86/mm/fault.c:1299
 [<ffffffff81e0b8c8>] page_fault+0x28/0x30 arch/x86/kernel/entry_64.S:1255
 [<ffffffff8151ecbf>] clear_user+0x4f/0x70 arch/x86/lib/usercopy_64.c:52
 [<ffffffff812cbf10>] padzero+0x40/0x50 fs/binfmt_elf.c:118
 [<ffffffff812cf29b>] load_elf_binary+0xedb/0x2660 fs/binfmt_elf.c:574
 [<ffffffff81250af1>] search_binary_handler+0x131/0x300 fs/exec.c:1374
 [<     inlined    >] do_execve_common.isra.30+0x7c7/0xa40 exec_binprm fs/exec.c:1416
 [<ffffffff812526b7>] do_execve_common.isra.30+0x7c7/0xa40 fs/exec.c:1513
 [<     inlined    >] SyS_execve+0x39/0x50 do_execve fs/exec.c:1555
 [<     inlined    >] SyS_execve+0x39/0x50 SYSC_execve fs/exec.c:1609
 [<ffffffff81252e39>] SyS_execve+0x39/0x50 fs/exec.c:1604
 [<ffffffff81e0a239>] stub_execve+0x69/0xa0 arch/x86/kernel/entry_64.S:648
DBG: cpu = ffffe8ffffc010b0

Previous write of size 8 by thread T360 (K909):
 [<     inlined    >] ext4_es_lru_add+0x11d/0x130 __list_add include/linux/list.h:45
 [<     inlined    >] ext4_es_lru_add+0x11d/0x130 list_add_tail include/linux/list.h:77
 [<ffffffff81383e8d>] ext4_es_lru_add+0x11d/0x130 fs/ext4/extents_status.c:1240
 [<ffffffff81363d97>] ext4_ext_map_blocks+0x397/0x1fc0 fs/ext4/extents.c:4623 (discriminator 4)
 [<ffffffff81318d75>] ext4_map_blocks+0x2c5/0x850 fs/ext4/inode.c:523
 [<ffffffff813193f8>] _ext4_get_block+0xf8/0x310 fs/ext4/inode.c:697
 [<ffffffff81319646>] ext4_get_block+0x36/0x50 fs/ext4/inode.c:716
 [<ffffffff812ab874>] do_mpage_readpage+0x644/0x920 fs/mpage.c:204
 [<ffffffff812abd03>] mpage_readpages+0x1b3/0x220 fs/mpage.c:374
 [<ffffffff81315522>] ext4_readpages+0x62/0x90 fs/ext4/inode.c:2839
 [<     inlined    >] __do_page_cache_readahead+0x291/0x3b0 read_pages mm/readahead.c:121
 [<ffffffff811cb1b1>] __do_page_cache_readahead+0x291/0x3b0 mm/readahead.c:200
 [<     inlined    >] ondemand_readahead+0x15b/0x3d0 ra_submit mm/internal.h:35
 [<ffffffff811cb42b>] ondemand_readahead+0x15b/0x3d0 mm/readahead.c:472
 [<ffffffff811cb8c6>] page_cache_sync_readahead+0x66/0xa0 mm/readahead.c:504
 [<     inlined    >] generic_file_read_iter+0x72c/0x860 do_generic_file_read mm/filemap.c:1496
 [<ffffffff811babcc>] generic_file_read_iter+0x72c/0x860 mm/filemap.c:1738
 [<ffffffff81245adb>] new_sync_read+0xfb/0x150 fs/read_write.c:406
 [<ffffffff81246820>] vfs_read+0xe0/0x260 fs/read_write.c:430
 [<ffffffff8124f831>] kernel_read+0x81/0xc0 fs/exec.c:803
 [<ffffffff8124fc95>] prepare_binprm+0x185/0x280 fs/exec.c:1299
 [<ffffffff812525ab>] do_execve_common.isra.30+0x6bb/0xa40 fs/exec.c:1496
 [<     inlined    >] SyS_execve+0x39/0x50 do_execve fs/exec.c:1555
 [<     inlined    >] SyS_execve+0x39/0x50 SYSC_execve fs/exec.c:1609
 [<ffffffff81252e39>] SyS_execve+0x39/0x50 fs/exec.c:1604
 [<ffffffff81e0a239>] stub_execve+0x69/0xa0 arch/x86/kernel/entry_64.S:648
DBG: cpu = ffffe8ffffc810b0

DBG: addr: ffff8800db4d2350
DBG: first offset: 0, second offset: 0
DBG: T355 clock: {T355: 211197, T360: 7677}
DBG: T360 clock: {T360: 12398}
==================================================================
Merge branch 'tsan-fixes' into tsan-dev
Suppress race in __internal_add_timer

Wrong line info in the second stack, racing access is the call of timer_pending in blk_add_timer.

==================================================================
ThreadSanitizer: data-race in __internal_add_timer

Write of size 8 by thread T4 (K4):
 [<     inlined    >] __internal_add_timer+0xea/0x160 __list_add include/linux/list.h:45
 [<     inlined    >] __internal_add_timer+0xea/0x160 list_add_tail include/linux/list.h:77
 [<ffffffff810fc19a>] __internal_add_timer+0xea/0x160 kernel/time/timer.c:397
 [<ffffffff810fcd12>] internal_add_timer+0x52/0x110 kernel/time/timer.c:403
 [<     inlined    >] mod_timer+0x1bb/0x300 __mod_timer kernel/time/timer.c:802
 [<ffffffff810ff95b>] mod_timer+0x1bb/0x300 kernel/time/timer.c:897
 [<ffffffff810ffad8>] add_timer+0x38/0x50 kernel/time/timer.c:946
 [<ffffffff810a57ab>] __queue_delayed_work+0xeb/0x220 kernel/workqueue.c:1452
 [<ffffffff810a608c>] queue_delayed_work_on+0x5c/0x90 kernel/workqueue.c:1477
 [<     inlined    >] cache_reap+0x2cd/0x360 queue_delayed_work include/linux/workqueue.h:489
 [<     inlined    >] cache_reap+0x2cd/0x360 schedule_delayed_work include/linux/workqueue.h:561
 [<ffffffff8122f06d>] cache_reap+0x2cd/0x360 mm/slab.c:3895
 [<ffffffff810a888a>] process_one_work+0x2aa/0x730 kernel/workqueue.c:2027
 [<ffffffff810a97cb>] worker_thread+0xcb/0x750 kernel/workqueue.c:2161
 [<ffffffff810b100c>] kthread+0x15c/0x180 kernel/kthread.c:207
 [<ffffffff81e09bbc>] ret_from_fork+0x7c/0xb0 arch/x86/kernel/entry_64.S:347
DBG: cpu = ffffe8ffffc010b0

Previous read of size 8 by thread T310 (K858):
 [<     inlined    >] blk_add_timer+0xf2/0x230 blk_rq_timeout block/blk-timeout.c:175
 [<ffffffff814e0192>] blk_add_timer+0xf2/0x230 block/blk-timeout.c:215
 [<ffffffff814d53a9>] blk_start_request+0x69/0xc0 block/blk-core.c:2347
 [<ffffffff817ef188>] scsi_request_fn+0x128/0xaa0 drivers/scsi/scsi_lib.c:1707
 [<     inlined    >] __blk_run_queue+0x6f/0xa0 __blk_run_queue_uncond block/blk-core.c:285
 [<ffffffff814cc61f>] __blk_run_queue+0x6f/0xa0 block/blk-core.c:302
 [<ffffffff814d671b>] blk_queue_bio+0x54b/0x550 block/blk-core.c:1647
 [<ffffffff814ce751>] generic_make_request+0x1b1/0x240 block/blk-core.c:1909
 [<ffffffff814ce887>] submit_bio+0xa7/0x260 block/blk-core.c:1961
 [<ffffffff8129d2bf>] _submit_bh+0x22f/0x2b0 fs/buffer.c:3045
 [<     inlined    >] ll_rw_block+0xae/0x100 submit_bh fs/buffer.c:3057
 [<ffffffff8129d8ce>] ll_rw_block+0xae/0x100 fs/buffer.c:3106
 [<ffffffff8132a4b6>] ext4_find_entry+0x5e6/0x810 fs/ext4/namei.c:1279
 [<ffffffff8132b0bb>] ext4_lookup+0x6b/0x1d0 fs/ext4/namei.c:1397
 [<ffffffff81255802>] lookup_real+0x52/0xa0 fs/namei.c:1346
 [<ffffffff8125794d>] __lookup_hash+0x5d/0x80 fs/namei.c:1364
 [<     inlined    >] link_path_walk+0x129e/0x1cd0 lookup_slow fs/namei.c:1471
 [<     inlined    >] link_path_walk+0x129e/0x1cd0 walk_component fs/namei.c:1551
 [<ffffffff8125b3be>] link_path_walk+0x129e/0x1cd0 fs/namei.c:1805
 [<ffffffff812608a4>] path_openat+0xe4/0xb10 fs/namei.c:3206
 [<ffffffff81263821>] do_filp_open+0x51/0xd0 fs/namei.c:3259
 [<ffffffff81244fe3>] do_sys_open+0x183/0x2c0 fs/open.c:998
 [<     inlined    >] SyS_open+0x35/0x50 SYSC_open fs/open.c:1016
 [<ffffffff81245155>] SyS_open+0x35/0x50 fs/open.c:1011
 [<ffffffff81e09c69>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = 0

DBG: addr: ffff8801c1a3bd80
DBG: first offset: 0, second offset: 0
DBG: T4 clock: {T4: 1506239, T310: 10716638}
DBG: T310 clock: {T310: 10730684}
==================================================================
Suppress race in drain_array

==================================================================
ThreadSanitizer: data-race in drain_array

Read of size 4 by thread T50 (K47):
 [<ffffffff8122e894>] drain_array+0x54/0x1a0 mm/slab.c:3812 (discriminator 1)
 [<ffffffff8122eec6>] cache_reap+0x126/0x360 mm/slab.c:3878
 [<ffffffff810a888a>] process_one_work+0x2aa/0x730 kernel/workqueue.c:2027
 [<ffffffff810a97cb>] worker_thread+0xcb/0x750 kernel/workqueue.c:2161
 [<ffffffff810b100c>] kthread+0x15c/0x180 kernel/kthread.c:207
 [<ffffffff81e09bbc>] ret_from_fork+0x7c/0xb0 arch/x86/kernel/entry_64.S:347
DBG: cpu = ffffe8ffffd810b0

Previous write of size 4 by thread T272 (K802):
 [<     inlined    >] kmem_cache_free+0x33a/0x610 cache_flusharray mm/slab.c:3319
 [<     inlined    >] kmem_cache_free+0x33a/0x610 __cache_free mm/slab.c:3380
 [<ffffffff8122e3ba>] kmem_cache_free+0x33a/0x610 mm/slab.c:3541
 [<ffffffff81201fb1>] remove_vma+0xb1/0xd0 mm/mmap.c:282
 [<ffffffff81207309>] exit_mmap+0x109/0x1c0 mm/mmap.c:2778
 [<ffffffff8107d61f>] mmput+0x5f/0x160 kernel/fork.c:658
 [<     inlined    >] do_exit+0x429/0x1430 exit_mm kernel/exit.c:461
 [<ffffffff81084669>] do_exit+0x429/0x1430 kernel/exit.c:747
 [<ffffffff8108741f>] do_group_exit+0x7f/0x140 kernel/exit.c:890
 [<     inlined    >] __wake_up_parent+0x0/0x50 SYSC_exit_group kernel/exit.c:901
 [<ffffffff81087500>] __wake_up_parent+0x0/0x50 kernel/exit.c:899
 [<ffffffff81e09c69>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = 0

DBG: addr: ffff8801c58bf000
DBG: first offset: 0, second offset: 0
DBG: T50 clock: {T50: 33411, T272: 15022}
DBG: T272 clock: {T272: 24195}
==================================================================
Merge branch 'tsan-fixes' into tsan-dev
Fix race in part_round_stats

==================================================================
ThreadSanitizer: data-race in part_round_stats

Read of size 8 by thread T442 (K987):
 [<     inlined    >] part_round_stats+0x63/0xc0 part_round_stats_single block/blk-core.c:1290
 [<ffffffff814cd723>] part_round_stats+0x63/0xc0 block/blk-core.c:1323
 [<ffffffff814d4a6e>] blk_account_io_start+0x20e/0x2d0 block/blk-core.c:2187
 [<ffffffff814d63b5>] blk_queue_bio+0x235/0x550 block/blk-core.c:1643
 [<ffffffff814ce701>] generic_make_request+0x1b1/0x240 block/blk-core.c:1909
 [<ffffffff814ce837>] submit_bio+0xa7/0x260 block/blk-core.c:1961
 [<ffffffff812aaf8d>] mpage_bio_submit+0x3d/0x50 fs/mpage.c:62
 [<ffffffff812abcea>] mpage_readpages+0x1ea/0x220 fs/mpage.c:384
 [<ffffffff813154d2>] ext4_readpages+0x62/0x90 fs/ext4/inode.c:2839
 [<     inlined    >] __do_page_cache_readahead+0x291/0x3b0 read_pages mm/readahead.c:121
 [<ffffffff811cb171>] __do_page_cache_readahead+0x291/0x3b0 mm/readahead.c:200
 [<     inlined    >] ondemand_readahead+0x15b/0x3d0 ra_submit mm/internal.h:35
 [<ffffffff811cb3eb>] ondemand_readahead+0x15b/0x3d0 mm/readahead.c:472
 [<ffffffff811cb886>] page_cache_sync_readahead+0x66/0xa0 mm/readahead.c:504
 [<     inlined    >] generic_file_read_iter+0x72c/0x860 do_generic_file_read mm/filemap.c:1496
 [<ffffffff811bab8c>] generic_file_read_iter+0x72c/0x860 mm/filemap.c:1738
 [<ffffffff81245a8b>] new_sync_read+0xfb/0x150 fs/read_write.c:406
 [<ffffffff812467d0>] vfs_read+0xe0/0x260 fs/read_write.c:430
 [<     inlined    >] SyS_read+0x6b/0xe0 SYSC_read fs/read_write.c:569
 [<ffffffff81247a0b>] SyS_read+0x6b/0xe0 fs/read_write.c:562
 [<ffffffff81e09b69>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = ffffe8ffffc010b0

Previous write of size 8 by thread T446 (K991):
 [<ffffffff814cd69a>] part_round_stats_single.part.63+0x14a/0x170 block/blk-core.c:1299
 [<     inlined    >] part_round_stats+0x7a/0xc0 part_round_stats_single block/blk-core.c:1290
 [<ffffffff814cd73a>] part_round_stats+0x7a/0xc0 block/blk-core.c:1323
 [<ffffffff814d4a6e>] blk_account_io_start+0x20e/0x2d0 block/blk-core.c:2187
 [<ffffffff814d63b5>] blk_queue_bio+0x235/0x550 block/blk-core.c:1643
 [<ffffffff814ce701>] generic_make_request+0x1b1/0x240 block/blk-core.c:1909
 [<ffffffff814ce837>] submit_bio+0xa7/0x260 block/blk-core.c:1961
 [<ffffffff812aaf8d>] mpage_bio_submit+0x3d/0x50 fs/mpage.c:62
 [<ffffffff812abcea>] mpage_readpages+0x1ea/0x220 fs/mpage.c:384
 [<ffffffff813154d2>] ext4_readpages+0x62/0x90 fs/ext4/inode.c:2839
 [<     inlined    >] __do_page_cache_readahead+0x291/0x3b0 read_pages mm/readahead.c:121
 [<ffffffff811cb171>] __do_page_cache_readahead+0x291/0x3b0 mm/readahead.c:200
 [<     inlined    >] ondemand_readahead+0x15b/0x3d0 ra_submit mm/internal.h:35
 [<ffffffff811cb3eb>] ondemand_readahead+0x15b/0x3d0 mm/readahead.c:472
 [<ffffffff811cb72a>] page_cache_async_readahead+0xca/0xf0 mm/readahead.c:548
 [<     inlined    >] generic_file_read_iter+0x63f/0x860 do_generic_file_read mm/filemap.c:1504
 [<ffffffff811baa9f>] generic_file_read_iter+0x63f/0x860 mm/filemap.c:1738
 [<ffffffff81245a8b>] new_sync_read+0xfb/0x150 fs/read_write.c:406
 [<ffffffff812467d0>] vfs_read+0xe0/0x260 fs/read_write.c:430
 [<     inlined    >] SyS_read+0x6b/0xe0 SYSC_read fs/read_write.c:569
 [<ffffffff81247a0b>] SyS_read+0x6b/0xe0 fs/read_write.c:562
 [<ffffffff81e09b69>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = ffffe8ffffd810b0

DBG: addr: ffff8800dba9c260
DBG: first offset: 0, second offset: 0
DBG: T442 clock: {T442: 8247402, T446: 2405922}
DBG: T446 clock: {T446: 2405930}
==================================================================
Suppress races in pipe_poll and pipe_release

==================================================================
ThreadSanitizer: data-race in pipe_poll

Read of size 4 by thread T446 (K991):
 [<ffffffff81252ed9>] pipe_poll+0x69/0x130 fs/pipe.c:509
 [<     inlined    >] do_sys_poll+0x47b/0x7c0 do_pollfd fs/select.c:767
 [<     inlined    >] do_sys_poll+0x47b/0x7c0 do_poll fs/select.c:817
 [<ffffffff81269f9b>] do_sys_poll+0x47b/0x7c0 fs/select.c:911
 [<     inlined    >] SyS_poll+0x145/0x1c0 SYSC_poll fs/select.c:969
 [<ffffffff8126a4f5>] SyS_poll+0x145/0x1c0 fs/select.c:957
 [<ffffffff81e09b69>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = ffffe8ffffd810b0

Previous write of size 4 by thread T488 (K1031):
 [<ffffffff8125398b>] pipe_write+0x2fb/0x6d0 fs/pipe.c:433
 [<ffffffff81245bde>] new_sync_write+0xfe/0x150 fs/read_write.c:478
 [<ffffffff81246a63>] vfs_write+0x113/0x310 fs/read_write.c:534
 [<     inlined    >] SyS_write+0x6b/0xe0 SYSC_write fs/read_write.c:585
 [<ffffffff81247aeb>] SyS_write+0x6b/0xe0 fs/read_write.c:577
 [<ffffffff81e09b69>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = 0

DBG: addr: ffff8800daea2500
DBG: first offset: 0, second offset: 0
DBG: T446 clock: {T446: 10151140, T488: 141784}
DBG: T488 clock: {T488: 221372}
==================================================================
==================================================================
ThreadSanitizer: data-race in pipe_release

Write of size 4 by thread T488 (K1031):
 [<ffffffff81254509>] pipe_release+0x89/0x150 fs/pipe.c:554
 [<ffffffff8124912f>] __fput+0x15f/0x310 fs/file_table.c:208
 [<ffffffff8124935d>] ____fput+0x1d/0x30 fs/file_table.c:244
 [<ffffffff810ae966>] task_work_run+0x106/0x120 kernel/task_work.c:123 (discriminator 1)
 [<     inlined    >] do_exit+0x48c/0x1430 exit_task_work include/linux/task_work.h:21
 [<ffffffff810846cc>] do_exit+0x48c/0x1430 kernel/exit.c:760
 [<ffffffff8108741f>] do_group_exit+0x7f/0x140 kernel/exit.c:890
 [<     inlined    >] __wake_up_parent+0x0/0x50 SYSC_exit_group kernel/exit.c:901
 [<ffffffff81087500>] __wake_up_parent+0x0/0x50 kernel/exit.c:899
 [<ffffffff81e09b69>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = ffffe8ffffd810b0

Previous read of size 4 by thread T446 (K991):
 [<ffffffff81252f05>] pipe_poll+0x95/0x130 fs/pipe.c:513
 [<     inlined    >] do_sys_poll+0x47b/0x7c0 do_pollfd fs/select.c:767
 [<     inlined    >] do_sys_poll+0x47b/0x7c0 do_poll fs/select.c:817
 [<ffffffff81269f9b>] do_sys_poll+0x47b/0x7c0 fs/select.c:911
 [<     inlined    >] SyS_poll+0x145/0x1c0 SYSC_poll fs/select.c:969
 [<ffffffff8126a4f5>] SyS_poll+0x145/0x1c0 fs/select.c:957
 [<ffffffff81e09b69>] system_call_fastpath+0x12/0x17 arch/x86/kernel/entry_64.S:422
DBG: cpu = 0

DBG: addr: ffff8800daea2510
DBG: first offset: 0, second offset: 0
DBG: T488 clock: {T488: 237699, T446: 10151655}
DBG: T446 clock: {T446: 10151837}
==================================================================
Merge branch 'tsan-fixes' into tsan-dev