syzbot


KMSAN: uninit-value in generic_bin_search

Status: closed as invalid on 2021/03/24 07:53
Reported-by: syzbot+@syzkaller.appspotmail.com
First crash: 685d, last: 685d
similar bugs (2):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KMSAN: kernel-infoleak in _copy_to_iter (7) btrfs ntfs3 erofs udf C 137277 now 334d 23/24 internal: reported C repro on 2022/03/09 07:32
upstream KMSAN: uninit-value in generic_bin_search (2) 1 606d 602d 0/24 auto-closed as invalid on 2021/10/08 02:20

Sample crash report:
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
=====================================================
=====================================================
BUG: KMSAN: uninit-value in btrfs_comp_cpu_keys fs/btrfs/ctree.c:1546 [inline]
BUG: KMSAN: uninit-value in comp_keys fs/btrfs/ctree.c:1522 [inline]
BUG: KMSAN: uninit-value in generic_bin_search+0x703/0xbc0 fs/btrfs/ctree.c:1696
CPU: 1 PID: 10525 Comm: syz-executor.4 Tainted: G    B             5.11.0-rc7-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 __dump_stack lib/dump_stack.c:79 [inline]
 dump_stack+0x21c/0x280 lib/dump_stack.c:120
 kmsan_report+0xfb/0x1e0 mm/kmsan/kmsan_report.c:118
 __msan_warning+0x5f/0xa0 mm/kmsan/kmsan_instr.c:197
 btrfs_comp_cpu_keys fs/btrfs/ctree.c:1546 [inline]
 comp_keys fs/btrfs/ctree.c:1522 [inline]
 generic_bin_search+0x703/0xbc0 fs/btrfs/ctree.c:1696
 btrfs_bin_search fs/btrfs/ctree.c:1718 [inline]
 btrfs_search_slot+0x2144/0x3f20 fs/btrfs/ctree.c:2718
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x5ec/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
RIP: 0023:0xf7fa6549
Code: 03 74 c0 01 10 05 03 74 b8 01 10 06 03 74 b4 01 10 07 03 74 b0 01 10 08 03 74 d8 01 00 00 00 00 00 51 52 55 89 e5 0f 34 cd 80 <5d> 5a 59 c3 90 90 90 90 8d b4 26 00 00 00 00 8d b4 26 00 00 00 00
RSP: 002b:00000000ffe830ec EFLAGS: 00000292 ORIG_RAX: 0000000000000034
RAX: 0000000000000000 RBX: 00000000ffe83190 RCX: 0000000000000002
RDX: 000000000816c000 RSI: 0000000000000000 RDI: 00000000080e9e6a
RBP: 00000000ffe83190 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000

Uninit was created at:
 kmsan_save_stack_with_flags+0x3c/0x90 mm/kmsan/kmsan.c:121
 kmsan_alloc_page+0xd3/0x1f0 mm/kmsan/kmsan_shadow.c:274
 __alloc_pages_nodemask+0x827/0xf90 mm/page_alloc.c:5038
 alloc_pages_current+0x7b6/0xb60 mm/mempolicy.c:2267
 alloc_pages include/linux/gfp.h:547 [inline]
 __page_cache_alloc mm/filemap.c:981 [inline]
 pagecache_get_page+0x1127/0x2070 mm/filemap.c:1841
 find_or_create_page include/linux/pagemap.h:404 [inline]
 alloc_extent_buffer+0x78c/0x28d0 fs/btrfs/extent_io.c:5293
 btrfs_find_create_tree_block+0xb6/0xd0 fs/btrfs/disk-io.c:959
 btrfs_init_new_buffer fs/btrfs/extent-tree.c:4597 [inline]
 btrfs_alloc_tree_block+0x545/0x2100 fs/btrfs/extent-tree.c:4698
 alloc_tree_block_no_bg_flush fs/btrfs/ctree.c:989 [inline]
 __btrfs_cow_block+0xb93/0x2760 fs/btrfs/ctree.c:1045
 btrfs_cow_block+0xa3c/0xc90 fs/btrfs/ctree.c:1490
 btrfs_search_slot+0x1ad5/0x3f20 fs/btrfs/ctree.c:2670
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
=====================================================
=====================================================
BUG: KMSAN: uninit-value in btrfs_comp_cpu_keys fs/btrfs/ctree.c:1548 [inline]
BUG: KMSAN: uninit-value in comp_keys fs/btrfs/ctree.c:1522 [inline]
BUG: KMSAN: uninit-value in generic_bin_search+0x766/0xbc0 fs/btrfs/ctree.c:1696
CPU: 1 PID: 10525 Comm: syz-executor.4 Tainted: G    B             5.11.0-rc7-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 __dump_stack lib/dump_stack.c:79 [inline]
 dump_stack+0x21c/0x280 lib/dump_stack.c:120
 kmsan_report+0xfb/0x1e0 mm/kmsan/kmsan_report.c:118
 __msan_warning+0x5f/0xa0 mm/kmsan/kmsan_instr.c:197
 btrfs_comp_cpu_keys fs/btrfs/ctree.c:1548 [inline]
 comp_keys fs/btrfs/ctree.c:1522 [inline]
 generic_bin_search+0x766/0xbc0 fs/btrfs/ctree.c:1696
 btrfs_bin_search fs/btrfs/ctree.c:1718 [inline]
 btrfs_search_slot+0x2144/0x3f20 fs/btrfs/ctree.c:2718
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x5ec/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
RIP: 0023:0xf7fa6549
Code: 03 74 c0 01 10 05 03 74 b8 01 10 06 03 74 b4 01 10 07 03 74 b0 01 10 08 03 74 d8 01 00 00 00 00 00 51 52 55 89 e5 0f 34 cd 80 <5d> 5a 59 c3 90 90 90 90 8d b4 26 00 00 00 00 8d b4 26 00 00 00 00
RSP: 002b:00000000ffe830ec EFLAGS: 00000292 ORIG_RAX: 0000000000000034
RAX: 0000000000000000 RBX: 00000000ffe83190 RCX: 0000000000000002
RDX: 000000000816c000 RSI: 0000000000000000 RDI: 00000000080e9e6a
RBP: 00000000ffe83190 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000

