ci starts bisection 2022-12-01 09:27:51.730315833 +0000 UTC m=+87389.525844600 bisecting cause commit starting from 49c13ed0316d55d73f1c81c66a7e2abd743f9ae6 building syzkaller on e2556bc3d5922d083190922a5f66f1db91687492 ensuring issue is reproducible on original commit 49c13ed0316d55d73f1c81c66a7e2abd743f9ae6 testing commit 49c13ed0316d55d73f1c81c66a7e2abd743f9ae6 gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: cdba33e540a08011ab0ec91d6c850d80664d056ad4e82b6947a00af9e0aba0a7 all runs: crashed: kernel BUG in btrfs_global_root_insert testing release v5.19 testing commit 3d7cb6b04c3f3115719235cc6866b10326de34cd gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: 53c139778a299323cca52a19212fbb88d51d3f2a86ae9072f147cf79b334d37f all runs: crashed: kernel BUG in btrfs_global_root_insert testing release v5.18 testing commit 4b0986a3613c92f4ec1bdc7f60ec66fea135991f gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: 59086c38872cd763c9844cc4d338fee043e616713b42847362e62717fd3006a9 all runs: crashed: kernel BUG in btrfs_global_root_insert testing release v5.17 testing commit f443e374ae131c168a065ea1748feac6b2e76613 gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: f1cf7a09b5404223ccfdbc13fcf01049dac7360fd937ea1319ece3fe9ad6b8c7 all runs: crashed: kernel BUG in btrfs_global_root_insert testing release v5.16 testing commit df0cc57e057f18e44dac8e6c18aba47ab53202f9 gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: 5dec6dc830384e0787962d7c3bede03ff045ec051a65f47ba287ef2d184fbf9f all runs: OK # git bisect start f443e374ae131c168a065ea1748feac6b2e76613 df0cc57e057f18e44dac8e6c18aba47ab53202f9 Bisecting: 6995 revisions left to test after this (roughly 13 steps) [22ef12195e13c5ec58320dbf99ef85059a2c0820] Merge tag 'staging-5.17-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging testing commit 22ef12195e13c5ec58320dbf99ef85059a2c0820 gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: 799ba20e6f1adc8db3b9d48817ad65cb7e80204874da93009d5d227f848f0f5e all runs: crashed: kernel BUG in btrfs_global_root_insert # git bisect bad 22ef12195e13c5ec58320dbf99ef85059a2c0820 Bisecting: 4385 revisions left to test after this (roughly 12 steps) [9bcbf894b6872216ef61faf17248ec234e3db6bc] Merge tag 'media/v5.17-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media testing commit 9bcbf894b6872216ef61faf17248ec234e3db6bc gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: e1855a21498deaef1dbcb2281a77a0cc14348dc0d6e9a6fc0c883a18972a3912 all runs: OK # git bisect good 9bcbf894b6872216ef61faf17248ec234e3db6bc Bisecting: 2194 revisions left to test after this (roughly 11 steps) [208dd45d8d050360b46ded439a057bcc7cbf3b09] tcp: tcp_send_challenge_ack delete useless param `skb` testing commit 208dd45d8d050360b46ded439a057bcc7cbf3b09 gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: 0e1a9db98d7e6e176550a06d047fff7f301805d21ec3aa634854eef2694d45a4 all runs: OK # git bisect good 208dd45d8d050360b46ded439a057bcc7cbf3b09 Bisecting: 1094 revisions left to test after this (roughly 10 steps) [c288ea679840de4dee2ce6da5d0f139e3774ad86] Merge tag 'gpio-updates-for-v5.17' of git://git.kernel.org/pub/scm/linux/kernel/git/brgl/linux testing commit c288ea679840de4dee2ce6da5d0f139e3774ad86 gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: b5581db7c4c6515f6bf27c0b20bcc253453869e7e308848b459d208fb52edc9e failed: failed to create VM pool: failed to create GCE image: create image operation failed: &{Code:PERMISSIONS_ERROR ErrorDetails:[] Location: Message:Required 'read' permission for 'disks/ci-upstream-kasan-gce-root-bisect-job-bisect-job-image.tar.gz' ForceSendFields:[] NullFields:[]}. # git bisect skip c288ea679840de4dee2ce6da5d0f139e3774ad86 Bisecting: 1094 revisions left to test after this (roughly 10 steps) [af8fefd7444480bb8fd8d74f977dbac4693ac3ed] Merge branches 'acpi-x86', 'acpi-pmic' and 'acpi-dptf' testing commit af8fefd7444480bb8fd8d74f977dbac4693ac3ed gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: d0d42f3cac1a4b9e62b5ca3099cc1ee452051fc29253862273ed377813d9835a all runs: OK # git bisect good af8fefd7444480bb8fd8d74f977dbac4693ac3ed Bisecting: 1067 revisions left to test after this (roughly 10 steps) [a135ce4400bb87f229ab33a663987327d9e0b2a0] Merge tag 'selinux-pr-20220110' of git://git.kernel.org/pub/scm/linux/kernel/git/pcmoore/selinux testing commit a135ce4400bb87f229ab33a663987327d9e0b2a0 gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: 389d8c6337d3e0edf65e6cc4ae6496bbc4de3143c88746f9817b2bd9b76edf11 all runs: OK # git bisect good a135ce4400bb87f229ab33a663987327d9e0b2a0 Bisecting: 506 revisions left to test after this (roughly 9 steps) [d3c810803576d867265277df8e94eee386351c9d] Merge tag 'for-5.17/block-2022-01-11' of git://git.kernel.dk/linux-block testing commit d3c810803576d867265277df8e94eee386351c9d gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: 082084ffa94459386d7f937704acec010f61a23cdbe4d740373a1c78aa06f8be failed: failed to create VM pool: failed to create GCE image: create image operation failed: &{Code:PERMISSIONS_ERROR ErrorDetails:[] Location: Message:Required 'read' permission for 'disks/ci-upstream-kasan-gce-root-bisect-job-bisect-job-image.tar.gz' ForceSendFields:[] NullFields:[]}. # git bisect skip d3c810803576d867265277df8e94eee386351c9d Bisecting: 506 revisions left to test after this (roughly 9 steps) [22f92b77479a1f869663cb6a09fb522e296ab242] staging: r8188eu: move xmit status check from hal to rtw_cmd testing commit 22f92b77479a1f869663cb6a09fb522e296ab242 gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: b5ca1a8927ad45b47a6052bb018d2cd0ebcdd19592b84e4b47153e0ed1d2d918 all runs: OK # git bisect good 22f92b77479a1f869663cb6a09fb522e296ab242 Bisecting: 478 revisions left to test after this (roughly 9 steps) [42a7b4ed45e7667836fae4fb0e1ac6340588b1b0] Merge tag 'for-5.17/io_uring-2022-01-11' of git://git.kernel.dk/linux-block testing commit 42a7b4ed45e7667836fae4fb0e1ac6340588b1b0 gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: ef0edd1e43daf24ec509c4d441e29c4f547ed96074eae5106272b0699842f73f all runs: crashed: kernel BUG in btrfs_global_root_insert # git bisect bad 42a7b4ed45e7667836fae4fb0e1ac6340588b1b0 Bisecting: 207 revisions left to test after this (roughly 8 steps) [1dbfae0113f1423b42c304989a3cc8a7dd0ea53e] Merge tag 'ext4_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4 testing commit 1dbfae0113f1423b42c304989a3cc8a7dd0ea53e gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: c5c3934a8f61b53d61744138c8e5c9992cec6d36e8705b1cf8cb4b7ba19acee4 all runs: crashed: kernel BUG in btrfs_global_root_insert # git bisect bad 1dbfae0113f1423b42c304989a3cc8a7dd0ea53e Bisecting: 109 revisions left to test after this (roughly 7 steps) [2ae8ae3d3def4c3ba73a58cc2531c42f0916f14e] btrfs: scrub: cleanup the argument list of scrub_stripe() testing commit 2ae8ae3d3def4c3ba73a58cc2531c42f0916f14e gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: 9853d0b48dba98c6fc9e33e3b7fe0bf00db972c3a4a17d119b6cab9970281c07 all runs: crashed: kernel BUG in btrfs_global_root_insert # git bisect bad 2ae8ae3d3def4c3ba73a58cc2531c42f0916f14e Bisecting: 54 revisions left to test after this (roughly 6 steps) [fc28b25e1f428651133326300d9572b42aae6d8f] btrfs: stop accessing ->csum_root directly testing commit fc28b25e1f428651133326300d9572b42aae6d8f gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: f9f9946baf6bf4fdb27ae817df4153eb7c1d24bff8108936367cced48e397acd all runs: OK # git bisect good fc28b25e1f428651133326300d9572b42aae6d8f Bisecting: 27 revisions left to test after this (roughly 5 steps) [462b728ea83fa85f1c0d2b79efb6187745444ce5] btrfs: only call inode_sub_bytes in truncate paths that care testing commit 462b728ea83fa85f1c0d2b79efb6187745444ce5 gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: 6a77fa16e0d70ab967ebc1e467720d7ebb7f055a0d7b7fe1a1b36c0d63968c76 all runs: crashed: kernel BUG in btrfs_global_root_insert # git bisect bad 462b728ea83fa85f1c0d2b79efb6187745444ce5 Bisecting: 12 revisions left to test after this (roughly 4 steps) [e2e58d0f8dc55533c24fc7b3e101092f571b4a43] btrfs: try to unlock parent nodes earlier when inserting a key testing commit e2e58d0f8dc55533c24fc7b3e101092f571b4a43 gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: 9f632ee457e6670bed586c2fa3b2a8854629946ad38a80cbaf2a91976e2cc1a3 all runs: crashed: kernel BUG in btrfs_global_root_insert # git bisect bad e2e58d0f8dc55533c24fc7b3e101092f571b4a43 Bisecting: 6 revisions left to test after this (roughly 3 steps) [364be8421192d11ff2aa2973f00efc7cf3b01f52] btrfs: change name and type of private member of btrfs_free_space_ctl testing commit 364be8421192d11ff2aa2973f00efc7cf3b01f52 gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: 0886119fbabfbc069edcb47304ce63168ae30f9be932d86300470bbc1e5351b5 all runs: crashed: kernel BUG in btrfs_global_root_insert # git bisect bad 364be8421192d11ff2aa2973f00efc7cf3b01f52 Bisecting: 3 revisions left to test after this (roughly 2 steps) [abed4aaae4f71a7bcdbe90a65319b6e772a2689d] btrfs: track the csum, extent, and free space trees in a rb tree testing commit abed4aaae4f71a7bcdbe90a65319b6e772a2689d gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: eab1b5e86f64b5870e2a32efa99cdbf915ba5fa95ab5ec06489540e3f875779a all runs: crashed: kernel BUG in btrfs_global_root_insert # git bisect bad abed4aaae4f71a7bcdbe90a65319b6e772a2689d Bisecting: 1 revision left to test after this (roughly 1 step) [7939dd9f35f6f76f5ee199851bcb4d89cd7be061] btrfs: stop accessing ->free_space_root directly testing commit 7939dd9f35f6f76f5ee199851bcb4d89cd7be061 gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: c6324d7c672992387805baa95ad94f9d8f793a91a480f289172f35276de115e0 all runs: OK # git bisect good 7939dd9f35f6f76f5ee199851bcb4d89cd7be061 Bisecting: 0 revisions left to test after this (roughly 0 steps) [7fcf8a0050df003776d10602c9c52b57212f3345] btrfs: remove useless WARN_ON in record_root_in_trans testing commit 7fcf8a0050df003776d10602c9c52b57212f3345 gcc compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: 82ab99c46f351ec6a04f0effd3175f62e60e5b39f0093d5952a3d4ac744b0882 all runs: OK # git bisect good 7fcf8a0050df003776d10602c9c52b57212f3345 abed4aaae4f71a7bcdbe90a65319b6e772a2689d is the first bad commit commit abed4aaae4f71a7bcdbe90a65319b6e772a2689d Author: Josef Bacik Date: Fri Nov 5 16:45:51 2021 -0400 btrfs: track the csum, extent, and free space trees in a rb tree In the future we are going to have multiple copies of these trees. To facilitate this we need a way to lookup the different roots we are looking for. Handle this by adding a global root rb tree that is indexed on the root->root_key. Then instead of loading the roots at mount time with individually targeted keys, simply search the tree_root for anything with the specific objectid we want. This will make it straightforward to support both old style and new style file systems. Signed-off-by: Josef Bacik Reviewed-by: David Sterba Signed-off-by: David Sterba fs/btrfs/ctree.h | 9 +- fs/btrfs/disk-io.c | 276 ++++++++++++++++++++++++++------- fs/btrfs/disk-io.h | 18 +-- fs/btrfs/extent-tree.c | 1 + fs/btrfs/free-space-tree.c | 23 ++- fs/btrfs/tests/btrfs-tests.c | 1 + fs/btrfs/tests/free-space-tests.c | 5 +- fs/btrfs/tests/free-space-tree-tests.c | 5 +- fs/btrfs/tests/qgroup-tests.c | 5 +- 9 files changed, 263 insertions(+), 80 deletions(-) culprit signature: eab1b5e86f64b5870e2a32efa99cdbf915ba5fa95ab5ec06489540e3f875779a parent signature: 82ab99c46f351ec6a04f0effd3175f62e60e5b39f0093d5952a3d4ac744b0882 revisions tested: 23, total time: 4h45m27.610340778s (build: 2h48m2.382262997s, test: 1h54m37.291571618s) first bad commit: abed4aaae4f71a7bcdbe90a65319b6e772a2689d btrfs: track the csum, extent, and free space trees in a rb tree recipients (to): ["clm@fb.com" "dsterba@suse.com" "dsterba@suse.com" "josef@toxicpanda.com" "josef@toxicpanda.com" "linux-btrfs@vger.kernel.org"] recipients (cc): ["linux-kernel@vger.kernel.org"] crash: kernel BUG in btrfs_global_root_insert BTRFS error (device loop0): failed to load root csum assertion failed: !tmp, in fs/btrfs/disk-io.c:1270 ------------[ cut here ]------------ kernel BUG at fs/btrfs/ctree.h:3519! invalid opcode: 0000 [#1] PREEMPT SMP KASAN CPU: 0 PID: 4182 Comm: syz-executor.0 Not tainted 5.16.0-rc8-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022 RIP: 0010:assertfail.constprop.0+0x18/0x1a fs/btrfs/ctree.h:3519 Code: e9 d4 fd ff ff 4c 89 ef e8 9e 17 64 f9 e9 fe fd ff ff 89 f1 48 c7 c2 00 f5 10 89 48 89 fe 48 c7 c7 40 f5 10 89 e8 83 1c f5 ff <0f> 0b 41 55 ba ff ff 37 00 41 54 48 c1 e2 2a 55 53 48 89 fb 48 83 RSP: 0018:ffffc9000292f748 EFLAGS: 00010286 RAX: 0000000000000032 RBX: ffff88807918e000 RCX: 0000000000000000 RDX: 0000000000000001 RSI: ffffffff8921d6a0 RDI: fffff52000525edc RBP: ffff888074fe0000 R08: 0000000000000032 R09: ffff8880b9c34007 R10: ffffed1017386800 R11: 0000000000000001 R12: ffff888074fe01f7 R13: ffff88807713c098 R14: ffff88807713c058 R15: dffffc0000000000 FS: 00007fdb91316700(0000) GS:ffff8880b9c00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 000055a93365f418 CR3: 0000000077c44000 CR4: 0000000000350ef0 Call Trace: btrfs_global_root_insert.cold+0x1e/0x1e fs/btrfs/disk-io.c:1270 load_global_roots_objectid+0x314/0x3ff fs/btrfs/disk-io.c:2591 load_global_roots fs/btrfs/disk-io.c:2622 [inline] btrfs_read_roots fs/btrfs/disk-io.c:2649 [inline] init_tree_roots fs/btrfs/disk-io.c:3017 [inline] open_ctree+0x26ed/0x3e33 fs/btrfs/disk-io.c:3654 btrfs_fill_super fs/btrfs/super.c:1359 [inline] btrfs_mount_root.cold+0xe/0x118 fs/btrfs/super.c:1726 legacy_get_tree+0xfa/0x1f0 fs/fs_context.c:610 vfs_get_tree+0x7f/0x2c0 fs/super.c:1500 fc_mount fs/namespace.c:994 [inline] vfs_kern_mount.part.0+0x70/0x100 fs/namespace.c:1024 btrfs_mount+0x1aa/0x920 fs/btrfs/super.c:1786 legacy_get_tree+0xfa/0x1f0 fs/fs_context.c:610 vfs_get_tree+0x7f/0x2c0 fs/super.c:1500 do_new_mount fs/namespace.c:2988 [inline] path_mount+0x7e8/0x1a40 fs/namespace.c:3318 do_mount fs/namespace.c:3331 [inline] __do_sys_mount fs/namespace.c:3539 [inline] __se_sys_mount fs/namespace.c:3516 [inline] __x64_sys_mount+0x1f5/0x260 fs/namespace.c:3516 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x35/0x80 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x44/0xae RIP: 0033:0x7fdb91ba3ada Code: 48 c7 c2 b8 ff ff ff f7 d8 64 89 02 b8 ff ff ff ff eb d2 e8 b8 04 00 00 0f 1f 84 00 00 00 00 00 49 89 ca b8 a5 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fdb91315f88 EFLAGS: 00000246 ORIG_RAX: 00000000000000a5 RAX: ffffffffffffffda RBX: 0000000020000200 RCX: 00007fdb91ba3ada RDX: 0000000020000000 RSI: 0000000020000100 RDI: 00007fdb91315fe0 RBP: 00007fdb91316020 R08: 00007fdb91316020 R09: 0000000020000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000020000000 R13: 0000000020000100 R14: 00007fdb91315fe0 R15: 0000000020002740 Modules linked in: ---[ end trace 68f7184cd7d4c778 ]--- RIP: 0010:assertfail.constprop.0+0x18/0x1a fs/btrfs/ctree.h:3519 Code: e9 d4 fd ff ff 4c 89 ef e8 9e 17 64 f9 e9 fe fd ff ff 89 f1 48 c7 c2 00 f5 10 89 48 89 fe 48 c7 c7 40 f5 10 89 e8 83 1c f5 ff <0f> 0b 41 55 ba ff ff 37 00 41 54 48 c1 e2 2a 55 53 48 89 fb 48 83 RSP: 0018:ffffc9000292f748 EFLAGS: 00010286 RAX: 0000000000000032 RBX: ffff88807918e000 RCX: 0000000000000000 RDX: 0000000000000001 RSI: ffffffff8921d6a0 RDI: fffff52000525edc RBP: ffff888074fe0000 R08: 0000000000000032 R09: ffff8880b9c34007 R10: ffffed1017386800 R11: 0000000000000001 R12: ffff888074fe01f7 R13: ffff88807713c098 R14: ffff88807713c058 R15: dffffc0000000000 FS: 00007fdb91316700(0000) GS:ffff8880b9c00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007f0127102a70 CR3: 0000000077c44000 CR4: 0000000000350ef0