bisecting cause commit starting from be978f8feb1d4678b941a3ccf181eea1039110e2 building syzkaller on f90ec89960664f503e0811d8b67c56bb1128d47d testing commit be978f8feb1d4678b941a3ccf181eea1039110e2 with gcc (GCC) 8.1.0 kernel signature: 4018a97bbac927b25351b96d5856c6cba87c4ac720753e31bb9e73a3a153522b all runs: crashed: WARNING in __kernel_write testing release v5.7 testing commit 3d77e6a8804abcc0504c904bd6e5cdf3a5cf8162 with gcc (GCC) 8.1.0 kernel signature: f7a9f224c53ea2d9734a6580de359464691daf53e4303be542a47e8665bbc762 all runs: OK # git bisect start be978f8feb1d4678b941a3ccf181eea1039110e2 3d77e6a8804abcc0504c904bd6e5cdf3a5cf8162 Bisecting: 11903 revisions left to test after this (roughly 14 steps) [80ef846e9909f22ccdc2a4a6d931266cecce8b2c] Merge tag 'staging-5.8-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging testing commit 80ef846e9909f22ccdc2a4a6d931266cecce8b2c with gcc (GCC) 8.1.0 kernel signature: 29a61743ff72d4114695b019664af426b333d4929c824fb85214a17474bbd273 all runs: basic kernel testing failed: BUG: using smp_processor_id() in preemptible code in ext4_mb_new_blocks # git bisect skip 80ef846e9909f22ccdc2a4a6d931266cecce8b2c Bisecting: 11903 revisions left to test after this (roughly 14 steps) [b97120b15ebd3de51325084136d3b9c3cce656d6] nvme-pci: use simple suspend when a HMB is enabled testing commit b97120b15ebd3de51325084136d3b9c3cce656d6 with gcc (GCC) 8.1.0 kernel signature: 0c20cdf2dcaf9b4250042c495d5290aa1d809224343f3b83e51388b81ddab2d6 all runs: OK # git bisect good b97120b15ebd3de51325084136d3b9c3cce656d6 Bisecting: 10248 revisions left to test after this (roughly 13 steps) [6f51ab9440d131ae424cce27e3170746219f5142] Merge tag 'mtd/for-5.8' of git://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux testing commit 6f51ab9440d131ae424cce27e3170746219f5142 with gcc (GCC) 8.1.0 kernel signature: fba9247d93b0bd04d41a11df78d3368798f144f2d2ef03751b0101bc50419597 all runs: basic kernel testing failed: BUG: using smp_processor_id() in preemptible code in ext4_mb_new_blocks # git bisect skip 6f51ab9440d131ae424cce27e3170746219f5142 Bisecting: 10248 revisions left to test after this (roughly 13 steps) [7b411871220af35722360cd1d1111c7fadfc29fe] misc: pch_phub: Remove superfluous descriptions to non-existent args 'offset_address' testing commit 7b411871220af35722360cd1d1111c7fadfc29fe with gcc (GCC) 8.1.0 kernel signature: 97f71443a612eb61f25289111edc079fdbd7645c6c25a67117eed527274ebcae all runs: OK # git bisect good 7b411871220af35722360cd1d1111c7fadfc29fe Bisecting: 4244 revisions left to test after this (roughly 12 steps) [ae5e4d2e6d7bec8a063fd8608fba00fb8c273896] Merge remote-tracking branch 'crypto/master' testing commit ae5e4d2e6d7bec8a063fd8608fba00fb8c273896 with gcc (GCC) 8.1.0 kernel signature: 043ae5220011ed102010ca90e5cdcf5c3769ab244ebc0721c7bb2c08bc54bb8e all runs: crashed: WARNING in __kernel_write # git bisect bad ae5e4d2e6d7bec8a063fd8608fba00fb8c273896 Bisecting: 1898 revisions left to test after this (roughly 11 steps) [05f24e945ebfaf1ccec7dc0cf6e664250b8d9df1] Merge remote-tracking branch 'printk/for-next' testing commit 05f24e945ebfaf1ccec7dc0cf6e664250b8d9df1 with gcc (GCC) 8.1.0 kernel signature: 897d0c9050fe8550111a5a30aca251805308e672367ee977de8a65dab2404ae3 all runs: crashed: WARNING in __kernel_write # git bisect bad 05f24e945ebfaf1ccec7dc0cf6e664250b8d9df1 Bisecting: 915 revisions left to test after this (roughly 10 steps) [008badb7e3a769def89a3712b396cdf5b24e3c19] Merge remote-tracking branch 'arm-soc/for-next' testing commit 008badb7e3a769def89a3712b396cdf5b24e3c19 with gcc (GCC) 8.1.0 kernel signature: 736c364f7f24cc7f0fb59f2119e2329f506c718e8c91c0fcf8a0ac23561ff54f all runs: crashed: WARNING in __kernel_write # git bisect bad 008badb7e3a769def89a3712b396cdf5b24e3c19 Bisecting: 512 revisions left to test after this (roughly 9 steps) [9321f1aaf63e74ec3884347490e4ebb039f01b6e] mips: Remove compiler check in unroll macro testing commit 9321f1aaf63e74ec3884347490e4ebb039f01b6e with gcc (GCC) 8.1.0 kernel signature: a5ce0785fe8dd69d92f2ca78ec7eb5ed5b1f737cf0b4338b8530fa5a9744ac19 all runs: crashed: WARNING in __kernel_write # git bisect bad 9321f1aaf63e74ec3884347490e4ebb039f01b6e Bisecting: 221 revisions left to test after this (roughly 8 steps) [f23dbe18930ba992f5c8c7b31e80f40dd6716081] Merge tag 'irq-urgent-2020-07-05' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip testing commit f23dbe18930ba992f5c8c7b31e80f40dd6716081 with gcc (GCC) 8.1.0 kernel signature: 500a1522a0573e3870da88c6cd18c42cedfce5ceb5bdbf5a13032ef84b36929c run #0: OK run #1: boot failed: can't ssh into the instance run #2: OK run #3: OK run #4: OK run #5: OK run #6: OK run #7: OK run #8: OK run #9: OK # git bisect good f23dbe18930ba992f5c8c7b31e80f40dd6716081 Bisecting: 109 revisions left to test after this (roughly 7 steps) [2a89b99f580371b86ae9bafd6cbeccd3bfab524a] Merge tag 'for-5.8/dm-fixes-2' of git://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm testing commit 2a89b99f580371b86ae9bafd6cbeccd3bfab524a with gcc (GCC) 8.1.0 kernel signature: 7eaabc8f080bf6ad6f4c4edc68ae6c9ce84b4d867f488da0a8c4206decdb3faf run #0: boot failed: can't ssh into the instance run #1: OK run #2: OK run #3: OK run #4: OK run #5: OK run #6: OK run #7: OK run #8: OK run #9: OK # git bisect good 2a89b99f580371b86ae9bafd6cbeccd3bfab524a Bisecting: 52 revisions left to test after this (roughly 6 steps) [f4c8824cbcc64524905f83388eb1139747829756] Merge tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux testing commit f4c8824cbcc64524905f83388eb1139747829756 with gcc (GCC) 8.1.0 kernel signature: fc4b101481f3a27c0978e2af6fecd72c91bdabce21558d2a7702b3af3a27d39f all runs: OK # git bisect good f4c8824cbcc64524905f83388eb1139747829756 Bisecting: 21 revisions left to test after this (roughly 5 steps) [b1b11d0063aab28aaf65f63cff56470bc01dc290] Merge tag 'cleanup-kernel_read_write' of git://git.infradead.org/users/hch/misc testing commit b1b11d0063aab28aaf65f63cff56470bc01dc290 with gcc (GCC) 8.1.0 kernel signature: 6de2b27f4b7f2c9b7d0639099ccb71acc942e2f6aa5fdf25d3fb6ae49bb81831 all runs: crashed: WARNING in __kernel_write # git bisect bad b1b11d0063aab28aaf65f63cff56470bc01dc290 Bisecting: 14 revisions left to test after this (roughly 4 steps) [25aadbd2a8ad05ed0477cb94c7659075f540d158] Merge tag 'pinctrl-v5.8-3' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl testing commit 25aadbd2a8ad05ed0477cb94c7659075f540d158 with gcc (GCC) 8.1.0 kernel signature: 28b64dc7305ef082642820477c4e9930d99f3eaa66b6a1c870040ac5d5ca5991 run #0: OK run #1: boot failed: can't ssh into the instance run #2: OK run #3: OK run #4: OK run #5: OK run #6: OK run #7: OK run #8: OK run #9: OK # git bisect good 25aadbd2a8ad05ed0477cb94c7659075f540d158 Bisecting: 7 revisions left to test after this (roughly 3 steps) [53ad86266bda973b526078227997ca3fcb92c9be] fs: remove __vfs_write testing commit 53ad86266bda973b526078227997ca3fcb92c9be with gcc (GCC) 8.1.0 kernel signature: a5d94510cd4decc689812c8dbc7526c722ae7b2ea8384d4f037718f76a6c6cf1 all runs: crashed: WARNING in __kernel_write # git bisect bad 53ad86266bda973b526078227997ca3fcb92c9be Bisecting: 3 revisions left to test after this (roughly 2 steps) [6955a76fbcd56d27c84c01353101048e366d070f] bpfilter: switch to kernel_write testing commit 6955a76fbcd56d27c84c01353101048e366d070f with gcc (GCC) 8.1.0 kernel signature: bd4b852855d1ed74ca3f3e87e7146d76e0c1409fe9673654980796c123e47f8d all runs: OK # git bisect good 6955a76fbcd56d27c84c01353101048e366d070f Bisecting: 1 revision left to test after this (roughly 1 step) [a01ac27be4729f80176a45c54611b768dfbdc840] fs: check FMODE_WRITE in __kernel_write testing commit a01ac27be4729f80176a45c54611b768dfbdc840 with gcc (GCC) 8.1.0 kernel signature: e5ecf7b644de8838c890c9688ebd6e6703eba9f7f65799ddb5f5a0eb226f4377 all runs: OK # git bisect good a01ac27be4729f80176a45c54611b768dfbdc840 Bisecting: 0 revisions left to test after this (roughly 0 steps) [81238b2cff1469ff5b94390d026cd075105d6dcd] fs: implement kernel_write using __kernel_write testing commit 81238b2cff1469ff5b94390d026cd075105d6dcd with gcc (GCC) 8.1.0 kernel signature: b6f3fa84e2df7435faae7161ac7374d28dbbe886b697215c5b77171cdb5fd184 all runs: crashed: WARNING in __kernel_write # git bisect bad 81238b2cff1469ff5b94390d026cd075105d6dcd 81238b2cff1469ff5b94390d026cd075105d6dcd is the first bad commit commit 81238b2cff1469ff5b94390d026cd075105d6dcd Author: Christoph Hellwig Date: Thu May 7 19:33:03 2020 +0200 fs: implement kernel_write using __kernel_write Consolidate the two in-kernel write helpers to make upcoming changes easier. The only difference are the missing call to rw_verify_area in kernel_write, and an access_ok check that doesn't make sense for kernel buffers to start with. Signed-off-by: Christoph Hellwig fs/read_write.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) culprit signature: b6f3fa84e2df7435faae7161ac7374d28dbbe886b697215c5b77171cdb5fd184 parent signature: e5ecf7b644de8838c890c9688ebd6e6703eba9f7f65799ddb5f5a0eb226f4377 revisions tested: 19, total time: 4h49m51.858015407s (build: 1h38m32.804441151s, test: 3h8m46.331486762s) first bad commit: 81238b2cff1469ff5b94390d026cd075105d6dcd fs: implement kernel_write using __kernel_write cc: ["hch@lst.de" "linux-fsdevel@vger.kernel.org" "linux-kernel@vger.kernel.org" "viro@zeniv.linux.org.uk"] crash: WARNING in __kernel_write ------------[ cut here ]------------ WARNING: CPU: 0 PID: 8394 at fs/read_write.c:509 fsnotify_file include/linux/fsnotify.h:78 [inline] WARNING: CPU: 0 PID: 8394 at fs/read_write.c:509 fsnotify_modify include/linux/fsnotify.h:257 [inline] WARNING: CPU: 0 PID: 8394 at fs/read_write.c:509 __kernel_write+0xfd/0x120 fs/read_write.c:522 Kernel panic - not syncing: panic_on_warn set ... CPU: 0 PID: 8394 Comm: kworker/0:4 Not tainted 5.8.0-rc4-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Workqueue: events p9_write_work Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0xb3/0xec lib/dump_stack.c:118 panic+0x115/0x2fa kernel/panic.c:231 __warn.cold.13+0x20/0x25 kernel/panic.c:600 report_bug+0xc0/0xf0 lib/bug.c:198 handle_bug+0x35/0x90 arch/x86/kernel/traps.c:235 exc_invalid_op+0x13/0x60 arch/x86/kernel/traps.c:255 asm_exc_invalid_op+0x12/0x20 arch/x86/include/asm/idtentry.h:542 RIP: 0010:__kernel_write+0xfd/0x120 fs/read_write.c:509 Code: 8b 04 25 00 7f 01 00 48 01 a8 a0 10 00 00 eb 8a 45 31 c9 45 31 c0 b9 01 00 00 00 4c 89 f2 89 de 4c 89 ef e8 a5 95 05 00 eb d4 <0f> 0b 48 c7 c5 f7 ff ff ff e9 73 ff ff ff 48 c7 c5 ea ff ff ff e9 RSP: 0018:ffffc90002b8fdc0 EFLAGS: 00010246 RAX: 00000000040a0001 RBX: ffff88812a4e9a00 RCX: ffff88812a4e9b18 RDX: 0000000000000015 RSI: ffff88811116a000 RDI: ffff88812a4e9a00 RBP: 0000000000000015 R08: 0000000000000000 R09: 0000000000000000 R10: ffff88810f40ebd0 R11: 18a3fb7e5efbefec R12: ffff88812a4e9b18 R13: ffff88811116a000 R14: ffff88812a69ecc0 R15: ffff888118e2fe30 kernel_write+0x5d/0xb0 fs/read_write.c:539 p9_fd_write net/9p/trans_fd.c:424 [inline] p9_write_work+0x88/0x2f0 net/9p/trans_fd.c:475 process_one_work+0x26a/0x5f0 kernel/workqueue.c:2269 worker_thread+0x38/0x380 kernel/workqueue.c:2415 kthread+0x148/0x170 kernel/kthread.c:291 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:293 Kernel Offset: disabled Rebooting in 86400 seconds..