Uninit was created at:
 kmsan_save_stack_with_flags+0x3c/0x90 mm/kmsan/kmsan.c:121
 kmsan_alloc_page+0xd3/0x1f0 mm/kmsan/kmsan_shadow.c:274
 __alloc_pages_nodemask+0x827/0xf90 mm/page_alloc.c:5038
 alloc_pages_current+0x7b6/0xb60 mm/mempolicy.c:2267
 alloc_pages include/linux/gfp.h:547 [inline]
 __page_cache_alloc mm/filemap.c:981 [inline]
 pagecache_get_page+0x1127/0x2070 mm/filemap.c:1841
 find_or_create_page include/linux/pagemap.h:404 [inline]
 alloc_extent_buffer+0x78c/0x28d0 fs/btrfs/extent_io.c:5293
 btrfs_find_create_tree_block+0xb6/0xd0 fs/btrfs/disk-io.c:959
 btrfs_init_new_buffer fs/btrfs/extent-tree.c:4597 [inline]
 btrfs_alloc_tree_block+0x545/0x2100 fs/btrfs/extent-tree.c:4698
 alloc_tree_block_no_bg_flush fs/btrfs/ctree.c:989 [inline]
 __btrfs_cow_block+0xb93/0x2760 fs/btrfs/ctree.c:1045
 btrfs_cow_block+0xa3c/0xc90 fs/btrfs/ctree.c:1490
 btrfs_search_slot+0x1ad5/0x3f20 fs/btrfs/ctree.c:2670
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
=====================================================
=====================================================
BUG: KMSAN: uninit-value in btrfs_comp_cpu_keys fs/btrfs/ctree.c:1546 [inline]
BUG: KMSAN: uninit-value in comp_keys fs/btrfs/ctree.c:1522 [inline]
BUG: KMSAN: uninit-value in generic_bin_search+0x703/0xbc0 fs/btrfs/ctree.c:1696
CPU: 1 PID: 10525 Comm: syz-executor.4 Tainted: G    B             5.11.0-rc7-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 __dump_stack lib/dump_stack.c:79 [inline]
 dump_stack+0x21c/0x280 lib/dump_stack.c:120
 kmsan_report+0xfb/0x1e0 mm/kmsan/kmsan_report.c:118
 __msan_warning+0x5f/0xa0 mm/kmsan/kmsan_instr.c:197
 btrfs_comp_cpu_keys fs/btrfs/ctree.c:1546 [inline]
 comp_keys fs/btrfs/ctree.c:1522 [inline]
 generic_bin_search+0x703/0xbc0 fs/btrfs/ctree.c:1696
 btrfs_bin_search fs/btrfs/ctree.c:1718 [inline]
 btrfs_search_slot+0x2144/0x3f20 fs/btrfs/ctree.c:2718
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x5ec/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
RIP: 0023:0xf7fa6549
Code: 03 74 c0 01 10 05 03 74 b8 01 10 06 03 74 b4 01 10 07 03 74 b0 01 10 08 03 74 d8 01 00 00 00 00 00 51 52 55 89 e5 0f 34 cd 80 <5d> 5a 59 c3 90 90 90 90 8d b4 26 00 00 00 00 8d b4 26 00 00 00 00
RSP: 002b:00000000ffe830ec EFLAGS: 00000292 ORIG_RAX: 0000000000000034
RAX: 0000000000000000 RBX: 00000000ffe83190 RCX: 0000000000000002
RDX: 000000000816c000 RSI: 0000000000000000 RDI: 00000000080e9e6a
RBP: 00000000ffe83190 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 kmsan_memcpy_memmove_metadata+0x25e/0x2d0 mm/kmsan/kmsan.c:226
 kmsan_memmove_metadata+0xe/0x10 mm/kmsan/kmsan.c:251
 __msan_memmove+0x46/0x60 mm/kmsan/kmsan_instr.c:92
 copy_pages fs/btrfs/extent_io.c:6094 [inline]
 memmove_extent_buffer+0x7c3/0xd30 fs/btrfs/extent_io.c:6162
 setup_items_for_insert+0x11d8/0x1a00 fs/btrfs/ctree.c:4734
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was created at:
 kmsan_save_stack_with_flags+0x3c/0x90 mm/kmsan/kmsan.c:121
 kmsan_alloc_page+0xd3/0x1f0 mm/kmsan/kmsan_shadow.c:274
 __alloc_pages_nodemask+0x827/0xf90 mm/page_alloc.c:5038
 alloc_pages_current+0x7b6/0xb60 mm/mempolicy.c:2267
 alloc_pages include/linux/gfp.h:547 [inline]
 __page_cache_alloc mm/filemap.c:981 [inline]
 pagecache_get_page+0x1127/0x2070 mm/filemap.c:1841
 find_or_create_page include/linux/pagemap.h:404 [inline]
 alloc_extent_buffer+0x78c/0x28d0 fs/btrfs/extent_io.c:5293
 btrfs_find_create_tree_block+0xb6/0xd0 fs/btrfs/disk-io.c:959
 btrfs_init_new_buffer fs/btrfs/extent-tree.c:4597 [inline]
 btrfs_alloc_tree_block+0x545/0x2100 fs/btrfs/extent-tree.c:4698
 alloc_tree_block_no_bg_flush fs/btrfs/ctree.c:989 [inline]
 __btrfs_cow_block+0xb93/0x2760 fs/btrfs/ctree.c:1045
 btrfs_cow_block+0xa3c/0xc90 fs/btrfs/ctree.c:1490
 btrfs_search_slot+0x1ad5/0x3f20 fs/btrfs/ctree.c:2670
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
=====================================================
=====================================================
BUG: KMSAN: uninit-value in btrfs_comp_cpu_keys fs/btrfs/ctree.c:1548 [inline]
BUG: KMSAN: uninit-value in comp_keys fs/btrfs/ctree.c:1522 [inline]
BUG: KMSAN: uninit-value in generic_bin_search+0x766/0xbc0 fs/btrfs/ctree.c:1696
CPU: 1 PID: 10525 Comm: syz-executor.4 Tainted: G    B             5.11.0-rc7-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 __dump_stack lib/dump_stack.c:79 [inline]
 dump_stack+0x21c/0x280 lib/dump_stack.c:120
 kmsan_report+0xfb/0x1e0 mm/kmsan/kmsan_report.c:118
 __msan_warning+0x5f/0xa0 mm/kmsan/kmsan_instr.c:197
 btrfs_comp_cpu_keys fs/btrfs/ctree.c:1548 [inline]
 comp_keys fs/btrfs/ctree.c:1522 [inline]
 generic_bin_search+0x766/0xbc0 fs/btrfs/ctree.c:1696
 btrfs_bin_search fs/btrfs/ctree.c:1718 [inline]
 btrfs_search_slot+0x2144/0x3f20 fs/btrfs/ctree.c:2718
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x5ec/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
RIP: 0023:0xf7fa6549
Code: 03 74 c0 01 10 05 03 74 b8 01 10 06 03 74 b4 01 10 07 03 74 b0 01 10 08 03 74 d8 01 00 00 00 00 00 51 52 55 89 e5 0f 34 cd 80 <5d> 5a 59 c3 90 90 90 90 8d b4 26 00 00 00 00 8d b4 26 00 00 00 00
RSP: 002b:00000000ffe830ec EFLAGS: 00000292 ORIG_RAX: 0000000000000034
RAX: 0000000000000000 RBX: 00000000ffe83190 RCX: 0000000000000002
RDX: 000000000816c000 RSI: 0000000000000000 RDI: 00000000080e9e6a
RBP: 00000000ffe83190 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 kmsan_memcpy_memmove_metadata+0x25e/0x2d0 mm/kmsan/kmsan.c:226
 kmsan_memmove_metadata+0xe/0x10 mm/kmsan/kmsan.c:251
 __msan_memmove+0x46/0x60 mm/kmsan/kmsan_instr.c:92
 copy_pages fs/btrfs/extent_io.c:6094 [inline]
 memmove_extent_buffer+0x7c3/0xd30 fs/btrfs/extent_io.c:6162
 setup_items_for_insert+0x11d8/0x1a00 fs/btrfs/ctree.c:4734
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was created at:
 kmsan_save_stack_with_flags+0x3c/0x90 mm/kmsan/kmsan.c:121
 kmsan_alloc_page+0xd3/0x1f0 mm/kmsan/kmsan_shadow.c:274
 __alloc_pages_nodemask+0x827/0xf90 mm/page_alloc.c:5038
 alloc_pages_current+0x7b6/0xb60 mm/mempolicy.c:2267
 alloc_pages include/linux/gfp.h:547 [inline]
 __page_cache_alloc mm/filemap.c:981 [inline]
 pagecache_get_page+0x1127/0x2070 mm/filemap.c:1841
 find_or_create_page include/linux/pagemap.h:404 [inline]
 alloc_extent_buffer+0x78c/0x28d0 fs/btrfs/extent_io.c:5293
 btrfs_find_create_tree_block+0xb6/0xd0 fs/btrfs/disk-io.c:959
 btrfs_init_new_buffer fs/btrfs/extent-tree.c:4597 [inline]
 btrfs_alloc_tree_block+0x545/0x2100 fs/btrfs/extent-tree.c:4698
 alloc_tree_block_no_bg_flush fs/btrfs/ctree.c:989 [inline]
 __btrfs_cow_block+0xb93/0x2760 fs/btrfs/ctree.c:1045
 btrfs_cow_block+0xa3c/0xc90 fs/btrfs/ctree.c:1490
 btrfs_search_slot+0x1ad5/0x3f20 fs/btrfs/ctree.c:2670
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
=====================================================
=====================================================
BUG: KMSAN: uninit-value in leaf_space_used+0x3c0/0x3d0 fs/btrfs/ctree.c:3510
CPU: 1 PID: 10525 Comm: syz-executor.4 Tainted: G    B             5.11.0-rc7-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 __dump_stack lib/dump_stack.c:79 [inline]
 dump_stack+0x21c/0x280 lib/dump_stack.c:120
 kmsan_report+0xfb/0x1e0 mm/kmsan/kmsan_report.c:118
 __msan_warning+0x5f/0xa0 mm/kmsan/kmsan_instr.c:197
 leaf_space_used+0x3c0/0x3d0 fs/btrfs/ctree.c:3510
 btrfs_leaf_free_space+0x16e/0x3d0 fs/btrfs/ctree.c:3525
 btrfs_search_slot+0x3841/0x3f20 fs/btrfs/ctree.c:2741
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x5ec/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
RIP: 0023:0xf7fa6549
Code: 03 74 c0 01 10 05 03 74 b8 01 10 06 03 74 b4 01 10 07 03 74 b0 01 10 08 03 74 d8 01 00 00 00 00 00 51 52 55 89 e5 0f 34 cd 80 <5d> 5a 59 c3 90 90 90 90 8d b4 26 00 00 00 00 8d b4 26 00 00 00 00
RSP: 002b:00000000ffe830ec EFLAGS: 00000292 ORIG_RAX: 0000000000000034
RAX: 0000000000000000 RBX: 00000000ffe83190 RCX: 0000000000000002
RDX: 000000000816c000 RSI: 0000000000000000 RDI: 00000000080e9e6a
RBP: 00000000ffe83190 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 kmsan_memcpy_memmove_metadata+0x25e/0x2d0 mm/kmsan/kmsan.c:226
 kmsan_memmove_metadata+0xe/0x10 mm/kmsan/kmsan.c:251
 __msan_memmove+0x46/0x60 mm/kmsan/kmsan_instr.c:92
 copy_pages fs/btrfs/extent_io.c:6094 [inline]
 memmove_extent_buffer+0x7c3/0xd30 fs/btrfs/extent_io.c:6162
 setup_items_for_insert+0x11d8/0x1a00 fs/btrfs/ctree.c:4734
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 __msan_chain_origin+0x57/0xa0 mm/kmsan/kmsan_instr.c:147
 put_unaligned_le32 include/linux/unaligned/access_ok.h:45 [inline]
 btrfs_set_token_32+0x9a6/0xb40 fs/btrfs/struct-funcs.c:162
 btrfs_set_token_item_offset fs/btrfs/ctree.h:1897 [inline]
 setup_items_for_insert+0x10e9/0x1a00 fs/btrfs/ctree.c:4730
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was created at:
 kmsan_save_stack_with_flags+0x3c/0x90 mm/kmsan/kmsan.c:121
 kmsan_alloc_page+0xd3/0x1f0 mm/kmsan/kmsan_shadow.c:274
 __alloc_pages_nodemask+0x827/0xf90 mm/page_alloc.c:5038
 alloc_pages_current+0x7b6/0xb60 mm/mempolicy.c:2267
 alloc_pages include/linux/gfp.h:547 [inline]
 __page_cache_alloc mm/filemap.c:981 [inline]
 pagecache_get_page+0x1127/0x2070 mm/filemap.c:1841
 find_or_create_page include/linux/pagemap.h:404 [inline]
 alloc_extent_buffer+0x78c/0x28d0 fs/btrfs/extent_io.c:5293
 btrfs_find_create_tree_block+0xb6/0xd0 fs/btrfs/disk-io.c:959
 btrfs_init_new_buffer fs/btrfs/extent-tree.c:4597 [inline]
 btrfs_alloc_tree_block+0x545/0x2100 fs/btrfs/extent-tree.c:4698
 alloc_tree_block_no_bg_flush fs/btrfs/ctree.c:989 [inline]
 __btrfs_cow_block+0xb93/0x2760 fs/btrfs/ctree.c:1045
 btrfs_cow_block+0xa3c/0xc90 fs/btrfs/ctree.c:1490
 btrfs_search_slot+0x1ad5/0x3f20 fs/btrfs/ctree.c:2670
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
=====================================================
=====================================================
BUG: KMSAN: uninit-value in btrfs_leaf_free_space+0x246/0x3d0 fs/btrfs/ctree.c:3526
CPU: 1 PID: 10525 Comm: syz-executor.4 Tainted: G    B             5.11.0-rc7-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 __dump_stack lib/dump_stack.c:79 [inline]
 dump_stack+0x21c/0x280 lib/dump_stack.c:120
 kmsan_report+0xfb/0x1e0 mm/kmsan/kmsan_report.c:118
 __msan_warning+0x5f/0xa0 mm/kmsan/kmsan_instr.c:197
 btrfs_leaf_free_space+0x246/0x3d0 fs/btrfs/ctree.c:3526
 btrfs_search_slot+0x3841/0x3f20 fs/btrfs/ctree.c:2741
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x5ec/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
RIP: 0023:0xf7fa6549
Code: 03 74 c0 01 10 05 03 74 b8 01 10 06 03 74 b4 01 10 07 03 74 b0 01 10 08 03 74 d8 01 00 00 00 00 00 51 52 55 89 e5 0f 34 cd 80 <5d> 5a 59 c3 90 90 90 90 8d b4 26 00 00 00 00 8d b4 26 00 00 00 00
RSP: 002b:00000000ffe830ec EFLAGS: 00000292 ORIG_RAX: 0000000000000034
RAX: 0000000000000000 RBX: 00000000ffe83190 RCX: 0000000000000002
RDX: 000000000816c000 RSI: 0000000000000000 RDI: 00000000080e9e6a
RBP: 00000000ffe83190 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 kmsan_memcpy_memmove_metadata+0x25e/0x2d0 mm/kmsan/kmsan.c:226
 kmsan_memmove_metadata+0xe/0x10 mm/kmsan/kmsan.c:251
 __msan_memmove+0x46/0x60 mm/kmsan/kmsan_instr.c:92
 copy_pages fs/btrfs/extent_io.c:6094 [inline]
 memmove_extent_buffer+0x7c3/0xd30 fs/btrfs/extent_io.c:6162
 setup_items_for_insert+0x11d8/0x1a00 fs/btrfs/ctree.c:4734
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 __msan_chain_origin+0x57/0xa0 mm/kmsan/kmsan_instr.c:147
 put_unaligned_le32 include/linux/unaligned/access_ok.h:45 [inline]
 btrfs_set_token_32+0x9a6/0xb40 fs/btrfs/struct-funcs.c:162
 btrfs_set_token_item_offset fs/btrfs/ctree.h:1897 [inline]
 setup_items_for_insert+0x10e9/0x1a00 fs/btrfs/ctree.c:4730
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was created at:
 kmsan_save_stack_with_flags+0x3c/0x90 mm/kmsan/kmsan.c:121
 kmsan_alloc_page+0xd3/0x1f0 mm/kmsan/kmsan_shadow.c:274
 __alloc_pages_nodemask+0x827/0xf90 mm/page_alloc.c:5038
 alloc_pages_current+0x7b6/0xb60 mm/mempolicy.c:2267
 alloc_pages include/linux/gfp.h:547 [inline]
 __page_cache_alloc mm/filemap.c:981 [inline]
 pagecache_get_page+0x1127/0x2070 mm/filemap.c:1841
 find_or_create_page include/linux/pagemap.h:404 [inline]
 alloc_extent_buffer+0x78c/0x28d0 fs/btrfs/extent_io.c:5293
 btrfs_find_create_tree_block+0xb6/0xd0 fs/btrfs/disk-io.c:959
 btrfs_init_new_buffer fs/btrfs/extent-tree.c:4597 [inline]
 btrfs_alloc_tree_block+0x545/0x2100 fs/btrfs/extent-tree.c:4698
 alloc_tree_block_no_bg_flush fs/btrfs/ctree.c:989 [inline]
 __btrfs_cow_block+0xb93/0x2760 fs/btrfs/ctree.c:1045
 btrfs_cow_block+0xa3c/0xc90 fs/btrfs/ctree.c:1490
 btrfs_search_slot+0x1ad5/0x3f20 fs/btrfs/ctree.c:2670
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
=====================================================
=====================================================
BUG: KMSAN: uninit-value in btrfs_search_slot+0x394f/0x3f20 fs/btrfs/ctree.c:2740
CPU: 1 PID: 10525 Comm: syz-executor.4 Tainted: G    B             5.11.0-rc7-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 __dump_stack lib/dump_stack.c:79 [inline]
 dump_stack+0x21c/0x280 lib/dump_stack.c:120
 kmsan_report+0xfb/0x1e0 mm/kmsan/kmsan_report.c:118
 __msan_warning+0x5f/0xa0 mm/kmsan/kmsan_instr.c:197
 btrfs_search_slot+0x394f/0x3f20 fs/btrfs/ctree.c:2740
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x5ec/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
RIP: 0023:0xf7fa6549
Code: 03 74 c0 01 10 05 03 74 b8 01 10 06 03 74 b4 01 10 07 03 74 b0 01 10 08 03 74 d8 01 00 00 00 00 00 51 52 55 89 e5 0f 34 cd 80 <5d> 5a 59 c3 90 90 90 90 8d b4 26 00 00 00 00 8d b4 26 00 00 00 00
RSP: 002b:00000000ffe830ec EFLAGS: 00000292 ORIG_RAX: 0000000000000034
RAX: 0000000000000000 RBX: 00000000ffe83190 RCX: 0000000000000002
RDX: 000000000816c000 RSI: 0000000000000000 RDI: 00000000080e9e6a
RBP: 00000000ffe83190 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 kmsan_memcpy_memmove_metadata+0x25e/0x2d0 mm/kmsan/kmsan.c:226
 kmsan_memmove_metadata+0xe/0x10 mm/kmsan/kmsan.c:251
 __msan_memmove+0x46/0x60 mm/kmsan/kmsan_instr.c:92
 copy_pages fs/btrfs/extent_io.c:6094 [inline]
 memmove_extent_buffer+0x7c3/0xd30 fs/btrfs/extent_io.c:6162
 setup_items_for_insert+0x11d8/0x1a00 fs/btrfs/ctree.c:4734
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 __msan_chain_origin+0x57/0xa0 mm/kmsan/kmsan_instr.c:147
 put_unaligned_le32 include/linux/unaligned/access_ok.h:45 [inline]
 btrfs_set_token_32+0x9a6/0xb40 fs/btrfs/struct-funcs.c:162
 btrfs_set_token_item_offset fs/btrfs/ctree.h:1897 [inline]
 setup_items_for_insert+0x10e9/0x1a00 fs/btrfs/ctree.c:4730
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was created at:
 kmsan_save_stack_with_flags+0x3c/0x90 mm/kmsan/kmsan.c:121
 kmsan_alloc_page+0xd3/0x1f0 mm/kmsan/kmsan_shadow.c:274
 __alloc_pages_nodemask+0x827/0xf90 mm/page_alloc.c:5038
 alloc_pages_current+0x7b6/0xb60 mm/mempolicy.c:2267
 alloc_pages include/linux/gfp.h:547 [inline]
 __page_cache_alloc mm/filemap.c:981 [inline]
 pagecache_get_page+0x1127/0x2070 mm/filemap.c:1841
 find_or_create_page include/linux/pagemap.h:404 [inline]
 alloc_extent_buffer+0x78c/0x28d0 fs/btrfs/extent_io.c:5293
 btrfs_find_create_tree_block+0xb6/0xd0 fs/btrfs/disk-io.c:959
 btrfs_init_new_buffer fs/btrfs/extent-tree.c:4597 [inline]
 btrfs_alloc_tree_block+0x545/0x2100 fs/btrfs/extent-tree.c:4698
 alloc_tree_block_no_bg_flush fs/btrfs/ctree.c:989 [inline]
 __btrfs_cow_block+0xb93/0x2760 fs/btrfs/ctree.c:1045
 btrfs_cow_block+0xa3c/0xc90 fs/btrfs/ctree.c:1490
 btrfs_search_slot+0x1ad5/0x3f20 fs/btrfs/ctree.c:2670
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
=====================================================
=====================================================
BUG: KMSAN: uninit-value in leaf_space_used+0x3c0/0x3d0 fs/btrfs/ctree.c:3510
CPU: 1 PID: 10525 Comm: syz-executor.4 Tainted: G    B             5.11.0-rc7-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 __dump_stack lib/dump_stack.c:79 [inline]
 dump_stack+0x21c/0x280 lib/dump_stack.c:120
 kmsan_report+0xfb/0x1e0 mm/kmsan/kmsan_report.c:118
 __msan_warning+0x5f/0xa0 mm/kmsan/kmsan_instr.c:197
 leaf_space_used+0x3c0/0x3d0 fs/btrfs/ctree.c:3510
 btrfs_leaf_free_space+0x16e/0x3d0 fs/btrfs/ctree.c:3525
 setup_items_for_insert+0xc47/0x1a00 fs/btrfs/ctree.c:4703
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x5ec/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
RIP: 0023:0xf7fa6549
Code: 03 74 c0 01 10 05 03 74 b8 01 10 06 03 74 b4 01 10 07 03 74 b0 01 10 08 03 74 d8 01 00 00 00 00 00 51 52 55 89 e5 0f 34 cd 80 <5d> 5a 59 c3 90 90 90 90 8d b4 26 00 00 00 00 8d b4 26 00 00 00 00
RSP: 002b:00000000ffe830ec EFLAGS: 00000292 ORIG_RAX: 0000000000000034
RAX: 0000000000000000 RBX: 00000000ffe83190 RCX: 0000000000000002
RDX: 000000000816c000 RSI: 0000000000000000 RDI: 00000000080e9e6a
RBP: 00000000ffe83190 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 kmsan_memcpy_memmove_metadata+0x25e/0x2d0 mm/kmsan/kmsan.c:226
 kmsan_memmove_metadata+0xe/0x10 mm/kmsan/kmsan.c:251
 __msan_memmove+0x46/0x60 mm/kmsan/kmsan_instr.c:92
 copy_pages fs/btrfs/extent_io.c:6094 [inline]
 memmove_extent_buffer+0x7c3/0xd30 fs/btrfs/extent_io.c:6162
 setup_items_for_insert+0x11d8/0x1a00 fs/btrfs/ctree.c:4734
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 __msan_chain_origin+0x57/0xa0 mm/kmsan/kmsan_instr.c:147
 put_unaligned_le32 include/linux/unaligned/access_ok.h:45 [inline]
 btrfs_set_token_32+0x9a6/0xb40 fs/btrfs/struct-funcs.c:162
 btrfs_set_token_item_offset fs/btrfs/ctree.h:1897 [inline]
 setup_items_for_insert+0x10e9/0x1a00 fs/btrfs/ctree.c:4730
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was created at:
 kmsan_save_stack_with_flags+0x3c/0x90 mm/kmsan/kmsan.c:121
 kmsan_alloc_page+0xd3/0x1f0 mm/kmsan/kmsan_shadow.c:274
 __alloc_pages_nodemask+0x827/0xf90 mm/page_alloc.c:5038
 alloc_pages_current+0x7b6/0xb60 mm/mempolicy.c:2267
 alloc_pages include/linux/gfp.h:547 [inline]
 __page_cache_alloc mm/filemap.c:981 [inline]
 pagecache_get_page+0x1127/0x2070 mm/filemap.c:1841
 find_or_create_page include/linux/pagemap.h:404 [inline]
 alloc_extent_buffer+0x78c/0x28d0 fs/btrfs/extent_io.c:5293
 btrfs_find_create_tree_block+0xb6/0xd0 fs/btrfs/disk-io.c:959
 btrfs_init_new_buffer fs/btrfs/extent-tree.c:4597 [inline]
 btrfs_alloc_tree_block+0x545/0x2100 fs/btrfs/extent-tree.c:4698
 alloc_tree_block_no_bg_flush fs/btrfs/ctree.c:989 [inline]
 __btrfs_cow_block+0xb93/0x2760 fs/btrfs/ctree.c:1045
 btrfs_cow_block+0xa3c/0xc90 fs/btrfs/ctree.c:1490
 btrfs_search_slot+0x1ad5/0x3f20 fs/btrfs/ctree.c:2670
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
=====================================================
=====================================================
BUG: KMSAN: uninit-value in btrfs_leaf_free_space+0x246/0x3d0 fs/btrfs/ctree.c:3526
CPU: 1 PID: 10525 Comm: syz-executor.4 Tainted: G    B             5.11.0-rc7-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 __dump_stack lib/dump_stack.c:79 [inline]
 dump_stack+0x21c/0x280 lib/dump_stack.c:120
 kmsan_report+0xfb/0x1e0 mm/kmsan/kmsan_report.c:118
 __msan_warning+0x5f/0xa0 mm/kmsan/kmsan_instr.c:197
 btrfs_leaf_free_space+0x246/0x3d0 fs/btrfs/ctree.c:3526
 setup_items_for_insert+0xc47/0x1a00 fs/btrfs/ctree.c:4703
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x5ec/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
RIP: 0023:0xf7fa6549
Code: 03 74 c0 01 10 05 03 74 b8 01 10 06 03 74 b4 01 10 07 03 74 b0 01 10 08 03 74 d8 01 00 00 00 00 00 51 52 55 89 e5 0f 34 cd 80 <5d> 5a 59 c3 90 90 90 90 8d b4 26 00 00 00 00 8d b4 26 00 00 00 00
RSP: 002b:00000000ffe830ec EFLAGS: 00000292 ORIG_RAX: 0000000000000034
RAX: 0000000000000000 RBX: 00000000ffe83190 RCX: 0000000000000002
RDX: 000000000816c000 RSI: 0000000000000000 RDI: 00000000080e9e6a
RBP: 00000000ffe83190 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 kmsan_memcpy_memmove_metadata+0x25e/0x2d0 mm/kmsan/kmsan.c:226
 kmsan_memmove_metadata+0xe/0x10 mm/kmsan/kmsan.c:251
 __msan_memmove+0x46/0x60 mm/kmsan/kmsan_instr.c:92
 copy_pages fs/btrfs/extent_io.c:6094 [inline]
 memmove_extent_buffer+0x7c3/0xd30 fs/btrfs/extent_io.c:6162
 setup_items_for_insert+0x11d8/0x1a00 fs/btrfs/ctree.c:4734
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 __msan_chain_origin+0x57/0xa0 mm/kmsan/kmsan_instr.c:147
 put_unaligned_le32 include/linux/unaligned/access_ok.h:45 [inline]
 btrfs_set_token_32+0x9a6/0xb40 fs/btrfs/struct-funcs.c:162
 btrfs_set_token_item_offset fs/btrfs/ctree.h:1897 [inline]
 setup_items_for_insert+0x10e9/0x1a00 fs/btrfs/ctree.c:4730
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was created at:
 kmsan_save_stack_with_flags+0x3c/0x90 mm/kmsan/kmsan.c:121
 kmsan_alloc_page+0xd3/0x1f0 mm/kmsan/kmsan_shadow.c:274
 __alloc_pages_nodemask+0x827/0xf90 mm/page_alloc.c:5038
 alloc_pages_current+0x7b6/0xb60 mm/mempolicy.c:2267
 alloc_pages include/linux/gfp.h:547 [inline]
 __page_cache_alloc mm/filemap.c:981 [inline]
 pagecache_get_page+0x1127/0x2070 mm/filemap.c:1841
 find_or_create_page include/linux/pagemap.h:404 [inline]
 alloc_extent_buffer+0x78c/0x28d0 fs/btrfs/extent_io.c:5293
 btrfs_find_create_tree_block+0xb6/0xd0 fs/btrfs/disk-io.c:959
 btrfs_init_new_buffer fs/btrfs/extent-tree.c:4597 [inline]
 btrfs_alloc_tree_block+0x545/0x2100 fs/btrfs/extent-tree.c:4698
 alloc_tree_block_no_bg_flush fs/btrfs/ctree.c:989 [inline]
 __btrfs_cow_block+0xb93/0x2760 fs/btrfs/ctree.c:1045
 btrfs_cow_block+0xa3c/0xc90 fs/btrfs/ctree.c:1490
 btrfs_search_slot+0x1ad5/0x3f20 fs/btrfs/ctree.c:2670
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
=====================================================
=====================================================
BUG: KMSAN: uninit-value in setup_items_for_insert+0x15a8/0x1a00 fs/btrfs/ctree.c:4703
CPU: 1 PID: 10525 Comm: syz-executor.4 Tainted: G    B             5.11.0-rc7-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 __dump_stack lib/dump_stack.c:79 [inline]
 dump_stack+0x21c/0x280 lib/dump_stack.c:120
 kmsan_report+0xfb/0x1e0 mm/kmsan/kmsan_report.c:118
 __msan_warning+0x5f/0xa0 mm/kmsan/kmsan_instr.c:197
 setup_items_for_insert+0x15a8/0x1a00 fs/btrfs/ctree.c:4703
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x5ec/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
RIP: 0023:0xf7fa6549
Code: 03 74 c0 01 10 05 03 74 b8 01 10 06 03 74 b4 01 10 07 03 74 b0 01 10 08 03 74 d8 01 00 00 00 00 00 51 52 55 89 e5 0f 34 cd 80 <5d> 5a 59 c3 90 90 90 90 8d b4 26 00 00 00 00 8d b4 26 00 00 00 00
RSP: 002b:00000000ffe830ec EFLAGS: 00000292 ORIG_RAX: 0000000000000034
RAX: 0000000000000000 RBX: 00000000ffe83190 RCX: 0000000000000002
RDX: 000000000816c000 RSI: 0000000000000000 RDI: 00000000080e9e6a
RBP: 00000000ffe83190 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 kmsan_memcpy_memmove_metadata+0x25e/0x2d0 mm/kmsan/kmsan.c:226
 kmsan_memmove_metadata+0xe/0x10 mm/kmsan/kmsan.c:251
 __msan_memmove+0x46/0x60 mm/kmsan/kmsan_instr.c:92
 copy_pages fs/btrfs/extent_io.c:6094 [inline]
 memmove_extent_buffer+0x7c3/0xd30 fs/btrfs/extent_io.c:6162
 setup_items_for_insert+0x11d8/0x1a00 fs/btrfs/ctree.c:4734
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 __msan_chain_origin+0x57/0xa0 mm/kmsan/kmsan_instr.c:147
 put_unaligned_le32 include/linux/unaligned/access_ok.h:45 [inline]
 btrfs_set_token_32+0x9a6/0xb40 fs/btrfs/struct-funcs.c:162
 btrfs_set_token_item_offset fs/btrfs/ctree.h:1897 [inline]
 setup_items_for_insert+0x10e9/0x1a00 fs/btrfs/ctree.c:4730
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was created at:
 kmsan_save_stack_with_flags+0x3c/0x90 mm/kmsan/kmsan.c:121
 kmsan_alloc_page+0xd3/0x1f0 mm/kmsan/kmsan_shadow.c:274
 __alloc_pages_nodemask+0x827/0xf90 mm/page_alloc.c:5038
 alloc_pages_current+0x7b6/0xb60 mm/mempolicy.c:2267
 alloc_pages include/linux/gfp.h:547 [inline]
 __page_cache_alloc mm/filemap.c:981 [inline]
 pagecache_get_page+0x1127/0x2070 mm/filemap.c:1841
 find_or_create_page include/linux/pagemap.h:404 [inline]
 alloc_extent_buffer+0x78c/0x28d0 fs/btrfs/extent_io.c:5293
 btrfs_find_create_tree_block+0xb6/0xd0 fs/btrfs/disk-io.c:959
 btrfs_init_new_buffer fs/btrfs/extent-tree.c:4597 [inline]
 btrfs_alloc_tree_block+0x545/0x2100 fs/btrfs/extent-tree.c:4698
 alloc_tree_block_no_bg_flush fs/btrfs/ctree.c:989 [inline]
 __btrfs_cow_block+0xb93/0x2760 fs/btrfs/ctree.c:1045
 btrfs_cow_block+0xa3c/0xc90 fs/btrfs/ctree.c:1490
 btrfs_search_slot+0x1ad5/0x3f20 fs/btrfs/ctree.c:2670
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
=====================================================
=====================================================
BUG: KMSAN: uninit-value in setup_items_for_insert+0x18eb/0x1a00 fs/btrfs/ctree.c:4714
CPU: 1 PID: 10525 Comm: syz-executor.4 Tainted: G    B             5.11.0-rc7-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 __dump_stack lib/dump_stack.c:79 [inline]
 dump_stack+0x21c/0x280 lib/dump_stack.c:120
 kmsan_report+0xfb/0x1e0 mm/kmsan/kmsan_report.c:118
 __msan_warning+0x5f/0xa0 mm/kmsan/kmsan_instr.c:197
 setup_items_for_insert+0x18eb/0x1a00 fs/btrfs/ctree.c:4714
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x5ec/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
RIP: 0023:0xf7fa6549
Code: 03 74 c0 01 10 05 03 74 b8 01 10 06 03 74 b4 01 10 07 03 74 b0 01 10 08 03 74 d8 01 00 00 00 00 00 51 52 55 89 e5 0f 34 cd 80 <5d> 5a 59 c3 90 90 90 90 8d b4 26 00 00 00 00 8d b4 26 00 00 00 00
RSP: 002b:00000000ffe830ec EFLAGS: 00000292 ORIG_RAX: 0000000000000034
RAX: 0000000000000000 RBX: 00000000ffe83190 RCX: 0000000000000002
RDX: 000000000816c000 RSI: 0000000000000000 RDI: 00000000080e9e6a
RBP: 00000000ffe83190 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 kmsan_memcpy_memmove_metadata+0x25e/0x2d0 mm/kmsan/kmsan.c:226
 kmsan_memmove_metadata+0xe/0x10 mm/kmsan/kmsan.c:251
 __msan_memmove+0x46/0x60 mm/kmsan/kmsan_instr.c:92
 copy_pages fs/btrfs/extent_io.c:6094 [inline]
 memmove_extent_buffer+0x7c3/0xd30 fs/btrfs/extent_io.c:6162
 setup_items_for_insert+0x11d8/0x1a00 fs/btrfs/ctree.c:4734
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 __msan_chain_origin+0x57/0xa0 mm/kmsan/kmsan_instr.c:147
 put_unaligned_le32 include/linux/unaligned/access_ok.h:45 [inline]
 btrfs_set_token_32+0x9a6/0xb40 fs/btrfs/struct-funcs.c:162
 btrfs_set_token_item_offset fs/btrfs/ctree.h:1897 [inline]
 setup_items_for_insert+0x10e9/0x1a00 fs/btrfs/ctree.c:4730
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was created at:
 kmsan_save_stack_with_flags+0x3c/0x90 mm/kmsan/kmsan.c:121
 kmsan_alloc_page+0xd3/0x1f0 mm/kmsan/kmsan_shadow.c:274
 __alloc_pages_nodemask+0x827/0xf90 mm/page_alloc.c:5038
 alloc_pages_current+0x7b6/0xb60 mm/mempolicy.c:2267
 alloc_pages include/linux/gfp.h:547 [inline]
 __page_cache_alloc mm/filemap.c:981 [inline]
 pagecache_get_page+0x1127/0x2070 mm/filemap.c:1841
 find_or_create_page include/linux/pagemap.h:404 [inline]
 alloc_extent_buffer+0x78c/0x28d0 fs/btrfs/extent_io.c:5293
 btrfs_find_create_tree_block+0xb6/0xd0 fs/btrfs/disk-io.c:959
 btrfs_init_new_buffer fs/btrfs/extent-tree.c:4597 [inline]
 btrfs_alloc_tree_block+0x545/0x2100 fs/btrfs/extent-tree.c:4698
 alloc_tree_block_no_bg_flush fs/btrfs/ctree.c:989 [inline]
 __btrfs_cow_block+0xb93/0x2760 fs/btrfs/ctree.c:1045
 btrfs_cow_block+0xa3c/0xc90 fs/btrfs/ctree.c:1490
 btrfs_search_slot+0x1ad5/0x3f20 fs/btrfs/ctree.c:2670
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
=====================================================
=====================================================
BUG: KMSAN: uninit-value in check_eb_range fs/btrfs/extent_io.c:5690 [inline]
BUG: KMSAN: uninit-value in memmove_extent_buffer+0x996/0xd30 fs/btrfs/extent_io.c:6146
CPU: 1 PID: 10525 Comm: syz-executor.4 Tainted: G    B             5.11.0-rc7-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 __dump_stack lib/dump_stack.c:79 [inline]
 dump_stack+0x21c/0x280 lib/dump_stack.c:120
 kmsan_report+0xfb/0x1e0 mm/kmsan/kmsan_report.c:118
 __msan_warning+0x5f/0xa0 mm/kmsan/kmsan_instr.c:197
 check_eb_range fs/btrfs/extent_io.c:5690 [inline]
 memmove_extent_buffer+0x996/0xd30 fs/btrfs/extent_io.c:6146
 setup_items_for_insert+0x1258/0x1a00 fs/btrfs/ctree.c:4739
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x5ec/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
RIP: 0023:0xf7fa6549
Code: 03 74 c0 01 10 05 03 74 b8 01 10 06 03 74 b4 01 10 07 03 74 b0 01 10 08 03 74 d8 01 00 00 00 00 00 51 52 55 89 e5 0f 34 cd 80 <5d> 5a 59 c3 90 90 90 90 8d b4 26 00 00 00 00 8d b4 26 00 00 00 00
RSP: 002b:00000000ffe830ec EFLAGS: 00000292 ORIG_RAX: 0000000000000034
RAX: 0000000000000000 RBX: 00000000ffe83190 RCX: 0000000000000002
RDX: 000000000816c000 RSI: 0000000000000000 RDI: 00000000080e9e6a
RBP: 00000000ffe83190 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 kmsan_memcpy_memmove_metadata+0x25e/0x2d0 mm/kmsan/kmsan.c:226
 kmsan_memmove_metadata+0xe/0x10 mm/kmsan/kmsan.c:251
 __msan_memmove+0x46/0x60 mm/kmsan/kmsan_instr.c:92
 copy_pages fs/btrfs/extent_io.c:6094 [inline]
 memmove_extent_buffer+0x7c3/0xd30 fs/btrfs/extent_io.c:6162
 setup_items_for_insert+0x11d8/0x1a00 fs/btrfs/ctree.c:4734
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 __msan_chain_origin+0x57/0xa0 mm/kmsan/kmsan_instr.c:147
 put_unaligned_le32 include/linux/unaligned/access_ok.h:45 [inline]
 btrfs_set_token_32+0x9a6/0xb40 fs/btrfs/struct-funcs.c:162
 btrfs_set_token_item_offset fs/btrfs/ctree.h:1897 [inline]
 setup_items_for_insert+0x10e9/0x1a00 fs/btrfs/ctree.c:4730
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was created at:
 kmsan_save_stack_with_flags+0x3c/0x90 mm/kmsan/kmsan.c:121
 kmsan_alloc_page+0xd3/0x1f0 mm/kmsan/kmsan_shadow.c:274
 __alloc_pages_nodemask+0x827/0xf90 mm/page_alloc.c:5038
 alloc_pages_current+0x7b6/0xb60 mm/mempolicy.c:2267
 alloc_pages include/linux/gfp.h:547 [inline]
 __page_cache_alloc mm/filemap.c:981 [inline]
 pagecache_get_page+0x1127/0x2070 mm/filemap.c:1841
 find_or_create_page include/linux/pagemap.h:404 [inline]
 alloc_extent_buffer+0x78c/0x28d0 fs/btrfs/extent_io.c:5293
 btrfs_find_create_tree_block+0xb6/0xd0 fs/btrfs/disk-io.c:959
 btrfs_init_new_buffer fs/btrfs/extent-tree.c:4597 [inline]
 btrfs_alloc_tree_block+0x545/0x2100 fs/btrfs/extent-tree.c:4698
 alloc_tree_block_no_bg_flush fs/btrfs/ctree.c:989 [inline]
 __btrfs_cow_block+0xb93/0x2760 fs/btrfs/ctree.c:1045
 btrfs_cow_block+0xa3c/0xc90 fs/btrfs/ctree.c:1490
 btrfs_search_slot+0x1ad5/0x3f20 fs/btrfs/ctree.c:2670
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
=====================================================
=====================================================
BUG: KMSAN: uninit-value in check_eb_range fs/btrfs/extent_io.c:5690 [inline]
BUG: KMSAN: uninit-value in memmove_extent_buffer+0x9a2/0xd30 fs/btrfs/extent_io.c:6146
CPU: 1 PID: 10525 Comm: syz-executor.4 Tainted: G    B             5.11.0-rc7-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 __dump_stack lib/dump_stack.c:79 [inline]
 dump_stack+0x21c/0x280 lib/dump_stack.c:120
 kmsan_report+0xfb/0x1e0 mm/kmsan/kmsan_report.c:118
 __msan_warning+0x5f/0xa0 mm/kmsan/kmsan_instr.c:197
 check_eb_range fs/btrfs/extent_io.c:5690 [inline]
 memmove_extent_buffer+0x9a2/0xd30 fs/btrfs/extent_io.c:6146
 setup_items_for_insert+0x1258/0x1a00 fs/btrfs/ctree.c:4739
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x5ec/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
RIP: 0023:0xf7fa6549
Code: 03 74 c0 01 10 05 03 74 b8 01 10 06 03 74 b4 01 10 07 03 74 b0 01 10 08 03 74 d8 01 00 00 00 00 00 51 52 55 89 e5 0f 34 cd 80 <5d> 5a 59 c3 90 90 90 90 8d b4 26 00 00 00 00 8d b4 26 00 00 00 00
RSP: 002b:00000000ffe830ec EFLAGS: 00000292 ORIG_RAX: 0000000000000034
RAX: 0000000000000000 RBX: 00000000ffe83190 RCX: 0000000000000002
RDX: 000000000816c000 RSI: 0000000000000000 RDI: 00000000080e9e6a
RBP: 00000000ffe83190 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 kmsan_memcpy_memmove_metadata+0x25e/0x2d0 mm/kmsan/kmsan.c:226
 kmsan_memmove_metadata+0xe/0x10 mm/kmsan/kmsan.c:251
 __msan_memmove+0x46/0x60 mm/kmsan/kmsan_instr.c:92
 copy_pages fs/btrfs/extent_io.c:6094 [inline]
 memmove_extent_buffer+0x7c3/0xd30 fs/btrfs/extent_io.c:6162
 setup_items_for_insert+0x11d8/0x1a00 fs/btrfs/ctree.c:4734
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 __msan_chain_origin+0x57/0xa0 mm/kmsan/kmsan_instr.c:147
 put_unaligned_le32 include/linux/unaligned/access_ok.h:45 [inline]
 btrfs_set_token_32+0x9a6/0xb40 fs/btrfs/struct-funcs.c:162
 btrfs_set_token_item_offset fs/btrfs/ctree.h:1897 [inline]
 setup_items_for_insert+0x10e9/0x1a00 fs/btrfs/ctree.c:4730
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c

