syzbot


BUG: sleeping function called from invalid context in do_page_fault (3)

Status: upstream: reported on 2022/04/25 16:04
Reported-by: syzbot+2845b2dfa28dec36e215@syzkaller.appspotmail.com
First crash: 165d, last: 2d16h
similar bugs (2):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream BUG: sleeping function called from invalid context in do_page_fault (2) 1 531d 521d 0/24 auto-closed as invalid on 2021/08/18 11:26
upstream BUG: sleeping function called from invalid context in do_page_fault C done error 7 875d 942d 0/24 closed as dup on 2020/08/16 04:02

Sample crash report:
BUG: sleeping function called from invalid context at kernel/locking/rwsem.c:1460
in_atomic(): 0, irqs_disabled(): 1, non_block: 0, pid: 10782, name: syz-executor.0
preempt_count: 0, expected: 0
RCU nest depth: 0, expected: 0
no locks held by syz-executor.0/10782.
irq event stamp: 4856
hardirqs last  enabled at (4855): [<ffffffff80b089e4>] __free_object+0x472/0x580 lib/debugobjects.c:421
hardirqs last disabled at (4856): [<ffffffff8000e866>] __trace_hardirqs_off+0x18/0x20 arch/riscv/kernel/trace_irq.c:25
softirqs last  enabled at (4438): [<ffffffff831b0bd0>] softirq_handle_end kernel/softirq.c:401 [inline]
softirqs last  enabled at (4438): [<ffffffff831b0bd0>] __do_softirq+0x618/0x8fc kernel/softirq.c:587
softirqs last disabled at (4431): [<ffffffff80061288>] do_softirq_own_stack include/asm-generic/softirq_stack.h:10 [inline]
softirqs last disabled at (4431): [<ffffffff80061288>] invoke_softirq kernel/softirq.c:439 [inline]
softirqs last disabled at (4431): [<ffffffff80061288>] __irq_exit_rcu+0x142/0x1f8 kernel/softirq.c:637
CPU: 1 PID: 10782 Comm: syz-executor.0 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
[<ffffffff800baf2a>] __might_resched+0x30a/0x342 kernel/sched/core.c:9583
[<ffffffff800bafc0>] __might_sleep+0x5e/0x8e kernel/sched/core.c:9512
[<ffffffff831ab63e>] down_read+0x24/0x54 kernel/locking/rwsem.c:1460
[<ffffffff800117d4>] mmap_read_lock include/linux/mmap_lock.h:117 [inline]
[<ffffffff800117d4>] do_page_fault+0x24e/0xa3c arch/riscv/mm/fault.c:285
[<ffffffff80005724>] ret_from_exception+0x0/0x10

Crashes (6):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci-qemu2-riscv64 2022/10/01 05:46 git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux.git fixes 0966d385830d feb56351 .config log report info BUG: sleeping function called from invalid context in do_page_fault
ci-qemu2-riscv64 2022/09/14 09:40 git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux.git fixes 0966d385830d b884348d .config log report info BUG: sleeping function called from invalid context in do_page_fault
ci-qemu2-riscv64 2022/07/16 09:36 git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux.git fixes 0966d385830d 95cb00d1 .config log report info BUG: sleeping function called from invalid context in do_page_fault
ci-qemu2-riscv64 2022/05/07 12:02 git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux.git fixes 0966d385830d e60b1103 .config log report info BUG: sleeping function called from invalid context in do_page_fault
ci-qemu2-riscv64 2022/04/28 13:52 git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux.git fixes 0966d385830d 8a1f1f07 .config log report info BUG: sleeping function called from invalid context in do_page_fault
ci-qemu2-riscv64 2022/04/21 15:56 git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux.git fixes 0966d385830d 2738b391 .config log report info BUG: sleeping function called from invalid context in do_page_fault
* Struck through repros no longer work on HEAD.