syzbot


KASAN: global-out-of-bounds Read in lock_sock_nested

Status: auto-closed as invalid on 2021/01/31 05:04
Subsystems: bluetooth
[Documentation on labels]
Reported-by: syzbot+92de81bbc21385b15723@syzkaller.appspotmail.com
First crash: 1296d, last: 1263d
Discussions (1)
Title Replies (including bot) Last reply
KASAN: global-out-of-bounds Read in lock_sock_nested 0 (1) 2020/12/01 10:30
Similar bugs (1)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream BUG: unable to handle kernel paging request in lock_sock_nested bluetooth 43 881d 1321d 0/26 auto-closed as invalid on 2022/02/16 22:16

Sample crash report:
==================================================================
BUG: KASAN: global-out-of-bounds in instrument_atomic_read include/linux/instrumented.h:56 [inline]
BUG: KASAN: global-out-of-bounds in test_bit include/asm-generic/bitops/instrumented-non-atomic.h:110 [inline]
BUG: KASAN: global-out-of-bounds in __lock_acquire+0xfa0/0x5780 kernel/locking/lockdep.c:4411
Read of size 8 at addr ffffffff890f9b18 by task kworker/1:0/17

CPU: 1 PID: 17 Comm: kworker/1:0 Not tainted 5.9.0-rc7-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Workqueue: events l2cap_chan_timeout
Call Trace:
 __dump_stack lib/dump_stack.c:77 [inline]
 dump_stack+0x198/0x1fd lib/dump_stack.c:118
 print_address_description.constprop.0.cold+0x5/0x497 mm/kasan/report.c:383
 __kasan_report mm/kasan/report.c:513 [inline]
 kasan_report.cold+0x1f/0x37 mm/kasan/report.c:530
 check_memory_region_inline mm/kasan/generic.c:186 [inline]
 check_memory_region+0x13d/0x180 mm/kasan/generic.c:192
 instrument_atomic_read include/linux/instrumented.h:56 [inline]
 test_bit include/asm-generic/bitops/instrumented-non-atomic.h:110 [inline]
 __lock_acquire+0xfa0/0x5780 kernel/locking/lockdep.c:4411
 lock_acquire+0x1f3/0xaf0 kernel/locking/lockdep.c:5029
 __raw_spin_lock_bh include/linux/spinlock_api_smp.h:135 [inline]
 _raw_spin_lock_bh+0x2f/0x40 kernel/locking/spinlock.c:175
 spin_lock_bh include/linux/spinlock.h:359 [inline]
 lock_sock_nested+0x3b/0x110 net/core/sock.c:3048
 l2cap_sock_teardown_cb+0x88/0x400 net/bluetooth/l2cap_sock.c:1520
 l2cap_chan_del+0xad/0x1300 net/bluetooth/l2cap_core.c:618
 l2cap_chan_close+0x118/0xb10 net/bluetooth/l2cap_core.c:823
 l2cap_chan_timeout+0x173/0x450 net/bluetooth/l2cap_core.c:436
 process_one_work+0x94c/0x1670 kernel/workqueue.c:2269
 worker_thread+0x64c/0x1120 kernel/workqueue.c:2415
 kthread+0x3b5/0x4a0 kernel/kthread.c:292
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:294

The buggy address belongs to the variable:
 rtl8150_table+0x9f8/0x26e0

Memory state around the buggy address:
 ffffffff890f9a00: 00 05 f9 f9 f9 f9 f9 f9 00 00 00 06 f9 f9 f9 f9
 ffffffff890f9a80: 00 00 05 f9 f9 f9 f9 f9 00 00 00 f9 f9 f9 f9 f9
>ffffffff890f9b00: 00 00 07 f9 f9 f9 f9 f9 00 00 00 02 f9 f9 f9 f9
                            ^
 ffffffff890f9b80: 00 00 07 f9 f9 f9 f9 f9 00 00 f9 f9 f9 f9 f9 f9
 ffffffff890f9c00: 07 f9 f9 f9 f9 f9 f9 f9 00 00 00 03 f9 f9 f9 f9
==================================================================

Crashes (2):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2020/10/03 05:03 upstream d3d45f8220d6 2653fa43 .config console log report info ci-upstream-kasan-gce-selinux-root
2020/08/31 07:18 net-next-old 0f091e43310f d5a3ae1f .config console log report ci-upstream-net-kasan-gce
* Struck through repros no longer work on HEAD.