Uninit was created at:
 kmsan_save_stack_with_flags+0x3c/0x90 mm/kmsan/kmsan.c:121
 kmsan_alloc_page+0xd3/0x1f0 mm/kmsan/kmsan_shadow.c:274
 __alloc_pages_nodemask+0x827/0xf90 mm/page_alloc.c:5038
 alloc_pages_current+0x7b6/0xb60 mm/mempolicy.c:2267
 alloc_pages include/linux/gfp.h:547 [inline]
 __page_cache_alloc mm/filemap.c:981 [inline]
 pagecache_get_page+0x1127/0x2070 mm/filemap.c:1841
 find_or_create_page include/linux/pagemap.h:404 [inline]
 alloc_extent_buffer+0x78c/0x28d0 fs/btrfs/extent_io.c:5293
 btrfs_find_create_tree_block+0xb6/0xd0 fs/btrfs/disk-io.c:959
 btrfs_init_new_buffer fs/btrfs/extent-tree.c:4597 [inline]
 btrfs_alloc_tree_block+0x545/0x2100 fs/btrfs/extent-tree.c:4698
 alloc_tree_block_no_bg_flush fs/btrfs/ctree.c:989 [inline]
 __btrfs_cow_block+0xb93/0x2760 fs/btrfs/ctree.c:1045
 btrfs_cow_block+0xa3c/0xc90 fs/btrfs/ctree.c:1490
 btrfs_search_slot+0x1ad5/0x3f20 fs/btrfs/ctree.c:2670
 btrfs_insert_empty_items+0x5a7/0x790 fs/btrfs/ctree.c:4784
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x2d6/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
=====================================================
=====================================================
BUG: KMSAN: uninit-value in check_eb_range fs/btrfs/extent_io.c:5690 [inline]
BUG: KMSAN: uninit-value in memmove_extent_buffer+0x9ca/0xd30 fs/btrfs/extent_io.c:6147
CPU: 1 PID: 10525 Comm: syz-executor.4 Tainted: G    B             5.11.0-rc7-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 __dump_stack lib/dump_stack.c:79 [inline]
 dump_stack+0x21c/0x280 lib/dump_stack.c:120
 kmsan_report+0xfb/0x1e0 mm/kmsan/kmsan_report.c:118
 __msan_warning+0x5f/0xa0 mm/kmsan/kmsan_instr.c:197
 check_eb_range fs/btrfs/extent_io.c:5690 [inline]
 memmove_extent_buffer+0x9ca/0xd30 fs/btrfs/extent_io.c:6147
 setup_items_for_insert+0x1258/0x1a00 fs/btrfs/ctree.c:4739
 btrfs_insert_empty_items+0x6f9/0x790 fs/btrfs/ctree.c:4793
 btrfs_insert_empty_item fs/btrfs/ctree.h:2856 [inline]
 alloc_reserved_tree_block+0x41a/0xfe0 fs/btrfs/extent-tree.c:4469
 run_delayed_tree_ref+0x3ea/0xa30 fs/btrfs/extent-tree.c:1684
 run_one_delayed_ref fs/btrfs/extent-tree.c:1713 [inline]
 btrfs_run_delayed_refs_for_head fs/btrfs/extent-tree.c:1973 [inline]
 __btrfs_run_delayed_refs+0xf48/0x2c10 fs/btrfs/extent-tree.c:2038
 btrfs_run_delayed_refs+0x5ec/0x920 fs/btrfs/extent-tree.c:2169
 commit_cowonly_roots+0x2ff/0x1620 fs/btrfs/transaction.c:1233
 btrfs_commit_transaction+0x204c/0x55b0 fs/btrfs/transaction.c:2275
 btrfs_commit_super+0x1b7/0x1f0 fs/btrfs/disk-io.c:4076
 close_ctree+0x473/0xef7 fs/btrfs/disk-io.c:4140
 btrfs_put_super+0x53/0x70 fs/btrfs/super.c:326
 generic_shutdown_super+0x2ab/0x650 fs/super.c:464
 kill_anon_super+0x63/0xb0 fs/super.c:1055
 btrfs_kill_super+0x61/0x90 fs/btrfs/super.c:2347
 deactivate_locked_super+0x10d/0x1e0 fs/super.c:335
 deactivate_super+0x1b7/0x1d0 fs/super.c:366
 cleanup_mnt+0x7a0/0x870 fs/namespace.c:1118
 __cleanup_mnt+0x3b/0x50 fs/namespace.c:1125
 task_work_run+0x140/0x280 kernel/task_work.c:140
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:174 [inline]
 exit_to_user_mode_prepare+0x486/0x560 kernel/entry/common.c:201
 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline]
 syscall_exit_to_user_mode+0x35/0x60 kernel/entry/common.c:294
 __do_fast_syscall_32+0x12d/0x160 arch/x86/entry/common.c:79
 do_fast_syscall_32+0x6a/0xc0 arch/x86/entry/common.c:166
 do_SYSENTER_32+0x73/0x90 arch/x86/entry/common.c:209
 entry_SYSENTER_compat_after_hwframe+0x4d/0x5c
