================================================================== BUG: KASAN: use-after-free in constant_test_bit arch/x86/include/asm/bitops.h:325 [inline] BUG: KASAN: use-after-free in work_is_static_object+0x31/0x40 kernel/workqueue.c:443 Read of size 8 at addr ffff8801c96dd8e0 by task kworker/0:0/3 CPU: 0 PID: 3 Comm: kworker/0:0 Not tainted 4.15.0-rc1-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Workqueue: events p9_poll_workfn Call Trace: __dump_stack lib/dump_stack.c:17 [inline] dump_stack+0x145/0x1e7 lib/dump_stack.c:53 print_address_description+0x6c/0x20b mm/kasan/report.c:252 kasan_report_error mm/kasan/report.c:351 [inline] kasan_report.cold.7+0x11a/0x2d3 mm/kasan/report.c:409 __asan_report_load8_noabort+0x14/0x20 mm/kasan/report.c:430 constant_test_bit arch/x86/include/asm/bitops.h:325 [inline] work_is_static_object+0x31/0x40 kernel/workqueue.c:443 debug_object_activate+0x2bd/0x5c0 lib/debugobjects.c:470 debug_work_activate kernel/workqueue.c:492 [inline] __queue_work+0x18b/0x11d0 kernel/workqueue.c:1381 queue_work_on+0x146/0x180 kernel/workqueue.c:1487 queue_work include/linux/workqueue.h:488 [inline] schedule_work include/linux/workqueue.h:546 [inline] p9_poll_mux net/9p/trans_fd.c:638 [inline] p9_poll_workfn+0x493/0x740 net/9p/trans_fd.c:1118 process_one_work+0x9c9/0x1a40 kernel/workqueue.c:2112 worker_thread+0x215/0x1a30 kernel/workqueue.c:2246 kthread+0x355/0x410 kernel/kthread.c:238 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:441 Allocated by task 10435: save_stack+0x43/0xd0 mm/kasan/kasan.c:447 set_track mm/kasan/kasan.c:459 [inline] kasan_kmalloc+0xc4/0xe0 mm/kasan/kasan.c:551 kmem_cache_alloc_trace+0x152/0x780 mm/slab.c:3613 kmalloc include/linux/slab.h:499 [inline] kzalloc include/linux/slab.h:688 [inline] p9_fd_open net/9p/trans_fd.c:806 [inline] p9_fd_create+0x165/0x380 net/9p/trans_fd.c:1047 p9_client_create+0x78e/0x1343 net/9p/client.c:1060 v9fs_session_init+0x1ee/0x1820 fs/9p/v9fs.c:401 v9fs_mount+0x73/0x7a0 fs/9p/vfs_super.c:135 mount_fs+0x7f/0x2a9 fs/super.c:1219 vfs_kern_mount.part.34+0xbf/0x5c0 fs/namespace.c:1037 vfs_kern_mount fs/namespace.c:1027 [inline] do_new_mount fs/namespace.c:2512 [inline] do_mount+0x38b/0x2f30 fs/namespace.c:2841 SYSC_mount fs/namespace.c:3057 [inline] SyS_mount+0xb8/0xd0 fs/namespace.c:3034 entry_SYSCALL_64_fastpath+0x23/0x9a Freed by task 10435: save_stack+0x43/0xd0 mm/kasan/kasan.c:447 set_track mm/kasan/kasan.c:459 [inline] kasan_slab_free+0x71/0xc0 mm/kasan/kasan.c:524 __cache_free mm/slab.c:3491 [inline] kfree+0xd6/0x250 mm/slab.c:3806 p9_fd_close+0x3ac/0x5b0 net/9p/trans_fd.c:904 p9_client_create+0x8e2/0x1343 net/9p/client.c:1074 v9fs_session_init+0x1ee/0x1820 fs/9p/v9fs.c:401 v9fs_mount+0x73/0x7a0 fs/9p/vfs_super.c:135 mount_fs+0x7f/0x2a9 fs/super.c:1219 vfs_kern_mount.part.34+0xbf/0x5c0 fs/namespace.c:1037 vfs_kern_mount fs/namespace.c:1027 [inline] do_new_mount fs/namespace.c:2512 [inline] do_mount+0x38b/0x2f30 fs/namespace.c:2841 SYSC_mount fs/namespace.c:3057 [inline] SyS_mount+0xb8/0xd0 fs/namespace.c:3034 entry_SYSCALL_64_fastpath+0x23/0x9a The buggy address belongs to the object at ffff8801c96dd7c0 which belongs to the cache kmalloc-512 of size 512 The buggy address is located 288 bytes inside of 512-byte region [ffff8801c96dd7c0, ffff8801c96dd9c0) The buggy address belongs to the page: page:ffffea000725b740 count:1 mapcount:0 mapping:ffff8801c96dd040 index:0x0 flags: 0x2fffc0000000100(slab) raw: 02fffc0000000100 ffff8801c96dd040 0000000000000000 0000000100000006 raw: ffffea000705ffe0 ffffea000731d960 ffff8801da800940 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8801c96dd780: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb ffff8801c96dd800: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb >ffff8801c96dd880: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff8801c96dd900: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff8801c96dd980: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc ==================================================================