------------[ cut here ]------------ WARNING: CPU: 1 PID: 6882 at drivers/gpu/drm/drm_prime.c:326 drm_gem_prime_fd_to_handle+0x503/0x590 drivers/gpu/drm/drm_prime.c:326 Modules linked in: CPU: 1 UID: 0 PID: 6882 Comm: syz-executor.4 Not tainted 6.12.0-rc4-syzkaller-g850925a8133c #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024 RIP: 0010:drm_gem_prime_fd_to_handle+0x503/0x590 drivers/gpu/drm/drm_prime.c:326 Code: e8 22 6d 26 fc 90 0f 0b 90 90 e9 28 fd ff ff e8 13 7c 65 fc 4c 89 ff 41 89 dc e8 78 52 fa 05 e9 5e fe ff ff e8 fe 7b 65 fc 90 <0f> 0b 90 e9 05 fd ff ff e8 b0 23 c6 fc e9 d1 fb ff ff e8 a6 23 c6 RSP: 0018:ffffc9000c65fc30 EFLAGS: 00010293 RAX: 0000000000000000 RBX: ffff888142b06800 RCX: ffffffff8527ffee RDX: ffff8880300dda00 RSI: ffffffff85280332 RDI: ffff888142b06928 RBP: ffff888024cb3800 R08: 0000000000000007 R09: fffffffffffff000 R10: ffff888142b06800 R11: 0000000000000000 R12: ffff88807b897000 R13: ffff888029885000 R14: ffffc9000c65fdf8 R15: ffff888024f54c58 FS: 00007f4307d3d6c0(0000) GS:ffff8880b8700000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007f921f101402 CR3: 000000007e148000 CR4: 0000000000350ef0 Call Trace: drm_prime_fd_to_handle_ioctl+0xd6/0x110 drivers/gpu/drm/drm_prime.c:375 drm_ioctl_kernel+0x1e9/0x3d0 drivers/gpu/drm/drm_ioctl.c:745 drm_ioctl+0x5d6/0xc00 drivers/gpu/drm/drm_ioctl.c:842 vfs_ioctl fs/ioctl.c:51 [inline] __do_sys_ioctl fs/ioctl.c:907 [inline] __se_sys_ioctl fs/ioctl.c:893 [inline] __x64_sys_ioctl+0x192/0x220 fs/ioctl.c:893 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0xcd/0x250 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7f430707cda9 Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 e1 20 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 b0 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007f4307d3d0c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 RAX: ffffffffffffffda RBX: 00007f43071abf80 RCX: 00007f430707cda9 RDX: 0000000020000000 RSI: 00000000c00c642e RDI: 0000000000000003 RBP: 00007f43070c947a R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 000000000000000b R14: 00007f43071abf80 R15: 00007fffa6cbd4a8