BUG: corrupted list in klist_dec_and_del

6 views
Skip to first unread message

syzbot

unread,
Nov 28, 2020, 2:47:19 AM11/28/20
to syzkaller...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: 0c88e405 Linux 4.19.160
git tree: linux-4.19.y
console output: https://syzkaller.appspot.com/x/log.txt?x=16d0e6b5500000
kernel config: https://syzkaller.appspot.com/x/.config?x=14b8a4cf9e8340fd
dashboard link: https://syzkaller.appspot.com/bug?extid=0ac8a639b2205bce1576
compiler: gcc (GCC) 10.1.0-syz 20200507
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=15756bf1500000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=1289b32d500000

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+0ac8a6...@syzkaller.appspotmail.com

IPVS: ftp: loaded support on port[0] = 21
list_del corruption. prev->next should be ffff8880b5318320, but was ffff8880b36511f8
------------[ cut here ]------------
kernel BUG at lib/list_debug.c:51!
invalid opcode: 0000 [#1] PREEMPT SMP KASAN
CPU: 1 PID: 8114 Comm: syz-executor374 Not tainted 4.19.160-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
RIP: 0010:__list_del_entry_valid.cold+0xf/0x55 lib/list_debug.c:51
Code: e8 3a a8 cf fd 0f 0b 48 89 f1 48 c7 c7 e0 ba b3 88 4c 89 e6 e8 26 a8 cf fd 0f 0b 48 89 ee 48 c7 c7 80 bc b3 88 e8 15 a8 cf fd <0f> 0b 4c 89 ea 48 89 ee 48 c7 c7 c0 bb b3 88 e8 01 a8 cf fd 0f 0b
RSP: 0018:ffff8880b139f9a8 EFLAGS: 00010286
RAX: 0000000000000054 RBX: 0000000000000001 RCX: 0000000000000000
RDX: 0000000000000000 RSI: ffffffff814fdb91 RDI: ffffed1016273f27
RBP: ffff8880b5318320 R08: 0000000000000054 R09: 0000000000000000
R10: 0000000000000005 R11: 0000000000000000 R12: ffff8880b59c7720
R13: ffff8880b59c7720 R14: ffff888094d7a840 R15: 0000000000000000
FS: 0000000000d43880(0000) GS:ffff8880ba100000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000020000200 CR3: 0000000009e6d000 CR4: 00000000001406e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
__list_del_entry include/linux/list.h:117 [inline]
list_del include/linux/list.h:125 [inline]
klist_release lib/klist.c:190 [inline]
kref_put include/linux/kref.h:70 [inline]
klist_dec_and_del+0x97/0x480 lib/klist.c:207
klist_put+0x7a/0x150 lib/klist.c:218
device_del+0x162/0xaf0 drivers/base/core.c:2305
hci_conn_del_sysfs+0xdc/0x180 net/bluetooth/hci_sysfs.c:78
hci_conn_cleanup+0x24b/0x550 net/bluetooth/hci_conn.c:128
hci_conn_del+0x2a0/0x780 net/bluetooth/hci_conn.c:611
hci_conn_hash_flush+0x19c/0x260 net/bluetooth/hci_conn.c:1513
hci_dev_do_close+0x659/0xf10 net/bluetooth/hci_core.c:1666
hci_unregister_dev+0x18b/0x910 net/bluetooth/hci_core.c:3271
vhci_release+0x70/0xe0 drivers/bluetooth/hci_vhci.c:354
__fput+0x2ce/0x890 fs/file_table.c:278
task_work_run+0x148/0x1c0 kernel/task_work.c:113
exit_task_work include/linux/task_work.h:22 [inline]
do_exit+0xbed/0x2be0 kernel/exit.c:890
do_group_exit+0x125/0x310 kernel/exit.c:993
__do_sys_exit_group kernel/exit.c:1004 [inline]
__se_sys_exit_group kernel/exit.c:1002 [inline]
__x64_sys_exit_group+0x3a/0x50 kernel/exit.c:1002
do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293
entry_SYSCALL_64_after_hwframe+0x49/0xbe
RIP: 0033:0x445098
Code: Bad RIP value.
RSP: 002b:00007ffdd5782038 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7
RAX: ffffffffffffffda RBX: 0000000000000001 RCX: 0000000000445098
RDX: 0000000000000001 RSI: 000000000000003c RDI: 0000000000000001
RBP: 00000000004ccdf0 R08: 00000000000000e7 R09: ffffffffffffffd0
R10: 0000000000000015 R11: 0000000000000246 R12: 0000000000000001
R13: 00000000006e0200 R14: 0000000000000000 R15: 0000000000000000
Modules linked in:
---[ end trace 64d9e1a1f7a9c46f ]---
RIP: 0010:__list_del_entry_valid.cold+0xf/0x55 lib/list_debug.c:51
Code: e8 3a a8 cf fd 0f 0b 48 89 f1 48 c7 c7 e0 ba b3 88 4c 89 e6 e8 26 a8 cf fd 0f 0b 48 89 ee 48 c7 c7 80 bc b3 88 e8 15 a8 cf fd <0f> 0b 4c 89 ea 48 89 ee 48 c7 c7 c0 bb b3 88 e8 01 a8 cf fd 0f 0b
RSP: 0018:ffff8880b139f9a8 EFLAGS: 00010286
RAX: 0000000000000054 RBX: 0000000000000001 RCX: 0000000000000000
RDX: 0000000000000000 RSI: ffffffff814fdb91 RDI: ffffed1016273f27
RBP: ffff8880b5318320 R08: 0000000000000054 R09: 0000000000000000
R10: 0000000000000005 R11: 0000000000000000 R12: ffff8880b59c7720
R13: ffff8880b59c7720 R14: ffff888094d7a840 R15: 0000000000000000
FS: 0000000000d43880(0000) GS:ffff8880ba100000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000000000044506e CR3: 0000000009e6d000 CR4: 00000000001406e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400


---
This report is generated by a bot. It may contain errors.
See https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at syzk...@googlegroups.com.

syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.
syzbot can test patches for this issue, for details see:
https://goo.gl/tpsmEJ#testing-patches
Reply all
Reply to author
Forward
0 new messages