[moderation] [virt?] KCSAN: data-race in virtqueue_disable_cb / virtqueue_disable_cb (5)

0 views
Skip to first unread message

syzbot

unread,
Sep 19, 2024, 10:07:26 PMSep 19
to syzkaller-upst...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: 2004cef11ea0 Merge tag 'sched-core-2024-09-19' of git://gi..
git tree: upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=170b8ca9980000
kernel config: https://syzkaller.appspot.com/x/.config?x=8ca3e8282608fcd1
dashboard link: https://syzkaller.appspot.com/bug?extid=17f8dd7cdf8903cbd75f
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40
CC: [eper...@redhat.com jaso...@redhat.com linux-...@vger.kernel.org m...@redhat.com virtual...@lists.linux.dev xuan...@linux.alibaba.com]

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

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/12edf669f5e6/disk-2004cef1.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/e9e27c004fd8/vmlinux-2004cef1.xz
kernel image: https://storage.googleapis.com/syzbot-assets/f172ce8b328e/bzImage-2004cef1.xz

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

==================================================================
BUG: KCSAN: data-race in virtqueue_disable_cb / virtqueue_disable_cb

read to 0xffff888101db0b78 of 2 bytes by interrupt on cpu 0:
virtqueue_disable_cb_split drivers/virtio/virtio_ring.c:885 [inline]
virtqueue_disable_cb+0x63/0x180 drivers/virtio/virtio_ring.c:2446
skb_xmit_done+0x5f/0x140 drivers/net/virtio_net.c:715
vring_interrupt+0x157/0x180 drivers/virtio/virtio_ring.c:2595
__handle_irq_event_percpu+0x95/0x490 kernel/irq/handle.c:158
handle_irq_event_percpu kernel/irq/handle.c:193 [inline]
handle_irq_event+0x64/0xf0 kernel/irq/handle.c:210
handle_edge_irq+0x16d/0x5b0 kernel/irq/chip.c:831
generic_handle_irq_desc include/linux/irqdesc.h:173 [inline]
handle_irq arch/x86/kernel/irq.c:247 [inline]
call_irq_handler arch/x86/kernel/irq.c:259 [inline]
__common_interrupt+0x58/0xe0 arch/x86/kernel/irq.c:285
common_interrupt+0x7c/0x90 arch/x86/kernel/irq.c:278
asm_common_interrupt+0x26/0x40 arch/x86/include/asm/idtentry.h:693
kcsan_setup_watchpoint+0x404/0x410 kernel/kcsan/core.c:705
selinux_socket_post_create+0x4a/0x2a0 security/selinux/hooks.c:4645
security_socket_post_create+0x5b/0xa0 security/security.c:4544
__sock_create+0x342/0x4f0 net/socket.c:1593
sock_create net/socket.c:1628 [inline]
__sys_socket_create net/socket.c:1665 [inline]
__sys_socket+0xae/0x240 net/socket.c:1712
__do_sys_socket net/socket.c:1726 [inline]
__se_sys_socket net/socket.c:1724 [inline]
__x64_sys_socket+0x3f/0x50 net/socket.c:1724
x64_sys_call+0x2c97/0x2d60 arch/x86/include/generated/asm/syscalls_64.h:42
do_syscall_x64 arch/x86/entry/common.c:52 [inline]
do_syscall_64+0xc9/0x1c0 arch/x86/entry/common.c:83
entry_SYSCALL_64_after_hwframe+0x77/0x7f

write to 0xffff888101db0b78 of 2 bytes by task 3250 on cpu 1:
virtqueue_disable_cb_split drivers/virtio/virtio_ring.c:886 [inline]
virtqueue_disable_cb+0x85/0x180 drivers/virtio/virtio_ring.c:2446
start_xmit+0x14b/0x1260 drivers/net/virtio_net.c:3061
__netdev_start_xmit include/linux/netdevice.h:4916 [inline]
netdev_start_xmit include/linux/netdevice.h:4925 [inline]
xmit_one net/core/dev.c:3588 [inline]
dev_hard_start_xmit+0x119/0x3f0 net/core/dev.c:3604
sch_direct_xmit+0x1a9/0x580 net/sched/sch_generic.c:343
__dev_xmit_skb net/core/dev.c:3817 [inline]
__dev_queue_xmit+0xf46/0x1fe0 net/core/dev.c:4390
dev_queue_xmit include/linux/netdevice.h:3094 [inline]
neigh_hh_output include/net/neighbour.h:526 [inline]
neigh_output include/net/neighbour.h:540 [inline]
ip_finish_output2+0x73d/0x8b0 net/ipv4/ip_output.c:236
ip_finish_output+0x11a/0x2a0 net/ipv4/ip_output.c:324
NF_HOOK_COND include/linux/netfilter.h:303 [inline]
ip_output+0xab/0x170 net/ipv4/ip_output.c:434
dst_output include/net/dst.h:450 [inline]
ip_local_out net/ipv4/ip_output.c:130 [inline]
__ip_queue_xmit+0xbcc/0xbf0 net/ipv4/ip_output.c:536
ip_queue_xmit+0x38/0x50 net/ipv4/ip_output.c:550
__tcp_transmit_skb+0x15b0/0x1970 net/ipv4/tcp_output.c:1466
tcp_transmit_skb net/ipv4/tcp_output.c:1484 [inline]
tcp_write_xmit+0x1410/0x3220 net/ipv4/tcp_output.c:2830
__tcp_push_pending_frames+0x6a/0x1a0 net/ipv4/tcp_output.c:3015
tcp_push+0x320/0x340 net/ipv4/tcp.c:750
tcp_sendmsg_locked+0x21ff/0x2700 net/ipv4/tcp.c:1325
tcp_sendmsg+0x30/0x50 net/ipv4/tcp.c:1357
inet_sendmsg+0x77/0xd0 net/ipv4/af_inet.c:853
sock_sendmsg_nosec net/socket.c:730 [inline]
__sock_sendmsg+0x102/0x180 net/socket.c:745
sock_write_iter+0x15e/0x1a0 net/socket.c:1166
new_sync_write fs/read_write.c:590 [inline]
vfs_write+0x76a/0x910 fs/read_write.c:683
ksys_write+0xeb/0x1b0 fs/read_write.c:736
__do_sys_write fs/read_write.c:748 [inline]
__se_sys_write fs/read_write.c:745 [inline]
__x64_sys_write+0x42/0x50 fs/read_write.c:745
x64_sys_call+0x27dd/0x2d60 arch/x86/include/generated/asm/syscalls_64.h:2
do_syscall_x64 arch/x86/entry/common.c:52 [inline]
do_syscall_64+0xc9/0x1c0 arch/x86/entry/common.c:83
entry_SYSCALL_64_after_hwframe+0x77/0x7f

value changed: 0x0000 -> 0x0001

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 UID: 0 PID: 3250 Comm: syz-executor Tainted: G W 6.11.0-syzkaller-07337-g2004cef11ea0 #0
Tainted: [W]=WARN
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 08/06/2024
==================================================================


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