RIP: 0023:0xf7fa6549
Code: 03 74 c0 01 10 05 03 74 b8 01 10 06 03 74 b4 01 10 07 03 74 b0 01 10 08 03 74 d8 01 00 00 00 00 00 51 52 55 89 e5 0f 34 cd 80 <5d> 5a 59 c3 90 90 90 90 8d b4 26 00 00 00 00 8d b4 26 00 00 00 00
RSP: 002b:00000000ffe830ec EFLAGS: 00000292 ORIG_RAX: 0000000000000034
RAX: 0000000000000000 RBX: 00000000ffe83190 RCX: 0000000000000002
RDX: 000000000816c000 RSI: 0000000000000000 RDI: 00000000080e9e6a
RBP: 00000000ffe83190 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000

Uninit was stored to memory at:
 kmsan_save_stack_with_flags mm/kmsan/kmsan.c:121 [inline]
 kmsan_internal_chain_origin+0xad/0x130 mm/kmsan/kmsan.c:289
 kmsan_memcpy_memmove_metadata+0x25e/0x2d0 mm/kmsan/kmsan.c:226
 kmsan_memmove_metadata+0xe/0x10 mm/kmsan/kmsan.c:251
 __msan_memmove+0x46/0x60 mm/kmsan/kmsan_instr.c:92
 copy_pages fs/btrfs/extent_io.c:6094 [inline]
 memmove_extent_buffer+0x7c3/0xd30 fs/btrfs/extent_io.c:6162
 setup_items_for_insert+0x11d8/0x1a00 fs/btrfs/ctree.c:4734

Crashes (1):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets Title
ci-upstream-kmsan-gce-386 2021/03/23 17:36 https://github.com/google/kmsan.git master 29ad81a1074a e613994b .config console log report info KMSAN: uninit-value in generic_bin_search
* Struck through repros no longer work on HEAD.