syzbot


kernel panic: corrupted stack end in ext4_file_mmap

Status: internal: reported on 2022/09/27 20:47
Reported-by: syzbot+@syzkaller.appspotmail.com
Fix commit: b81d591386c3 riscv: Increase stack size under KASAN
Patched on: [ci-qemu-upstream ci-qemu-upstream-386 ci-qemu2-arm32 ci-qemu2-arm64 ci-qemu2-arm64-compat ci-qemu2-arm64-mte ci-upstream-bpf-kasan-gce ci-upstream-bpf-next-kasan-gce ci-upstream-gce-arm64 ci-upstream-gce-leak ci-upstream-kasan-gce ci-upstream-kasan-gce-386 ci-upstream-kasan-gce-root ci-upstream-kasan-gce-selinux-root ci-upstream-kasan-gce-smack-root ci-upstream-kmsan-gce ci-upstream-kmsan-gce-386 ci-upstream-linux-next-kasan-gce-root ci-upstream-net-kasan-gce ci-upstream-net-this-kasan-gce ci2-upstream-fs ci2-upstream-kcsan-gce ci2-upstream-usb], missing on: [ci-qemu2-riscv64]
First crash: 124d, last: 124d

Sample crash report:
Kernel panic - not syncing: corrupted stack end detected inside scheduler
CPU: 0 PID: 2030 Comm: cmp Not tainted 5.17.0-rc1-syzkaller-00002-g0966d385830d #0
Hardware name: riscv-virtio,qemu (DT)
Call Trace:
[<ffffffff8000a228>] dump_backtrace+0x2e/0x3c arch/riscv/kernel/stacktrace.c:113
[<ffffffff831668cc>] show_stack+0x34/0x40 arch/riscv/kernel/stacktrace.c:119
[<ffffffff831756ba>] __dump_stack lib/dump_stack.c:88 [inline]
[<ffffffff831756ba>] dump_stack_lvl+0xe4/0x150 lib/dump_stack.c:106
[<ffffffff83175742>] dump_stack+0x1c/0x24 lib/dump_stack.c:113
[<ffffffff83166fa8>] panic+0x24a/0x634 kernel/panic.c:233
[<ffffffff831a688a>] schedule_debug kernel/sched/core.c:5541 [inline]
[<ffffffff831a688a>] schedule+0x0/0x14c kernel/sched/core.c:6187
[<ffffffff831a6c62>] preempt_schedule_notrace+0x9c/0x19a kernel/sched/core.c:6541
[<ffffffff801448be>] rcu_is_watching+0xa0/0xae kernel/rcu/tree.c:1129
[<ffffffff8013f2c6>] rcu_read_lock_held_common kernel/rcu/update.c:108 [inline]
[<ffffffff8013f2c6>] rcu_read_lock_held+0x22/0x4e kernel/rcu/update.c:309
[<ffffffff806d3948>] ext4_get_group_desc+0x106/0x3c2 fs/ext4/balloc.c:284
[<ffffffff8071e302>] __ext4_get_inode_loc+0x154/0xc08 fs/ext4/inode.c:4392
[<ffffffff8072413e>] ext4_get_inode_loc+0xb2/0x138 fs/ext4/inode.c:4533
[<ffffffff807281be>] ext4_reserve_inode_write+0x76/0x164 fs/ext4/inode.c:5696
[<ffffffff807287ce>] __ext4_mark_inode_dirty+0x17a/0x6bc fs/ext4/inode.c:5865
[<ffffffff80733182>] ext4_dirty_inode+0x90/0xba fs/ext4/inode.c:5902
[<ffffffff8053ebec>] __mark_inode_dirty+0x40a/0xf04 fs/fs-writeback.c:2409
[<ffffffff8050f47c>] generic_update_time fs/inode.c:1856 [inline]
[<ffffffff8050f47c>] inode_update_time fs/inode.c:1869 [inline]
[<ffffffff8050f47c>] touch_atime+0x656/0x67a fs/inode.c:1941
[<ffffffff806fb95c>] file_accessed include/linux/fs.h:2421 [inline]
[<ffffffff806fb95c>] ext4_file_mmap+0x236/0x23c fs/ext4/file.c:778
[<ffffffff803eff16>] call_mmap include/linux/fs.h:2079 [inline]
[<ffffffff803eff16>] mmap_region+0x7a0/0xa88 mm/mmap.c:1793
[<ffffffff803f0982>] do_mmap+0x784/0x8d2 mm/mmap.c:1582
[<ffffffff80395578>] vm_mmap_pgoff+0x1a2/0x24e mm/util.c:519
[<ffffffff803956a6>] vm_mmap+0x82/0xaa mm/util.c:538
[<ffffffff805ffd98>] elf_map+0xbe/0x1da fs/binfmt_elf.c:392
[<ffffffff80601520>] load_elf_interp fs/binfmt_elf.c:637 [inline]
[<ffffffff80601520>] load_elf_binary+0x12de/0x2716 fs/binfmt_elf.c:1228
[<ffffffff804d6cd0>] search_binary_handler fs/exec.c:1727 [inline]
[<ffffffff804d6cd0>] exec_binprm fs/exec.c:1768 [inline]
[<ffffffff804d6cd0>] bprm_execve fs/exec.c:1837 [inline]
[<ffffffff804d6cd0>] bprm_execve+0x5bc/0x1140 fs/exec.c:1799
[<ffffffff804d8b3a>] do_execveat_common+0x298/0x312 fs/exec.c:1926
[<ffffffff804da664>] do_execve fs/exec.c:1994 [inline]
[<ffffffff804da664>] __do_sys_execve fs/exec.c:2070 [inline]
[<ffffffff804da664>] sys_execve+0x32/0x40 fs/exec.c:2065
[<ffffffff80005716>] ret_from_syscall+0x0/0x2
SMP: stopping secondary CPUs
Rebooting in 86400 seconds..

Crashes (1):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets Title
ci-qemu2-riscv64 2022/09/27 20:46 git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux.git fixes 0966d385830d 87840e00 .config console log report info kernel panic: corrupted stack end in ext4_file_mmap
* Struck through repros no longer work on HEAD.