XFS (loop3): Filesystem has been shut down due to log error (0x2).
XFS (loop3): Please unmount the filesystem and rectify the problem(s).
==================================================================
BUG: KASAN: use-after-free in xfs_trans_ail_delete+0x64/0x2b0 fs/xfs/xfs_trans_ail.c:875
Read of size 8 at addr ffff0000dda6d600 by task kworker/0:1H/51

CPU: 0 PID: 51 Comm: kworker/0:1H Not tainted 6.1.34-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/25/2023
Workqueue: xfs-log/loop3 xlog_ioend_work
Call trace:
 dump_backtrace+0x1c8/0x1f4 arch/arm64/kernel/stacktrace.c:158
 show_stack+0x2c/0x3c arch/arm64/kernel/stacktrace.c:165
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0x108/0x170 lib/dump_stack.c:106
 print_address_description mm/kasan/report.c:284 [inline]
 print_report+0x174/0x4c0 mm/kasan/report.c:395
 kasan_report+0xd4/0x130 mm/kasan/report.c:495
 __asan_report_load8_noabort+0x2c/0x38 mm/kasan/report_generic.c:351
 xfs_trans_ail_delete+0x64/0x2b0 fs/xfs/xfs_trans_ail.c:875
 xfs_buf_item_done+0x58/0x94 fs/xfs/xfs_buf_item.c:1042
 xfs_buf_ioend+0x2d4/0x78c fs/xfs/xfs_buf.c:1326
 xfs_buf_ioend_fail+0x78/0x90 fs/xfs/xfs_buf.c:1397
 xfs_buf_item_unpin+0x224/0x918 fs/xfs/xfs_buf_item.c:549
 xfs_trans_committed_bulk+0x2d8/0x73c fs/xfs/xfs_trans.c:806
 xlog_cil_committed+0x21c/0xd64 fs/xfs/xfs_log_cil.c:795
 xlog_cil_process_committed+0x11c/0x174 fs/xfs/xfs_log_cil.c:823
 xlog_state_shutdown_callbacks+0x23c/0x324 fs/xfs/xfs_log.c:538
 xlog_force_shutdown+0x29c/0x350 fs/xfs/xfs_log.c:3821
 xlog_ioend_work+0xa8/0xf8 fs/xfs/xfs_log.c:1402
 process_one_work+0x7ac/0x1404 kernel/workqueue.c:2289
 worker_thread+0x8e4/0xfec kernel/workqueue.c:2436
 kthread+0x250/0x2d8 kernel/kthread.c:376
 ret_from_fork+0x10/0x20 arch/arm64/kernel/entry.S:860

Allocated by task 20506:
 kasan_save_stack mm/kasan/common.c:45 [inline]
 kasan_set_track+0x4c/0x80 mm/kasan/common.c:52
 kasan_save_alloc_info+0x24/0x30 mm/kasan/generic.c:505
 ____kasan_kmalloc mm/kasan/common.c:374 [inline]
 __kasan_kmalloc+0xac/0xc4 mm/kasan/common.c:383
 kasan_kmalloc include/linux/kasan.h:211 [inline]
 __do_kmalloc_node mm/slab_common.c:955 [inline]
 __kmalloc+0xd8/0x1c4 mm/slab_common.c:968
 kmalloc include/linux/slab.h:558 [inline]
 kmem_alloc+0x1bc/0x518 fs/xfs/kmem.c:20
 kmem_zalloc fs/xfs/kmem.h:69 [inline]
 xfs_trans_ail_init+0x2c/0x220 fs/xfs/xfs_trans_ail.c:902
 xfs_log_mount+0x294/0x6e0 fs/xfs/xfs_log.c:721
 xfs_mountfs+0xa04/0x18fc fs/xfs/xfs_mount.c:805
 xfs_fs_fill_super+0xd38/0xf50 fs/xfs/xfs_super.c:1666
 get_tree_bdev+0x360/0x54c fs/super.c:1346
 xfs_fs_get_tree+0x28/0x38 fs/xfs/xfs_super.c:1713
 vfs_get_tree+0x90/0x274 fs/super.c:1553
 do_new_mount+0x25c/0x8c4 fs/namespace.c:3040
 path_mount+0x590/0xe58 fs/namespace.c:3370
 do_mount fs/namespace.c:3383 [inline]
 __do_sys_mount fs/namespace.c:3591 [inline]
 __se_sys_mount fs/namespace.c:3568 [inline]
 __arm64_sys_mount+0x45c/0x594 fs/namespace.c:3568
 __invoke_syscall arch/arm64/kernel/syscall.c:38 [inline]
 invoke_syscall+0x98/0x2c0 arch/arm64/kernel/syscall.c:52
 el0_svc_common+0x138/0x258 arch/arm64/kernel/syscall.c:142
 do_el0_svc+0x64/0x218 arch/arm64/kernel/syscall.c:206
 el0_svc+0x58/0x168 arch/arm64/kernel/entry-common.c:637
 el0t_64_sync_handler+0x84/0xf0 arch/arm64/kernel/entry-common.c:655
 el0t_64_sync+0x18c/0x190 arch/arm64/kernel/entry.S:581

