------------[ cut here ]------------
usb_ep_enable: ep129 (ep1in-bulk) has maxpacket 0
WARNING: drivers/usb/gadget/udc/core.c:124 at usb_ep_enable+0x3e6/0x490 drivers/usb/gadget/udc/core.c:124, CPU#2: syz.3.147/6426
Modules linked in:
CPU: 2 UID: 0 PID: 6426 Comm: syz.3.147 Not tainted syzkaller #0 PREEMPT(full)
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
RIP: 0010:usb_ep_enable+0x3f8/0x490 drivers/usb/gadget/udc/core.c:124
Code: 48 89 fa 48 c1 ea 03 80 3c 02 00 0f 85 93 00 00 00 48 8d 3d 0a 4a 84 0a 48 8b 4b 08 40 0f b6 d5 4d 89 e0 48 c7 c6 00 b7 fb 8c <67> 48 0f b9 3a bd ea ff ff ff e9 8e fd ff ff 49 c7 c4 a0 a9 fb 8c
RSP: 0018:ffffc90000648a10 EFLAGS: 00010046
RAX: dffffc0000000000 RBX: ffff88802c9ec0e0 RCX: ffffffff8cfbee00
RDX: 0000000000000081 RSI: ffffffff8cfbb700 RDI: ffffffff92780070
RBP: 0000000000000081 R08: ffffffff8cfba9e0 R09: 0000000000000000
R10: ffffffff926aa25f R11: 0000000000000002 R12: ffffffff8cfba9e0
R13: 0000000000000000 R14: ffff88802c9ec0e0 R15: ffff888026c617a0
FS: 0000000000000000(0000) GS:ffff8880d4679000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000055bd50ca5728 CR3: 00000000549e5000 CR4: 0000000000352ef0
Call Trace:
hidg_set_alt+0x190/0xa10 drivers/usb/gadget/function/f_hid.c:1042
set_config drivers/usb/gadget/composite.c:1018 [inline]
composite_setup+0x2ccf/0x9290 drivers/usb/gadget/composite.c:1901
configfs_composite_setup+0xfb/0x130 drivers/usb/gadget/configfs.c:1877
dummy_timer+0x20a0/0x3840 drivers/usb/gadget/udc/dummy_hcd.c:1983
__run_hrtimer kernel/time/hrtimer.c:2079 [inline]
__hrtimer_run_queues+0x448/0x9a0 kernel/time/hrtimer.c:2136
hrtimer_run_softirq+0x1ca/0x360 kernel/time/hrtimer.c:2153
handle_softirqs+0x216/0xa20 kernel/softirq.c:669
__do_softirq kernel/softirq.c:703 [inline]
invoke_softirq kernel/softirq.c:542 [inline]
__irq_exit_rcu+0x178/0x220 kernel/softirq.c:786
irq_exit_rcu+0x9/0x30 kernel/softirq.c:809
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:__sanitizer_cov_trace_pc+0x0/0x70 kernel/kcov.c:216
Code: 66 9f 67 00 48 89 df 5b e9 1d e5 6d 00 be 03 00 00 00 5b e9 f2 97 2c 03 66 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 0f 1e fa 65 48 8b 05 7c 07 ac 13 48 8b 34 24 65 48 8b 15 60 07
RSP: 0018:ffffc90005217420 EFLAGS: 00000293
RAX: 0000000000000000 RBX: 000000000004f835 RCX: ffff888034250000
RDX: 0000000000000001 RSI: ffffffff829557c6 RDI: 0000000000000007
RBP: 0000000000000000 R08: 0000000000000fff R09: 0000000000000000
R10: ffffea00013e0d47 R11: 0000000000000000 R12: 0000000000000009
R13: 0000000000000001 R14: dffffc0000000000 R15: ffffea00013e0d58
__nr_to_section include/linux/mmzone.h:2112 [inline]
__pfn_to_section include/linux/mmzone.h:2217 [inline]
pfn_valid+0x35/0x4b0 include/linux/mmzone.h:2296
page_table_check_clear+0x21/0x5e0 mm/page_table_check.c:70
__page_table_check_pte_clear+0x10f/0x120 mm/page_table_check.c:155
page_table_check_pte_clear include/linux/page_table_check.h:55 [inline]
ptep_get_and_clear_full arch/x86/include/asm/pgtable.h:1263 [inline]
get_and_clear_full_ptes include/linux/pgtable.h:879 [inline]
zap_present_folio_ptes mm/memory.c:1740 [inline]
zap_present_ptes mm/memory.c:1822 [inline]
do_zap_pte_range mm/memory.c:1924 [inline]
zap_pte_range mm/memory.c:2026 [inline]
zap_pmd_range mm/memory.c:2117 [inline]
zap_pud_range mm/memory.c:2145 [inline]
zap_p4d_range mm/memory.c:2166 [inline]
__zap_vma_range+0x2bc7/0x46c0 mm/memory.c:2206
unmap_vmas+0x294/0x5f0 mm/memory.c:2275
exit_mmap+0x1ef/0xa40 mm/mmap.c:1315
__mmput+0x12a/0x410 kernel/fork.c:1192
mmput+0x62/0x70 kernel/fork.c:1215
exit_mm kernel/exit.c:586 [inline]
do_exit+0x80c/0x2a00 kernel/exit.c:967
do_group_exit+0xd5/0x2a0 kernel/exit.c:1123
get_signal+0x1f58/0x22e0 kernel/signal.c:3113
arch_do_signal_or_restart+0x91/0x7e0 arch/x86/kernel/signal.c:337
__exit_to_user_mode_loop kernel/entry/common.c:66 [inline]
exit_to_user_mode_loop+0x139/0x700 kernel/entry/common.c:101
__exit_to_user_mode_prepare include/linux/irq-entry-common.h:207 [inline]
syscall_exit_to_user_mode_prepare include/linux/irq-entry-common.h:230 [inline]
syscall_exit_to_user_mode include/linux/entry-common.h:343 [inline]
do_syscall_64+0x661/0x790 arch/x86/entry/syscall_64.c:89
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fc40d39fb19
Code: Unable to access opcode bytes at 0x7fc40d39faef.
RSP: 002b:00007fc40e2130e8 EFLAGS: 00000246 ORIG_RAX: 00000000000000ca
RAX: fffffffffffffe00 RBX: 00007fc40d625fa8 RCX: 00007fc40d39fb19
RDX: 0000000000000000 RSI: 0000000000000080 RDI: 00007fc40d625fa8
RBP: 00007fc40d625fa0 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007fc40d626038 R14: 00007ffe1183d640 R15: 00007ffe1183d728
----------------
Code disassembly (best guess):
0: 48 89 fa mov %rdi,%rdx
3: 48 c1 ea 03 shr $0x3,%rdx
7: 80 3c 02 00 cmpb $0x0,(%rdx,%rax,1)
b: 0f 85 93 00 00 00 jne 0xa4
11: 48 8d 3d 0a 4a 84 0a lea 0xa844a0a(%rip),%rdi # 0xa844a22
18: 48 8b 4b 08 mov 0x8(%rbx),%rcx
1c: 40 0f b6 d5 movzbl %bpl,%edx
20: 4d 89 e0 mov %r12,%r8
23: 48 c7 c6 00 b7 fb 8c mov $0xffffffff8cfbb700,%rsi
* 2a: 67 48 0f b9 3a ud1 (%edx),%rdi <-- trapping instruction
2f: bd ea ff ff ff mov $0xffffffea,%ebp
34: e9 8e fd ff ff jmp 0xfffffdc7
39: 49 c7 c4 a0 a9 fb 8c mov $0xffffffff8cfba9a0,%r12