Oops: general protection fault, probably for non-canonical address 0xdffffc00000000e6: 0000 [#1] SMP KASAN NOPTI
KASAN: null-ptr-deref in range [0x0000000000000730-0x0000000000000737]
CPU: 3 UID: 0 PID: 5144 Comm: udevd Tainted: G L syzkaller #0 PREEMPT(full)
Tainted: [L]=SOFTLOCKUP
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
RIP: 0010:f_midi2_free_ep_reqs+0x56/0x2b0 drivers/usb/gadget/function/f_midi2.c:1166
Code: 85 6a 02 00 00 49 8b 45 00 48 89 44 24 18 48 05 30 07 00 00 48 89 c2 48 89 44 24 20 48 b8 00 00 00 00 00 fc ff df 48 c1 ea 03 <0f> b6 04 02 84 c0 74 08 3c 03 0f 8e b5 01 00 00 48 8b 44 24 18 31
RSP: 0018:ffffc900006f89e8 EFLAGS: 00010002
RAX: dffffc0000000000 RBX: ffff88812eba8000 RCX: ffffffff87e73d89
RDX: 00000000000000e6 RSI: ffffffff87e73bc6 RDI: ffff88812eba8128
RBP: ffff88812eba8128 R08: 0000000000000004 R09: 0000000000000020
R10: 0000000000000020 R11: 0000000000000000 R12: ffff88812eba80f0
R13: ffff88812eba8128 R14: ffff88812eba8740 R15: 0000000000000001
FS: 00007f533df80880(0000) GS:ffff8880d60d8000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000000110c37d37c CR3: 000000003343f000 CR4: 0000000000352ef0
Call Trace:
f_midi2_stop_eps drivers/usb/gadget/function/f_midi2.c:1246 [inline]
f_midi2_set_alt+0x444/0x5f0 drivers/usb/gadget/function/f_midi2.c:1296
composite_setup+0x16f8/0x9290 drivers/usb/gadget/composite.c:1933
configfs_composite_setup+0xfb/0x130 drivers/usb/gadget/configfs.c:1877
dummy_timer+0x2045/0x36f0 drivers/usb/gadget/udc/dummy_hcd.c:1951
__run_hrtimer kernel/time/hrtimer.c:2032 [inline]
__hrtimer_run_queues+0x462/0x9c0 kernel/time/hrtimer.c:2096
hrtimer_run_softirq+0x17d/0x2c0 kernel/time/hrtimer.c:2113
handle_softirqs+0x1ea/0x9b0 kernel/softirq.c:622
__do_softirq kernel/softirq.c:656 [inline]
invoke_softirq kernel/softirq.c:496 [inline]
__irq_exit_rcu+0x162/0x210 kernel/softirq.c:735
irq_exit_rcu+0x9/0x30 kernel/softirq.c:752
instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1062 [inline]
sysvec_apic_timer_interrupt+0xa3/0xc0 arch/x86/kernel/apic/apic.c:1062
asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:674
RIP: 0010:trace_lock_release include/trace/events/lock.h:68 [inline]
RIP: 0010:lock_release+0x40/0x310 kernel/locking/lockdep.c:5879
Code: 2d 3d 86 7e 12 48 89 6c 24 10 48 89 f5 0f 1f 44 00 00 65 8b 05 55 86 7e 12 83 f8 07 0f 87 07 02 00 00 48 0f a3 05 e0 8c 3c 0f <0f> 82 02 02 00 00 44 8b 05 a7 c0 3c 0f 45 85 c0 0f 84 48 01 00 00
RSP: 0018:ffffc90003ab7550 EFLAGS: 00000297
RAX: 0000000000000003 RBX: ffffffff8ebe8200 RCX: ffffffff91d55201
RDX: 0000000000000000 RSI: ffffffff81b866be RDI: ffffffff8ebe8200
RBP: ffffffff81b866be R08: 0000000000000001 R09: 0000000000000007
R10: 0000000000000200 R11: 0000000000018f70 R12: ffffc90003ab7658
R13: ffffc90003ab7608 R14: ffffc90003ab7a80 R15: ffffc90003ab763c
rcu_lock_release include/linux/rcupdate.h:310 [inline]
rcu_read_unlock include/linux/rcupdate.h:871 [inline]
class_rcu_destructor include/linux/rcupdate.h:1183 [inline]
unwind_next_frame+0x3c3/0x2090 arch/x86/kernel/unwind_orc.c:495
arch_stack_walk+0x94/0xf0 arch/x86/kernel/stacktrace.c:25
stack_trace_save+0x8e/0xc0 kernel/stacktrace.c:122
kasan_save_stack+0x30/0x50 mm/kasan/common.c:57
kasan_save_track+0x14/0x30 mm/kasan/common.c:78
unpoison_slab_object mm/kasan/common.c:340 [inline]
__kasan_slab_alloc+0x89/0x90 mm/kasan/common.c:366
kasan_slab_alloc include/linux/kasan.h:253 [inline]
slab_post_alloc_hook mm/slub.c:4584 [inline]
slab_alloc_node mm/slub.c:4917 [inline]
kmem_cache_alloc_noprof+0x26b/0x6a0 mm/slub.c:4931
lsm_file_alloc security/security.c:171 [inline]
security_file_alloc+0x34/0x2c0 security/security.c:2406
init_file+0x95/0x480 fs/file_table.c:184
alloc_empty_file+0x79/0x1c0 fs/file_table.c:266
path_openat+0xe7/0x4280 fs/namei.c:4849
do_file_open+0x20e/0x430 fs/namei.c:4892
do_sys_openat2+0x10f/0x1e0 fs/open.c:1368
do_sys_open fs/open.c:1374 [inline]
__do_sys_openat fs/open.c:1390 [inline]
__se_sys_openat fs/open.c:1385 [inline]
__x64_sys_openat+0x12d/0x210 fs/open.c:1385
do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
do_syscall_64+0x115/0x870 arch/x86/entry/syscall_64.c:94
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f533d8a7407
Code: 48 89 fa 4c 89 df e8 38 aa 00 00 8b 93 08 03 00 00 59 5e 48 83 f8 fc 74 1a 5b c3 0f 1f 84 00 00 00 00 00 48 8b 44 24 10 0f 05 <5b> c3 0f 1f 80 00 00 00 00 83 e2 39 83 fa 08 75 de e8 23 ff ff ff
RSP: 002b:00007ffecacfd5e0 EFLAGS: 00000202 ORIG_RAX: 0000000000000101
RAX: ffffffffffffffda RBX: 00007f533df80880 RCX: 00007f533d8a7407
RDX: 0000000000080141 RSI: 000055b73aa6f02e RDI: ffffffffffffff9c
RBP: 0000000000000000 R08: 0000000000000000 R09: 0000000000000000
R10: 00000000000001a4 R11: 0000000000000202 R12: 00000000ffffffff
R13: 00000000ffffffff R14: ffffffffffffffff R15: 0000000000000000
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:f_midi2_free_ep_reqs+0x56/0x2b0 drivers/usb/gadget/function/f_midi2.c:1166
Code: 85 6a 02 00 00 49 8b 45 00 48 89 44 24 18 48 05 30 07 00 00 48 89 c2 48 89 44 24 20 48 b8 00 00 00 00 00 fc ff df 48 c1 ea 03 <0f> b6 04 02 84 c0 74 08 3c 03 0f 8e b5 01 00 00 48 8b 44 24 18 31
RSP: 0018:ffffc900006f89e8 EFLAGS: 00010002
RAX: dffffc0000000000 RBX: ffff88812eba8000 RCX: ffffffff87e73d89
RDX: 00000000000000e6 RSI: ffffffff87e73bc6 RDI: ffff88812eba8128
RBP: ffff88812eba8128 R08: 0000000000000004 R09: 0000000000000020
R10: 0000000000000020 R11: 0000000000000000 R12: ffff88812eba80f0
R13: ffff88812eba8128 R14: ffff88812eba8740 R15: 0000000000000001
FS: 00007f533df80880(0000) GS:ffff8880d60d8000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000000110c37d37c CR3: 000000003343f000 CR4: 0000000000352ef0
----------------
Code disassembly (best guess):
0: 85 6a 02 test %ebp,0x2(%rdx)
3: 00 00 add %al,(%rax)
5: 49 8b 45 00 mov 0x0(%r13),%rax
9: 48 89 44 24 18 mov %rax,0x18(%rsp)
e: 48 05 30 07 00 00 add $0x730,%rax
14: 48 89 c2 mov %rax,%rdx
17: 48 89 44 24 20 mov %rax,0x20(%rsp)
1c: 48 b8 00 00 00 00 00 movabs $0xdffffc0000000000,%rax
23: fc ff df
26: 48 c1 ea 03 shr $0x3,%rdx
* 2a: 0f b6 04 02 movzbl (%rdx,%rax,1),%eax <-- trapping instruction
2e: 84 c0 test %al,%al
30: 74 08 je 0x3a
32: 3c 03 cmp $0x3,%al
34: 0f 8e b5 01 00 00 jle 0x1ef
3a: 48 8b 44 24 18 mov 0x18(%rsp),%rax
3f: 31 .byte 0x31