Freed by task 4283:
 kasan_save_stack mm/kasan/common.c:45 [inline]
 kasan_set_track+0x4c/0x80 mm/kasan/common.c:52
 kasan_save_free_info+0x38/0x5c mm/kasan/generic.c:516
 ____kasan_slab_free+0x144/0x1c0 mm/kasan/common.c:236
 __kasan_slab_free+0x18/0x28 mm/kasan/common.c:244
 kasan_slab_free include/linux/kasan.h:177 [inline]
 slab_free_hook mm/slub.c:1724 [inline]
 slab_free_freelist_hook mm/slub.c:1750 [inline]
 slab_free mm/slub.c:3661 [inline]
 __kmem_cache_free+0x2c0/0x4b4 mm/slub.c:3674
 kfree+0xcc/0x1b8 mm/slab_common.c:1007
 kvfree+0x40/0x50 mm/util.c:627
 kmem_free fs/xfs/kmem.h:62 [inline]
 xfs_trans_ail_destroy+0x60/0x70 fs/xfs/xfs_trans_ail.c:933
 xfs_log_unmount+0x54/0xbc fs/xfs/xfs_log.c:1116
 xfs_unmountfs+0x130/0x1d0 fs/xfs/xfs_mount.c:1081
 xfs_fs_put_super+0x78/0x260 fs/xfs/xfs_super.c:1115
 generic_shutdown_super+0x130/0x328 fs/super.c:501
 kill_block_super+0x70/0xdc fs/super.c:1450
 deactivate_locked_super+0xac/0x124 fs/super.c:332
 deactivate_super+0xf0/0x110 fs/super.c:363
 cleanup_mnt+0x394/0x41c fs/namespace.c:1186
 __cleanup_mnt+0x20/0x30 fs/namespace.c:1193
 task_work_run+0x240/0x2f0 kernel/task_work.c:179
 resume_user_mode_work include/linux/resume_user_mode.h:49 [inline]
 do_notify_resume+0x2144/0x3470 arch/arm64/kernel/signal.c:1132
 prepare_exit_to_user_mode arch/arm64/kernel/entry-common.c:137 [inline]
 exit_to_user_mode arch/arm64/kernel/entry-common.c:142 [inline]
 el0_svc+0x9c/0x168 arch/arm64/kernel/entry-common.c:638
 el0t_64_sync_handler+0x84/0xf0 arch/arm64/kernel/entry-common.c:655
 el0t_64_sync+0x18c/0x190 arch/arm64/kernel/entry.S:581

