BUG: corrupted list in kobject_add_internal

9 views
Skip to first unread message

syzbot

unread,
Dec 26, 2020, 4:29:18 AM12/26/20
to syzkaller...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: 13d2ce42 Linux 4.19.163
git tree: linux-4.19.y
console output: https://syzkaller.appspot.com/x/log.txt?x=14e72fa7500000
kernel config: https://syzkaller.appspot.com/x/.config?x=fac7c3360835a4e0
dashboard link: https://syzkaller.appspot.com/bug?extid=9b8ab2e0f51cbed440c0
compiler: gcc (GCC) 10.1.0-syz 20200507
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=13c5118f500000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=14d28383500000

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

IPv6: ADDRCONF(NETDEV_UP): wlan1: link is not ready
IPv6: ADDRCONF(NETDEV_UP): wlan1: link is not ready
IPv6: ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready
list_add double add: new=ffff8880ab03ab58, prev=ffff8880ab03ab58, next=ffff88823b29c400.
------------[ cut here ]------------
kernel BUG at lib/list_debug.c:29!
invalid opcode: 0000 [#1] PREEMPT SMP KASAN
IPv6: ADDRCONF(NETDEV_UP): wlan1: link is not ready
CPU: 1 PID: 8142 Comm: kworker/u5:8 Not tainted 4.19.163-syzkaller #0
wlan1: Created IBSS using preconfigured BSSID 50:50:50:50:50:50
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Workqueue: hci5 hci_rx_work
RIP: 0010:__list_add_valid.cold+0x26/0x3c lib/list_debug.c:29
Code: 57 ff ff ff 4c 89 e1 48 c7 c7 a0 bb b3 88 e8 d1 a6 cf fd 0f 0b 48 89 f2 4c 89 e1 48 89 ee 48 c7 c7 e0 bc b3 88 e8 ba a6 cf fd <0f> 0b 48 89 f1 48 c7 c7 60 bc b3 88 4c 89 e6 e8 a6 a6 cf fd 0f 0b
wlan1: Created IBSS using preconfigured BSSID 50:50:50:50:50:50
RSP: 0018:ffff888094f67800 EFLAGS: 00010282
RAX: 0000000000000058 RBX: ffff88823b29c400 RCX: 0000000000000000
RDX: 0000000000000000 RSI: ffffffff814fdbb1 RDI: ffffed10129ecef2
RBP: ffff8880ab03ab58 R08: 0000000000000058 R09: 0000000000000000
R10: 0000000000000005 R11: 0000000000000000 R12: ffff88823b29c400
R13: ffff8880956e62d0 R14: ffff8880ab03ab70 R15: ffff8880ab03ab58
FS: 0000000000000000(0000) GS:ffff8880ba100000(0000) knlGS:0000000000000000
wlan1: Created IBSS using preconfigured BSSID 50:50:50:50:50:50
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007ffdf495b070 CR3: 0000000009e6d000 CR4: 00000000001406e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
__list_add include/linux/list.h:60 [inline]
list_add_tail include/linux/list.h:93 [inline]
kobj_kset_join lib/kobject.c:188 [inline]
kobject_add_internal+0x18d/0x9c0 lib/kobject.c:238
kobject_add_varg lib/kobject.c:382 [inline]
kobject_add+0x150/0x1c0 lib/kobject.c:426
wlan1: Creating new IBSS network, BSSID 50:50:50:50:50:50
wlan1: Creating new IBSS network, BSSID 50:50:50:50:50:50
device_add+0x37b/0x16d0 drivers/base/core.c:2106
hci_conn_add_sysfs+0x97/0x1a0 net/bluetooth/hci_sysfs.c:53
hci_sync_conn_complete_evt.isra.0+0x9e9/0xca0 net/bluetooth/hci_event.c:4091
hci_event_packet+0x391f/0x7e19 net/bluetooth/hci_event.c:5854
hci_rx_work+0x4ad/0xc70 net/bluetooth/hci_core.c:4359
process_one_work+0x864/0x1570 kernel/workqueue.c:2155
IPv6: ADDRCONF(NETDEV_CHANGE): wlan1: link becomes ready
worker_thread+0x64c/0x1130 kernel/workqueue.c:2298
wlan1: Creating new IBSS network, BSSID 50:50:50:50:50:50
kthread+0x33f/0x460 kernel/kthread.c:259
ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:415
Modules linked in:
IPv6: ADDRCONF(NETDEV_CHANGE): wlan1: link becomes ready
---[ end trace 95f979322632bded ]---
IPv6: ADDRCONF(NETDEV_CHANGE): wlan1: link becomes ready
RIP: 0010:__list_add_valid.cold+0x26/0x3c lib/list_debug.c:29
Code: 57 ff ff ff 4c 89 e1 48 c7 c7 a0 bb b3 88 e8 d1 a6 cf fd 0f 0b 48 89 f2 4c 89 e1 48 89 ee 48 c7 c7 e0 bc b3 88 e8 ba a6 cf fd <0f> 0b 48 89 f1 48 c7 c7 60 bc b3 88 4c 89 e6 e8 a6 a6 cf fd 0f 0b
RSP: 0018:ffff888094f67800 EFLAGS: 00010282
RAX: 0000000000000058 RBX: ffff88823b29c400 RCX: 0000000000000000
RDX: 0000000000000000 RSI: ffffffff814fdbb1 RDI: ffffed10129ecef2
RBP: ffff8880ab03ab58 R08: 0000000000000058 R09: 0000000000000000
R10: 0000000000000005 R11: 0000000000000000 R12: ffff88823b29c400
R13: ffff8880956e62d0 R14: ffff8880ab03ab70 R15: ffff8880ab03ab58
FS: 0000000000000000(0000) GS:ffff8880ba100000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007ffdf495b070 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

syzbot

unread,
Sep 29, 2021, 11:46:07 AM9/29/21
to syzkaller...@googlegroups.com
syzbot suspects this issue was fixed by commit:

commit 3f7b869c1b44108a8cbf3e4a763ddac9df548d73
Author: Desmond Cheong Zhi Xi <desmond...@gmail.com>
Date: Tue Aug 10 04:14:06 2021 +0000

Bluetooth: avoid circular locks in sco_sock_connect

bisection log: https://syzkaller.appspot.com/x/bisect.txt?x=112b3a13300000
start commit: 13d2ce42de8c Linux 4.19.163
git tree: linux-4.19.y
If the result looks correct, please mark the issue as fixed by replying with:

#syz fix: Bluetooth: avoid circular locks in sco_sock_connect

For information about bisection process see: https://goo.gl/tpsmEJ#bisection
Reply all
Reply to author
Forward
0 new messages