loop0: detected capacity change from 0 to 32768 BUG at fs/jfs/jfs_dmap.c:2958 assert(n < 4) ------------[ cut here ]------------ kernel BUG at fs/jfs/jfs_dmap.c:2958! invalid opcode: 0000 [#1] PREEMPT SMP KASAN CPU: 1 PID: 3543 Comm: syz-executor230 Not tainted 6.1.51-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/26/2023 RIP: 0010:dbFindLeaf+0x41f/0x430 fs/jfs/jfs_dmap.c:2958 Code: e7 a9 dc fe eb 89 e8 40 0c 86 fe 48 c7 c7 e0 4e 24 8b 48 c7 c6 20 4c 24 8b ba 8e 0b 00 00 48 c7 c1 a0 59 24 8b e8 2a 23 7f 07 <0f> 0b 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 55 41 57 41 56 RSP: 0018:ffffc90003a1f978 EFLAGS: 00010246 RAX: 000000000000002b RBX: 0000000000000020 RCX: d9cd63f5e3689700 RDX: 0000000000000000 RSI: 0000000080000000 RDI: 0000000000000000 RBP: 00000000ffffffff R08: ffffffff816db5ec R09: fffff52000743ee9 R10: 0000000000000000 R11: dffffc0000000001 R12: ffff888079f9e010 R13: 000000000000000a R14: ffff888079f9e041 R15: 000000000000001d FS: 0000555556a45380(0000) GS:ffff8880b9900000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 000055675ee90000 CR3: 00000000267de000 CR4: 00000000003506e0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: dbAllocDmapLev+0xcd/0x490 fs/jfs/jfs_dmap.c:1959 dbAllocCtl+0x113/0x920 fs/jfs/jfs_dmap.c:1815 dbAllocAG+0x28b/0x10b0 fs/jfs/jfs_dmap.c:1356 dbDiscardAG+0x34e/0xa10 fs/jfs/jfs_dmap.c:1605 jfs_ioc_trim+0x42f/0x660 fs/jfs/jfs_discard.c:100 jfs_ioctl+0x2cc/0x3e0 fs/jfs/ioctl.c:131 vfs_ioctl fs/ioctl.c:51 [inline] __do_sys_ioctl fs/ioctl.c:870 [inline] __se_sys_ioctl+0xf1/0x160 fs/ioctl.c:856 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd RIP: 0033:0x7f0abc4ac6f9 Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 61 17 00 00 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007ffee1f14f68 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 RAX: ffffffffffffffda RBX: 00007ffee1f15138 RCX: 00007f0abc4ac6f9 RDX: 0000000020000080 RSI: 00000000c0185879 RDI: 0000000000000004 RBP: 00007f0abc525610 R08: 0000000000000000 R09: 00007ffee1f15138 R10: 00007f0abc4e7ab3 R11: 0000000000000246 R12: 0000000000000001 R13: 00007ffee1f15128 R14: 0000000000000001 R15: 0000000000000001 Modules linked in: ---[ end trace 0000000000000000 ]--- RIP: 0010:dbFindLeaf+0x41f/0x430 fs/jfs/jfs_dmap.c:2958 Code: e7 a9 dc fe eb 89 e8 40 0c 86 fe 48 c7 c7 e0 4e 24 8b 48 c7 c6 20 4c 24 8b ba 8e 0b 00 00 48 c7 c1 a0 59 24 8b e8 2a 23 7f 07 <0f> 0b 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 55 41 57 41 56 RSP: 0018:ffffc90003a1f978 EFLAGS: 00010246 RAX: 000000000000002b RBX: 0000000000000020 RCX: d9cd63f5e3689700 RDX: 0000000000000000 RSI: 0000000080000000 RDI: 0000000000000000 RBP: 00000000ffffffff R08: ffffffff816db5ec R09: fffff52000743ee9 R10: 0000000000000000 R11: dffffc0000000001 R12: ffff888079f9e010 R13: 000000000000000a R14: ffff888079f9e041 R15: 000000000000001d FS: 0000555556a45380(0000) GS:ffff8880b9900000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 000055675ee90000 CR3: 00000000267de000 CR4: 00000000003506e0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400