================================================================== BUG: KCSAN: data-race in detach_buf_split / virtqueue_add read to 0xffff888101443048 of 4 bytes by task 17596 on cpu 0: virtqueue_add_split drivers/virtio/virtio_ring.c:553 [inline] virtqueue_add+0x4b3/0x20e0 drivers/virtio/virtio_ring.c:2133 virtqueue_add_inbuf+0x53/0x80 drivers/virtio/virtio_ring.c:2212 request_entropy drivers/char/hw_random/virtio-rng.c:61 [inline] copy_data drivers/char/hw_random/virtio-rng.c:74 [inline] virtio_read+0x1c5/0x3f0 drivers/char/hw_random/virtio-rng.c:92 rng_get_data drivers/char/hw_random/core.c:197 [inline] rng_dev_read+0x1a7/0x5e0 drivers/char/hw_random/core.c:234 vfs_read+0x19f/0x5c0 fs/read_write.c:468 ksys_read+0xeb/0x1a0 fs/read_write.c:613 __do_sys_read fs/read_write.c:623 [inline] __se_sys_read fs/read_write.c:621 [inline] __x64_sys_read+0x42/0x50 fs/read_write.c:621 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x41/0xc0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd read-write to 0xffff888101443048 of 4 bytes by interrupt on cpu 1: detach_buf_split+0x2fc/0x570 drivers/virtio/virtio_ring.c:757 virtqueue_get_buf_ctx_split drivers/virtio/virtio_ring.c:835 [inline] virtqueue_get_buf_ctx+0x3c2/0x5b0 drivers/virtio/virtio_ring.c:2327 virtqueue_get_buf+0x1f/0x30 drivers/virtio/virtio_ring.c:2333 random_recv_done+0x4c/0x90 drivers/char/hw_random/virtio-rng.c:42 vring_interrupt+0x150/0x170 drivers/virtio/virtio_ring.c:2501 __handle_irq_event_percpu+0x91/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+0x167/0x590 kernel/irq/chip.c:819 generic_handle_irq_desc include/linux/irqdesc.h:158 [inline] handle_irq arch/x86/kernel/irq.c:231 [inline] __common_interrupt+0x3c/0xb0 arch/x86/kernel/irq.c:250 common_interrupt+0x7a/0x90 arch/x86/kernel/irq.c:240 asm_common_interrupt+0x26/0x40 arch/x86/include/asm/idtentry.h:636 netif_is_bridge_port include/linux/netdevice.h:5103 [inline] rtnl_fdb_dump+0x4a3/0xa20 net/core/rtnetlink.c:4618 netlink_dump+0x381/0x710 net/netlink/af_netlink.c:2268 __netlink_dump_start+0x3ed/0x4d0 net/netlink/af_netlink.c:2373 netlink_dump_start include/linux/netlink.h:329 [inline] rtnetlink_rcv_msg+0x70f/0x8c0 net/core/rtnetlink.c:6373 netlink_rcv_skb+0x126/0x220 net/netlink/af_netlink.c:2546 rtnetlink_rcv+0x1c/0x20 net/core/rtnetlink.c:6435 netlink_unicast_kernel net/netlink/af_netlink.c:1339 [inline] netlink_unicast+0x56f/0x640 net/netlink/af_netlink.c:1365 netlink_sendmsg+0x665/0x770 net/netlink/af_netlink.c:1913 sock_sendmsg_nosec net/socket.c:724 [inline] sock_sendmsg net/socket.c:747 [inline] ____sys_sendmsg+0x375/0x4c0 net/socket.c:2503 ___sys_sendmsg net/socket.c:2557 [inline] __sys_sendmsg+0x1e9/0x270 net/socket.c:2586 __do_sys_sendmsg net/socket.c:2595 [inline] __se_sys_sendmsg net/socket.c:2593 [inline] __x64_sys_sendmsg+0x46/0x50 net/socket.c:2593 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x41/0xc0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd value changed: 0x00000001 -> 0x00000002 Reported by Kernel Concurrency Sanitizer on: CPU: 1 PID: 17607 Comm: syz-executor.0 Tainted: G W 6.4.0-syzkaller-00082-gc0a572d9d32f #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/27/2023 ==================================================================