Last potentially related work creation:
 kasan_save_stack+0x40/0x70 mm/kasan/common.c:45
 __kasan_record_aux_stack+0xcc/0xe8 mm/kasan/generic.c:486
 kasan_record_aux_stack_noalloc+0x14/0x20 mm/kasan/generic.c:496
 insert_work+0x64/0x384 kernel/workqueue.c:1358
 __queue_work+0xd48/0x136c kernel/workqueue.c:1517
 queue_work_on+0xc0/0x16c kernel/workqueue.c:1545
 queue_work include/linux/workqueue.h:503 [inline]
 xfs_pwork_queue+0x134/0x16c fs/xfs/xfs_pwork.c:97
 xfs_iwalk_threaded+0x2f8/0x584 fs/xfs/xfs_iwalk.c:680
 xfs_qm_quotacheck+0x224/0x58c fs/xfs/xfs_qm.c:1314
 xfs_qm_mount_quotas+0x2c4/0x590 fs/xfs/xfs_qm.c:1437
 xfs_mountfs+0x1368/0x18fc fs/xfs/xfs_mount.c:945
 xfs_fs_fill_super+0xd38/0xf50 fs/xfs/xfs_super.c:1666
 get_tree_bdev+0x360/0x54c fs/super.c:1346
 xfs_fs_get_tree+0x28/0x38 fs/xfs/xfs_super.c:1713
 vfs_get_tree+0x90/0x274 fs/super.c:1553
 do_new_mount+0x25c/0x8c4 fs/namespace.c:3040
 path_mount+0x590/0xe58 fs/namespace.c:3370
 do_mount fs/namespace.c:3383 [inline]
 __do_sys_mount fs/namespace.c:3591 [inline]
 __se_sys_mount fs/namespace.c:3568 [inline]
 __arm64_sys_mount+0x45c/0x594 fs/namespace.c:3568
 __invoke_syscall arch/arm64/kernel/syscall.c:38 [inline]
 invoke_syscall+0x98/0x2c0 arch/arm64/kernel/syscall.c:52
 el0_svc_common+0x138/0x258 arch/arm64/kernel/syscall.c:142
 do_el0_svc+0x64/0x218 arch/arm64/kernel/syscall.c:206
 el0_svc+0x58/0x168 arch/arm64/kernel/entry-common.c:637
 el0t_64_sync_handler+0x84/0xf0 arch/arm64/kernel/entry-common.c:655
 el0t_64_sync+0x18c/0x190 arch/arm64/kernel/entry.S:581

Second to last potentially related work creation:
 kasan_save_stack+0x40/0x70 mm/kasan/common.c:45
 __kasan_record_aux_stack+0xcc/0xe8 mm/kasan/generic.c:486
 kasan_record_aux_stack_noalloc+0x14/0x20 mm/kasan/generic.c:496
 kvfree_call_rcu+0xb4/0x714 kernel/rcu/tree.c:3344
 drop_sysctl_table+0x274/0x3a0 fs/proc/proc_sysctl.c:1729
 drop_sysctl_table+0x284/0x3a0 fs/proc/proc_sysctl.c:1732
 unregister_sysctl_table+0x90/0x12c fs/proc/proc_sysctl.c:1767
 retire_ipc_sysctls+0x60/0x84 ipc/ipc_sysctl.c:278
 free_ipc_ns ipc/namespace.c:142 [inline]
 free_ipc+0xb8/0x224 ipc/namespace.c:157
 process_one_work+0x7ac/0x1404 kernel/workqueue.c:2289
 worker_thread+0x8e4/0xfec kernel/workqueue.c:2436
 kthread+0x250/0x2d8 kernel/kthread.c:376
 ret_from_fork+0x10/0x20 arch/arm64/kernel/entry.S:860

The buggy address belongs to the object at ffff0000dda6d600
 which belongs to the cache kmalloc-256 of size 256
The buggy address is located 0 bytes inside of
 256-byte region [ffff0000dda6d600, ffff0000dda6d700)

The buggy address belongs to the physical page:
page:000000001db461c2 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x11da6c
head:000000001db461c2 order:1 compound_mapcount:0 compound_pincount:0
flags: 0x5ffc00000010200(slab|head|node=0|zone=2|lastcpupid=0x7ff)
raw: 05ffc00000010200 dead000000000100 dead000000000122 ffff0000c0002480
raw: 0000000000000000 0000000000100010 00000001ffffffff 0000000000000000
page dumped because: kasan: bad access detected

Memory state around the buggy address:
 ffff0000dda6d500: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
 ffff0000dda6d580: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
>ffff0000dda6d600: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
                   ^
 ffff0000dda6d680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
 ffff0000dda6d700: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
