	.file	"extr_usb_main.c_usb_event_cb.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	usb_event_cb, @function
usb_event_cb:
.LFB0:
	.cfi_startproc
	endbr64
	push	r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	push	rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	push	rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	cmp	esi, 132
	je	.L2
	jg	.L3
	cmp	esi, 128
	jne	.L31
	mov	edx, DWORD PTR NUM_USB_DRIVERS[rip]
	xor	ebp, ebp
	xor	ebx, ebx
	test	edx, edx
	jle	.L13
	.p2align 4,,10
	.p2align 3
.L8:
	xor	eax, eax
	add	ebx, 1
	call	chSysLockFromISR@PLT
	mov	rdi, QWORD PTR drivers[rip]
	add	rdi, rbp
	add	rbp, 28
	call	qmkusbWakeupHookI@PLT
	xor	eax, eax
	call	chSysUnlockFromISR@PLT
	cmp	DWORD PTR NUM_USB_DRIVERS[rip], ebx
	jg	.L8
.L13:
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	xor	eax, eax
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	jmp	suspend_wakeup_init@PLT
	.p2align 4,,10
	.p2align 3
.L31:
	.cfi_restore_state
	sub	esi, 129
	cmp	esi, 1
	ja	.L1
.L2:
	mov	ecx, DWORD PTR NUM_USB_DRIVERS[rip]
	xor	ebp, ebp
	xor	ebx, ebx
	test	ecx, ecx
	jle	.L1
	.p2align 4,,10
	.p2align 3
.L7:
	xor	eax, eax
	add	ebx, 1
	call	chSysLockFromISR@PLT
	mov	rdi, QWORD PTR drivers[rip]
	add	rdi, rbp
	add	rbp, 28
	call	qmkusbSuspendHookI@PLT
	xor	eax, eax
	call	chSysUnlockFromISR@PLT
	cmp	DWORD PTR NUM_USB_DRIVERS[rip], ebx
	jg	.L7
.L1:
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L3:
	.cfi_restore_state
	cmp	esi, 133
	jne	.L1
	xor	eax, eax
	mov	rbp, rdi
	xor	r12d, r12d
	call	osalSysLockFromISR@PLT
	mov	esi, DWORD PTR KEYBOARD_IN_EPNUM[rip]
	lea	rdx, kbd_ep_config[rip]
	mov	rdi, rbp
	call	usbInitEndpointI@PLT
	mov	eax, DWORD PTR NUM_USB_DRIVERS[rip]
	test	eax, eax
	jg	.L9
.L11:
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	xor	eax, eax
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	jmp	osalSysUnlockFromISR@PLT
	.p2align 4,,10
	.p2align 3
.L32:
	.cfi_restore_state
	lea	rdx, 4[rdi]
	mov	rdi, rbp
	call	usbInitEndpointI@PLT
	add	rbx, QWORD PTR drivers[rip]
	mov	rdi, rbx
.L10:
	call	qmkusbConfigureHookI@PLT
	add	r12, 1
	cmp	DWORD PTR NUM_USB_DRIVERS[rip], r12d
	jle	.L11
.L9:
	lea	rbx, 0[0+r12*8]
	mov	rax, QWORD PTR drivers[rip]
	mov	rdi, rbp
	sub	rbx, r12
	sal	rbx, 2
	add	rax, rbx
	mov	esi, DWORD PTR 16[rax]
	lea	rdx, 24[rax]
	call	usbInitEndpointI@PLT
	mov	rax, QWORD PTR drivers[rip]
	mov	rdi, rbp
	add	rax, rbx
	mov	esi, DWORD PTR 12[rax]
	lea	rdx, 20[rax]
	call	usbInitEndpointI@PLT
	mov	rdi, QWORD PTR drivers[rip]
	add	rdi, rbx
	mov	esi, DWORD PTR 8[rdi]
	test	esi, esi
	je	.L10
	jmp	.L32
	.cfi_endproc
