BUG: KASAN: use-after-free in __lock_acquire+0x3c9f/0x3d50 kernel/locking/lockdep.c:3368 Read of size 8 at addr ffff8801cbe553e8 by task syz-executor0/6324 CPU: 1 PID: 6324 Comm: syz-executor0 Not tainted 4.14.0-rc5+ #139 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:16 [inline] dump_stack+0x194/0x257 lib/dump_stack.c:52 print_address_description+0x73/0x250 mm/kasan/report.c:252 kasan_report_error mm/kasan/report.c:351 [inline] kasan_report+0x25b/0x340 mm/kasan/report.c:409 __asan_report_load8_noabort+0x14/0x20 mm/kasan/report.c:430 __lock_acquire+0x3c9f/0x3d50 kernel/locking/lockdep.c:3368 lock_acquire+0x1d5/0x580 kernel/locking/lockdep.c:3994 __raw_spin_lock_irq include/linux/spinlock_api_smp.h:128 [inline] _raw_spin_lock_irq+0x5e/0x80 kernel/locking/spinlock.c:167 exit_pi_state_list+0x369/0x7a0 kernel/futex.c:914 mm_release+0x46d/0x590 kernel/fork.c:1148 exit_mm kernel/exit.c:499 [inline] do_exit+0x481/0x1ad0 kernel/exit.c:852 do_group_exit+0x149/0x400 kernel/exit.c:968 get_signal+0x73f/0x16d0 kernel/signal.c:2334 do_signal+0x94/0x1ee0 arch/x86/kernel/signal.c:808 exit_to_usermode_loop+0x214/0x310 arch/x86/entry/common.c:158 prepare_exit_to_usermode arch/x86/entry/common.c:197 [inline] syscall_return_slowpath+0x42f/0x510 arch/x86/entry/common.c:266 entry_SYSCALL_64_fastpath+0xbc/0xbe RIP: 0033:0x452719 RSP: 002b:00007fc22b45abe8 EFLAGS: 00000212 ORIG_RAX: 0000000000000009 RAX: fffffffffffffff7 RBX: 0000000000758190 RCX: 0000000000452719 RDX: 0000000000000003 RSI: 0000000000001000 RDI: 0000000020fd6000 RBP: 00000000000003d9 R08: ffffffffffffffff R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000212 R12: 00000000006f3cf8 R13: 00000000ffffffff R14: 00007fc22b45b6d4 R15: 0000000000000005 Allocated by task 6325: save_stack_trace+0x16/0x20 arch/x86/kernel/stacktrace.c:59 save_stack+0x43/0xd0 mm/kasan/kasan.c:447 set_track mm/kasan/kasan.c:459 [inline] kasan_kmalloc+0xad/0xe0 mm/kasan/kasan.c:551 kmem_cache_alloc_trace+0x136/0x750 mm/slab.c:3627 kmalloc include/linux/slab.h:493 [inline] kzalloc include/linux/slab.h:666 [inline] refill_pi_state_cache.part.6+0xa5/0x2f0 kernel/futex.c:790 refill_pi_state_cache kernel/futex.c:1810 [inline] futex_requeue+0x1887/0x2370 kernel/futex.c:1877 do_futex+0x7f5/0x20d0 kernel/futex.c:3488 SYSC_futex kernel/futex.c:3526 [inline] SyS_futex+0x260/0x390 kernel/futex.c:3494 entry_SYSCALL_64_fastpath+0x1f/0xbe Freed by task 6323: save_stack_trace+0x16/0x20 arch/x86/kernel/stacktrace.c:59 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:3503 [inline] kfree+0xca/0x250 mm/slab.c:3820 put_pi_state+0x3f4/0x560 kernel/futex.c:852 unqueue_me_pi+0x4a/0xc0 kernel/futex.c:2266 futex_wait_requeue_pi.constprop.19+0xc7f/0x1300 kernel/futex.c:3185 do_futex+0x825/0x20d0 kernel/futex.c:3485 SYSC_futex kernel/futex.c:3526 [inline] SyS_futex+0x260/0x390 kernel/futex.c:3494 entry_SYSCALL_64_fastpath+0x1f/0xbe The buggy address belongs to the object at ffff8801cbe553c0 which belongs to the cache kmalloc-256 of size 256 The buggy address is located 40 bytes inside of 256-byte region [ffff8801cbe553c0, ffff8801cbe554c0) The buggy address belongs to the page: page:ffffea00072f9540 count:1 mapcount:0 mapping:ffff8801cbe55000 index:0x0 flags: 0x200000000000100(slab) raw: 0200000000000100 ffff8801cbe55000 0000000000000000 000000010000000c raw: ffffea00072ebca0 ffffea00072d0560 ffff8801dac007c0 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8801cbe55280: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff8801cbe55300: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb >ffff8801cbe55380: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb ^ ffff8801cbe55400: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff8801cbe55480: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc ==================================================================