==================================================================
BUG: KASAN: use-after-free in list_empty include/linux/list.h:282 [inline]
BUG: KASAN: use-after-free in waitqueue_active include/linux/wait.h:127 [inline]
BUG: KASAN: use-after-free in wq_has_sleeper include/linux/wait.h:161 [inline]
BUG: KASAN: use-after-free in skwq_has_sleeper include/net/sock.h:2143 [inline]
BUG: KASAN: use-after-free in sock_def_write_space+0x609/0x630 net/core/sock.c:2917
Read of size 8 at addr ffff88804e9e0080 by task kworker/0:8/9601
CPU: 0 PID: 9601 Comm: kworker/0:8 Not tainted 5.8.0-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Workqueue: 0x0 (events)
Call Trace:
__dump_stack lib/dump_stack.c:77 [inline]
dump_stack+0x18f/0x20d lib/dump_stack.c:118
print_address_description.constprop.0.cold+0xae/0x436 mm/kasan/report.c:383
__kasan_report mm/kasan/report.c:513 [inline]
kasan_report.cold+0x1f/0x37 mm/kasan/report.c:530
list_empty include/linux/list.h:282 [inline]
waitqueue_active include/linux/wait.h:127 [inline]
wq_has_sleeper include/linux/wait.h:161 [inline]
skwq_has_sleeper include/net/sock.h:2143 [inline]
sock_def_write_space+0x609/0x630 net/core/sock.c:2917
sock_wfree+0x1cc/0x240 net/core/sock.c:2044
skb_release_head_state+0x9f/0x250 net/core/skbuff.c:651
skb_release_all net/core/skbuff.c:662 [inline]
_kfree_skb_defer net/core/skbuff.c:872 [inline]
napi_consume_skb net/core/skbuff.c:917 [inline]
napi_consume_skb+0x12e/0x370 net/core/skbuff.c:894
free_old_xmit_skbs+0xd5/0x230 drivers/net/virtio_net.c:1389
virtnet_poll_tx+0x1e9/0x370 drivers/net/virtio_net.c:1516
napi_poll net/core/dev.c:6687 [inline]
net_rx_action+0x4a1/0xe80 net/core/dev.c:6757
__do_softirq+0x2de/0xa24 kernel/softirq.c:298
asm_call_on_stack+0xf/0x20 arch/x86/entry/entry_64.S:706
__run_on_irqstack arch/x86/include/asm/irq_stack.h:22 [inline]
run_on_irqstack_cond arch/x86/include/asm/irq_stack.h:48 [inline]
do_softirq_own_stack+0x9d/0xd0 arch/x86/kernel/irq_64.c:77
invoke_softirq kernel/softirq.c:393 [inline]
__irq_exit_rcu kernel/softirq.c:423 [inline]
irq_exit_rcu+0x1f3/0x230 kernel/softirq.c:435
common_interrupt+0xa3/0x1f0 arch/x86/kernel/irq.c:239
asm_common_interrupt+0x1e/0x40 arch/x86/include/asm/idtentry.h:572
RIP: 0010:__raw_spin_unlock_irq include/linux/spinlock_api_smp.h:169 [inline]
RIP: 0010:_raw_spin_unlock_irq+0x4b/0x80 kernel/locking/spinlock.c:199
Code: c0 18 3b b6 89 48 ba 00 00 00 00 00 fc ff df 48 c1 e8 03 80 3c 10 00 75 31 48 83 3d b6 9d c4 01 00 74 25 fb 66 0f 1f 44 00 00 01 00 00 00 e8 9b fc 5d f9 65 8b 05 44 61 10 78 85 c0 74 02 5d
RSP: 0018:ffffc900042dfce0 EFLAGS: 00000282
RAX: 1ffffffff136c763 RBX: ffff88805dc7e540 RCX: 1ffffffff15622f1
RDX: dffffc0000000000 RSI: 0000000000000000 RDI: ffffffff87f19d3f
RBP: ffff8880ae635e40 R08: 0000000000000001 R09: 0000000000000001
R10: 0000000000000000 R11: 0000000000000000 R12: ffff8880ae635e40
R13: ffff8880694aa040 R14: 0000000000000000 R15: 0000000000000000
finish_lock_switch kernel/sched/core.c:3517 [inline]
finish_task_switch+0x147/0x750 kernel/sched/core.c:3617
context_switch kernel/sched/core.c:3781 [inline]
__schedule+0x8ed/0x21e0 kernel/sched/core.c:4527
schedule+0xd0/0x2a0 kernel/sched/core.c:4602
worker_thread+0x14c/0x1120 kernel/workqueue.c:2436
kthread+0x3b5/0x4a0 kernel/kthread.c:292
ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:294
Allocated by task 20194:
save_stack+0x1b/0x40 mm/kasan/common.c:48
set_track mm/kasan/common.c:56 [inline]
__kasan_kmalloc.constprop.0+0xc2/0xd0 mm/kasan/common.c:494
slab_post_alloc_hook mm/slab.h:586 [inline]
slab_alloc mm/slab.c:3320 [inline]
kmem_cache_alloc+0x12c/0x3b0 mm/slab.c:3484
sock_alloc_inode+0x18/0x1c0 net/socket.c:253
alloc_inode+0x61/0x230 fs/inode.c:232
new_inode_pseudo+0x14/0xe0 fs/inode.c:928
sock_alloc+0x3c/0x260 net/socket.c:573
__sock_create+0xb9/0x740 net/socket.c:1391
sock_create net/socket.c:1478 [inline]
__sys_socket+0xef/0x200 net/socket.c:1520
__do_sys_socket net/socket.c:1529 [inline]
__se_sys_socket net/socket.c:1527 [inline]
__x64_sys_socket+0x6f/0xb0 net/socket.c:1527
do_syscall_64+0x2d/0x70 arch/x86/entry/common.c:46
entry_SYSCALL_64_after_hwframe+0x44/0xa9
Freed by task 7061:
save_stack+0x1b/0x40 mm/kasan/common.c:48
set_track mm/kasan/common.c:56 [inline]
kasan_set_free_info mm/kasan/common.c:316 [inline]
__kasan_slab_free+0xf5/0x140 mm/kasan/common.c:455
__cache_free mm/slab.c:3426 [inline]
kmem_cache_free+0x7f/0x310 mm/slab.c:3694
i_callback+0x3f/0x70 fs/inode.c:221
rcu_do_batch kernel/rcu/tree.c:2427 [inline]
rcu_core+0x5c7/0x1190 kernel/rcu/tree.c:2655
__do_softirq+0x2de/0xa24 kernel/softirq.c:298
The buggy address belongs to the object at ffff88804e9e0000
which belongs to the cache sock_inode_cache of size 1216
The buggy address is located 128 bytes inside of
1216-byte region [ffff88804e9e0000, ffff88804e9e04c0)
The buggy address belongs to the page:
page:ffffea00013a7800 refcount:1 mapcount:0 mapping:0000000000000000 index:0xffff88804e9e0ffd
flags: 0xfffe0000000200(slab)
raw: 00fffe0000000200 ffffea0001694588 ffffea0001692888 ffff88821b77f8c0
raw: ffff88804e9e0ffd ffff88804e9e0000 0000000100000003 0000000000000000
page dumped because: kasan: bad access detected
Memory state around the buggy address:
ffff88804e9dff80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
ffff88804e9e0000: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
>ffff88804e9e0080: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
^
ffff88804e9e0100: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
ffff88804e9e0180: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
==================================================================