loop5: detected capacity change from 0 to 2048 ================================================================== BUG: KCSAN: data-race in data_push_tail / string write to 0xffffffff86eae097 of 1 bytes by task 5030 on cpu 0: string_nocheck lib/vsprintf.c:650 [inline] string+0x16c/0x200 lib/vsprintf.c:728 vsnprintf+0xa09/0xe20 lib/vsprintf.c:2819 vscnprintf+0x42/0x80 lib/vsprintf.c:2925 printk_sprint+0x30/0x2d0 kernel/printk/printk.c:2124 vprintk_store+0x56f/0x800 kernel/printk/printk.c:2238 vprintk_emit+0xd0/0x5d0 kernel/printk/printk.c:2284 vprintk_default+0x26/0x30 kernel/printk/printk.c:2318 vprintk+0x71/0x80 kernel/printk/printk_safe.c:45 _printk+0x7a/0xa0 kernel/printk/printk.c:2328 dump_stack_print_info+0xb4/0x120 lib/dump_stack.c:57 __dump_stack lib/dump_stack.c:87 [inline] dump_stack_lvl+0xce/0x130 lib/dump_stack.c:106 dump_stack+0x15/0x20 lib/dump_stack.c:113 fail_dump lib/fault-inject.c:52 [inline] should_fail_ex+0x21f/0x230 lib/fault-inject.c:153 __should_failslab+0x92/0xa0 mm/failslab.c:44 should_failslab+0x9/0x20 mm/slab_common.c:1493 slab_pre_alloc_hook mm/slab.h:712 [inline] slab_alloc_node mm/slub.c:3460 [inline] slab_alloc mm/slub.c:3486 [inline] __kmem_cache_alloc_lru mm/slub.c:3493 [inline] kmem_cache_alloc+0x4e/0x250 mm/slub.c:3502 kmem_cache_zalloc include/linux/slab.h:711 [inline] wg_peer_create+0x75/0x410 drivers/net/wireguard/peer.c:33 set_peer drivers/net/wireguard/netlink.c:412 [inline] wg_set_device+0xb1d/0x1220 drivers/net/wireguard/netlink.c:592 genl_family_rcv_msg_doit net/netlink/genetlink.c:972 [inline] genl_family_rcv_msg net/netlink/genetlink.c:1052 [inline] genl_rcv_msg+0x627/0x6c0 net/netlink/genetlink.c:1067 netlink_rcv_skb+0x126/0x220 net/netlink/af_netlink.c:2545 genl_rcv+0x28/0x40 net/netlink/genetlink.c:1076 netlink_unicast_kernel net/netlink/af_netlink.c:1342 [inline] netlink_unicast+0x589/0x650 net/netlink/af_netlink.c:1368 netlink_sendmsg+0x66e/0x770 net/netlink/af_netlink.c:1910 sock_sendmsg_nosec net/socket.c:730 [inline] __sock_sendmsg net/socket.c:745 [inline] ____sys_sendmsg+0x37c/0x4d0 net/socket.c:2584 ___sys_sendmsg net/socket.c:2638 [inline] __sys_sendmsg+0x1e9/0x270 net/socket.c:2667 __do_sys_sendmsg net/socket.c:2676 [inline] __se_sys_sendmsg net/socket.c:2674 [inline] __x64_sys_sendmsg+0x46/0x50 net/socket.c:2674 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0x44/0x110 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x63/0x6b read to 0xffffffff86eae090 of 8 bytes by task 5029 on cpu 1: data_make_reusable kernel/printk/printk_ringbuffer.c:590 [inline] data_push_tail+0x102/0x430 kernel/printk/printk_ringbuffer.c:675 data_alloc+0xbe/0x2c0 kernel/printk/printk_ringbuffer.c:1046 prb_reserve+0x893/0xbc0 kernel/printk/printk_ringbuffer.c:1555 vprintk_store+0x53e/0x800 kernel/printk/printk.c:2228 vprintk_emit+0xd0/0x5d0 kernel/printk/printk.c:2284 vprintk_default+0x26/0x30 kernel/printk/printk.c:2318 vprintk+0x71/0x80 kernel/printk/printk_safe.c:45 _printk+0x7a/0xa0 kernel/printk/printk.c:2328 set_capacity_and_notify+0x11d/0x170 block/genhd.c:86 loop_set_size+0x2e/0x70 drivers/block/loop.c:237 loop_configure+0xaf9/0xca0 drivers/block/loop.c:1100 lo_ioctl+0x682/0x12e0 blkdev_ioctl+0x375/0x460 block/ioctl.c:633 vfs_ioctl fs/ioctl.c:51 [inline] __do_sys_ioctl fs/ioctl.c:871 [inline] __se_sys_ioctl+0xcf/0x140 fs/ioctl.c:857 __x64_sys_ioctl+0x43/0x50 fs/ioctl.c:857 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0x44/0x110 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x63/0x6b value changed: 0x0000000100004831 -> 0x00203a6d6d6f4320 Reported by Kernel Concurrency Sanitizer on: CPU: 1 PID: 5029 Comm: syz-executor.5 Not tainted 6.7.0-rc5-syzkaller-00042-g88035e5694a8 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 11/10/2023 ==================================================================