================================================================== BUG: KASAN: use-after-free in ext4_data_block_valid+0x276/0x2d0 fs/ext4/block_validity.c:211 Read of size 8 at addr ffff8801d59140f8 by task syz-executor5/1808 CPU: 1 PID: 1808 Comm: syz-executor5 Not tainted 4.14.81+ #6 Call Trace: __dump_stack lib/dump_stack.c:17 [inline] dump_stack+0xb9/0x11b lib/dump_stack.c:53 print_address_description+0x60/0x22b mm/kasan/report.c:252 kasan_report_error mm/kasan/report.c:351 [inline] kasan_report.cold.6+0x11b/0x2dd mm/kasan/report.c:409 ext4_data_block_valid+0x276/0x2d0 fs/ext4/block_validity.c:211 __check_block_validity.constprop.27+0xbc/0x200 fs/ext4/inode.c:402 ext4_map_blocks+0xc22/0x1560 fs/ext4/inode.c:592 ext4_getblk+0x31c/0x400 fs/ext4/inode.c:966 ext4_bread_batch+0x78/0x330 fs/ext4/inode.c:1036 ext4_find_entry+0x44c/0xcd0 fs/ext4/namei.c:1424 ext4_rmdir+0x190/0xad0 fs/ext4/namei.c:2926 vfs_rmdir2+0x21a/0x420 fs/namei.c:3901 do_rmdir+0x2f5/0x3a0 fs/namei.c:3967 do_syscall_64+0x19b/0x4b0 arch/x86/entry/common.c:289 entry_SYSCALL_64_after_hwframe+0x42/0xb7 RIP: 0033:0x4572d7 RSP: 002b:00007ffc4af5af08 EFLAGS: 00000207 ORIG_RAX: 0000000000000054 RAX: ffffffffffffffda RBX: 0000000000000065 RCX: 00000000004572d7 RDX: 0000000000000000 RSI: 000000000070d698 RDI: 00007ffc4af5c040 RBP: 00000000000021c6 R08: 0000000000000000 R09: 0000000000000001 R10: 000000000000000a R11: 0000000000000207 R12: 00007ffc4af5c040 R13: 0000000001448940 R14: 0000000000000000 R15: 0000000000000005 Allocated by task 1: save_stack mm/kasan/kasan.c:447 [inline] set_track mm/kasan/kasan.c:459 [inline] kasan_kmalloc.part.1+0x4f/0xd0 mm/kasan/kasan.c:551 slab_post_alloc_hook mm/slab.h:442 [inline] slab_alloc_node mm/slub.c:2723 [inline] slab_alloc mm/slub.c:2731 [inline] kmem_cache_alloc+0xe4/0x2b0 mm/slub.c:2736 add_system_zone+0x261/0x4d0 fs/ext4/block_validity.c:85 ext4_setup_system_zone+0x253/0x470 fs/ext4/block_validity.c:160 ext4_fill_super+0x706c/0xb6b0 fs/ext4/super.c:4309 mount_bdev+0x2ab/0x370 fs/super.c:1149 mount_fs+0x28f/0x31a fs/super.c:1255 vfs_kern_mount.part.9+0xce/0x4a0 fs/namespace.c:1056 vfs_kern_mount fs/namespace.c:1038 [inline] do_new_mount fs/namespace.c:2561 [inline] do_mount+0x404/0x26e0 fs/namespace.c:2891 SYSC_mount fs/namespace.c:3107 [inline] SyS_mount+0xe5/0x100 fs/namespace.c:3084 do_mount_root init/do_mounts.c:366 [inline] mount_block_root+0x378/0x727 init/do_mounts.c:395 prepare_namespace+0x1cf/0x20a init/do_mounts.c:600 kernel_init_freeable+0x382/0x39f init/main.c:1091 kernel_init+0xc/0x157 init/main.c:1000 ret_from_fork+0x3a/0x50 arch/x86/entry/entry_64.S:402 Freed by task 9987: (stack is not available) The buggy address belongs to the object at ffff8801d59140e0 which belongs to the cache ext4_system_zone of size 40 The buggy address is located 24 bytes inside of 40-byte region [ffff8801d59140e0, ffff8801d5914108) The buggy address belongs to the page: page:ffffea0007564500 count:1 mapcount:0 mapping: (null) index:0x0 flags: 0x4000000000000100(slab) raw: 4000000000000100 0000000000000000 0000000000000000 0000000180490049 raw: dead000000000100 dead000000000200 ffff8801d907c200 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8801d5913f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff8801d5914000: fb fb fb fb fb fc fc fb fb fb fb fb fc fc fb fb >ffff8801d5914080: fb fb fb fc fc fb fb fb fb fb fc fc fb fb fb fb ^ ffff8801d5914100: fb fc fc fb fb fb fb fb fc fc fb fb fb fb fb fc ffff8801d5914180: fc fb fb fb fb fb fc fc fb fb fb fb fb fc fc fb ================================================================== EXT4-fs (sda1): re-mounted. Opts: noblock_validity,