.LFE0:
	.size	usb_event_cb, .-usb_event_cb
	.comm	shared_ep_config,4,4
	.comm	mouse_ep_config,4,4
	.comm	kbd_ep_config,4,4
	.comm	drivers,8,8
	.comm	SHARED_IN_EPNUM,4,4
	.comm	NUM_USB_DRIVERS,4,4
	.comm	MOUSE_IN_EPNUM,4,4
	.comm	KEYBOARD_IN_EPNUM,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_usb_main.c_usb_event_cb.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	usb_event_cb, %function
usb_event_cb:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	sub	r1, r1, #128
	push	{r4, r5, r6, r7, r8, lr}
	cmp	r1, #5
	ldrls	pc, [pc, r1, asl #2]
	b	.L1
.L4:
	.word	.L6
	.word	.L5
	.word	.L5
	.word	.L1
	.word	.L5
	.word	.L3
.L5:
	ldr	r7, .L27
	ldr	r3, [r7]
	cmp	r3, #0
	pople	{r4, r5, r6, r7, r8, pc}
	mov	r5, #0
	mov	r6, r5
	ldr	r4, .L27+4
.L7:
	bl	chSysLockFromISR
	ldr	r0, [r4]
	add	r6, r6, #1
	add	r0, r0, r5
	bl	qmkusbSuspendHookI
	bl	chSysUnlockFromISR
	ldr	r3, [r7]
	add	r5, r5, #28
	cmp	r3, r6
	bgt	.L7
	pop	{r4, r5, r6, r7, r8, pc}
.L6:
	ldr	r7, .L27
	ldr	r3, [r7]
	cmp	r3, #0
	ble	.L13
	mov	r5, #0
	mov	r6, r5
	ldr	r4, .L27+4
.L8:
	bl	chSysLockFromISR
	ldr	r0, [r4]
	add	r6, r6, #1
	add	r0, r0, r5
	bl	qmkusbWakeupHookI
	bl	chSysUnlockFromISR
	ldr	r3, [r7]
	add	r5, r5, #28
	cmp	r3, r6
	bgt	.L8
.L13:
	pop	{r4, r5, r6, r7, r8, lr}
	b	suspend_wakeup_init
.L3:
	mov	r6, r0
	bl	osalSysLockFromISR
	ldr	r3, .L27+8
	ldr	r7, .L27
	ldr	r1, [r3]
	mov	r0, r6
	ldr	r2, .L27+12
	bl	usbInitEndpointI
	ldr	r3, [r7]
	cmp	r3, #0
	ble	.L11
	mov	r5, #0
	ldr	r4, .L27+4
	mov	r8, r5
	b	.L9
.L10:
	bl	qmkusbConfigureHookI
	ldr	r3, [r7]
	add	r5, r5, #28
	cmp	r3, r8
	ble	.L11
.L9:
	ldr	r3, [r4]
	mov	r0, r6
	add	r3, r3, r5
	ldr	r1, [r3, #16]
	add	r2, r3, #24
	bl	usbInitEndpointI
	ldr	r3, [r4]
	mov	r0, r6
	add	r3, r3, r5
	ldr	r1, [r3, #12]
	add	r2, r3, #20
	bl	usbInitEndpointI
	ldr	r0, [r4]
	add	r8, r8, #1
	add	r0, r0, r5
	ldr	r1, [r0, #8]
	cmp	r1, #0
	beq	.L10
	add	r2, r0, #4
	mov	r0, r6
	bl	usbInitEndpointI
	ldr	r2, [r4]
	add	r0, r2, r5
	b	.L10
.L1:
	pop	{r4, r5, r6, r7, r8, pc}
.L11:
	pop	{r4, r5, r6, r7, r8, lr}
	b	osalSysUnlockFromISR
.L28:
	.align	2
.L27:
	.word	NUM_USB_DRIVERS
	.word	drivers
	.word	KEYBOARD_IN_EPNUM
	.word	kbd_ep_config
	.size	usb_event_cb, .-usb_event_cb
	.comm	shared_ep_config,4,4
	.comm	mouse_ep_config,4,4
	.comm	kbd_ep_config,4,4
	.comm	drivers,4,4
	.comm	SHARED_IN_EPNUM,4,4
	.comm	NUM_USB_DRIVERS,4,4
	.comm	MOUSE_IN_EPNUM,4,4
	.comm	KEYBOARD_IN_EPNUM,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
