[moderation] [net?] WARNING: refcount bug in nsim_fib_event_nb

0 views
Skip to first unread message

syzbot

unread,
Jun 5, 2024, 4:24:23 AMJun 5
to syzkaller-upst...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: 2b438c5774cc openvswitch: Remove generic .ndo_get_stats64
git tree: net-next
console output: https://syzkaller.appspot.com/x/log.txt?x=164ecbaa980000
kernel config: https://syzkaller.appspot.com/x/.config?x=b9016f104992d69c
dashboard link: https://syzkaller.appspot.com/bug?extid=eb26da833888f8e19b67
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40
CC: [da...@davemloft.net edum...@google.com ku...@kernel.org linux-...@vger.kernel.org net...@vger.kernel.org pab...@redhat.com]

Unfortunately, I don't have any reproducer for this issue yet.

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/ab7dc74d19b2/disk-2b438c57.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/e800ef3a3282/vmlinux-2b438c57.xz
kernel image: https://storage.googleapis.com/syzbot-assets/dbaacee3fbf7/bzImage-2b438c57.xz

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

------------[ cut here ]------------
refcount_t: addition on 0; use-after-free.
WARNING: CPU: 1 PID: 46 at lib/refcount.c:25 refcount_warn_saturate+0x13a/0x1d0 lib/refcount.c:25
Modules linked in:
CPU: 1 PID: 46 Comm: kworker/u8:3 Not tainted 6.10.0-rc1-syzkaller-00260-g2b438c5774cc #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/02/2024
Workqueue: netns cleanup_net
RIP: 0010:refcount_warn_saturate+0x13a/0x1d0 lib/refcount.c:25
Code: 80 9f 1f 8c e8 a7 f1 a8 fc 90 0f 0b 90 90 eb b9 e8 0b c3 e6 fc c6 05 a8 6e e8 0a 01 90 48 c7 c7 e0 9f 1f 8c e8 87 f1 a8 fc 90 <0f> 0b 90 90 eb 99 e8 eb c2 e6 fc c6 05 89 6e e8 0a 01 90 48 c7 c7
RSP: 0018:ffffc90000b673a0 EFLAGS: 00010246
RAX: aeacbc3fb5d60300 RBX: ffff88801829263c RCX: ffff88801b2a9e00
RDX: 0000000000000000 RSI: 0000000000000001 RDI: 0000000000000000
RBP: 0000000000000002 R08: ffffffff815847a2 R09: 1ffff110172a519a
R10: dffffc0000000000 R11: ffffed10172a519b R12: ffffffffffffffff
R13: ffff88807e1ed000 R14: ffff88801829263c R15: dffffc0000000000
FS: 0000000000000000(0000) GS:ffff8880b9500000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f7820726ff8 CR3: 000000001e5ca000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
<TASK>
__refcount_inc include/linux/refcount.h:241 [inline]
refcount_inc include/linux/refcount.h:258 [inline]
fib_info_hold include/net/ip_fib.h:577 [inline]
nsim_fib4_prepare_event drivers/net/netdevsim/fib.c:930 [inline]
nsim_fib_event_schedule_work drivers/net/netdevsim/fib.c:1000 [inline]
nsim_fib_event_nb+0xee9/0x10b0 drivers/net/netdevsim/fib.c:1043
call_fib_notifier+0x42/0x70 net/core/fib_notifier.c:24
call_fib_entry_notifier net/ipv4/fib_trie.c:90 [inline]
fib_leaf_notify net/ipv4/fib_trie.c:2203 [inline]
fib_table_notify net/ipv4/fib_trie.c:2221 [inline]
fib_notify+0x445/0x780 net/ipv4/fib_trie.c:2244
fib_net_dump net/core/fib_notifier.c:71 [inline]
register_fib_notifier+0x182/0x370 net/core/fib_notifier.c:109
nsim_fib_create+0x902/0xa70 drivers/net/netdevsim/fib.c:1595
nsim_dev_reload_create drivers/net/netdevsim/dev.c:1480 [inline]
nsim_dev_reload_up+0x3d1/0x8e0 drivers/net/netdevsim/dev.c:985
devlink_reload+0x478/0x870 net/devlink/dev.c:474
devlink_pernet_pre_exit+0x1f3/0x440 net/devlink/core.c:509
ops_pre_exit_list net/core/net_namespace.c:163 [inline]
cleanup_net+0x615/0xcc0 net/core/net_namespace.c:620
process_one_work kernel/workqueue.c:3231 [inline]
process_scheduled_works+0xa2c/0x1830 kernel/workqueue.c:3312
worker_thread+0x86d/0xd70 kernel/workqueue.c:3393
kthread+0x2f0/0x390 kernel/kthread.c:389
ret_from_fork+0x4b/0x80 arch/x86/kernel/process.c:147
ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244
</TASK>


---
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.

If the report is already addressed, let syzbot know by replying with:
#syz fix: exact-commit-title

If you want to overwrite report's subsystems, reply with:
#syz set subsystems: new-subsystem
(See the list of subsystem names on the web dashboard)

If the report is a duplicate of another one, reply with:
#syz dup: exact-subject-of-another-report

If you want to undo deduplication, reply with:
#syz undup
Reply all
Reply to author
Forward
0 new messages