==================================================================
XFS (): xfs_trans_ail_delete: attempting to delete a log item that is not in the AIL
Unable to handle kernel paging request at virtual address 001e8f1f53005b31
Mem abort info:
  ESR = 0x0000000096000004
  EC = 0x25: DABT (current EL), IL = 32 bits
  SET = 0, FnV = 0
  EA = 0, S1PTW = 0
  FSC = 0x04: level 0 translation fault
Data abort info:
  ISV = 0, ISS = 0x00000004
  CM = 0, WnR = 0
[001e8f1f53005b31] address between user and kernel address ranges
Internal error: Oops: 0000000096000004 [#1] PREEMPT SMP
Modules linked in:
CPU: 0 PID: 51 Comm: kworker/0:1H Tainted: G    B              6.1.34-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/25/2023
Workqueue: xfs-log/loop3 xlog_ioend_work
pstate: 80400005 (Nzcv daif +PAN -UAO -TCO -DIT -SSBS BTYPE=--)
pc : xfs_log_force+0x174/0xa4c fs/xfs/xfs_log.c:3204
lr : xfs_log_force+0x14c/0xa4c fs/xfs/xfs_log.c:3204
sp : ffff80001b0d7310
x29: ffff80001b0d7310 x28: 0000000000000000 x27: ffff8000155c1130
x26: dfff800000000000 x25: ffff80001550f008 x24: f8f8f8f8f8f8f8f8
x23: f8f878fa9802d988 x22: 0000000000000000 x21: ffff800009c42888
x20: ffff0000c3b4fcb0 x19: 0000000000000001 x18: 1fffe000368b5f76
x17: 6874206d65746920 x16: ffff8000121062b4 x15: 0000000000000000
x14: 0000000000000000 x13: 0000000000000001 x12: 0000000000000001
x11: ff80800009c3cc5c x10: 0000000000000000 x9 : ffff800009c3cc5c
x8 : 1f1f0f1f53005b31 x7 : 0000000000000001 x6 : 0000000000000001
x5 : ffff80001b0d6bb8 x4 : ffff8000156a2a40 x3 : ffff800009c3cc24
x2 : 0000000000000000 x1 : 0000000000000000 x0 : 0000000000000008
Call trace:
 xfs_log_force+0x174/0xa4c fs/xfs/xfs_log.c:3204
 xlog_force_shutdown+0xac/0x350 fs/xfs/xfs_log.c:3765
 xfs_trans_ail_delete+0x124/0x2b0 fs/xfs/xfs_trans_ail.c:885
 xfs_buf_item_done+0x58/0x94 fs/xfs/xfs_buf_item.c:1042
 xfs_buf_ioend+0x2d4/0x78c fs/xfs/xfs_buf.c:1326
 xfs_buf_ioend_fail+0x78/0x90 fs/xfs/xfs_buf.c:1397
 xfs_buf_item_unpin+0x224/0x918 fs/xfs/xfs_buf_item.c:549
 xfs_trans_committed_bulk+0x2d8/0x73c fs/xfs/xfs_trans.c:806
 xlog_cil_committed+0x21c/0xd64 fs/xfs/xfs_log_cil.c:795
 xlog_cil_process_committed+0x11c/0x174 fs/xfs/xfs_log_cil.c:823
 xlog_state_shutdown_callbacks+0x23c/0x324 fs/xfs/xfs_log.c:538
 xlog_force_shutdown+0x29c/0x350 fs/xfs/xfs_log.c:3821
 xlog_ioend_work+0xa8/0xf8 fs/xfs/xfs_log.c:1402
 process_one_work+0x7ac/0x1404 kernel/workqueue.c:2289
 worker_thread+0x8e4/0xfec kernel/workqueue.c:2436
 kthread+0x250/0x2d8 kernel/kthread.c:376
 ret_from_fork+0x10/0x20 arch/arm64/kernel/entry.S:860
Code: f94002e8 8b180108 91024117 d343fee8 (38fa6908) 
---[ end trace 0000000000000000 ]---
----------------
Code disassembly (best guess):
   0:	f94002e8 	ldr	x8, [x23]
   4:	8b180108 	add	x8, x8, x24
   8:	91024117 	add	x23, x8, #0x90
   c:	d343fee8 	lsr	x8, x23, #3
* 10:	38fa6908 	ldrsb	w8, [x8, x26] <-- trapping instruction