	.file	"extr_usb.c_usb_alloc_dev.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"usb%d"
.LC1:
	.string	"%d"
.LC2:
	.string	"%s.%d"
.LC3:
	.string	"%d-%s"
	.text
	.p2align 4
	.globl	usb_alloc_dev
	.type	usb_alloc_dev, @function
usb_alloc_dev:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	mov	r14d, edx
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	mov	rbp, rsi
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	mov	rbx, rdi
	mov	rdi, rsi
	sub	rsp, 24
	.cfi_def_cfa_offset 80
	call	bus_to_hcd@PLT
	mov	esi, DWORD PTR GFP_KERNEL[rip]
	mov	edi, 152
	mov	r13, rax
	call	kzalloc@PLT
	mov	r12, rax
	test	rax, rax
	je	.L1
	mov	rdi, r13
	call	usb_get_hcd@PLT
	test	eax, eax
	je	.L21
	mov	rax, QWORD PTR 0[r13]
	mov	rax, QWORD PTR [rax]
	test	rax, rax
	je	.L4
	test	rbx, rbx
	je	.L4
	mov	rsi, r12
	mov	rdi, r13
	call	rax
	test	eax, eax
	je	.L23
.L4:
	lea	r15, 48[r12]
	mov	rdi, r15
	call	device_initialize@PLT
	lea	rax, usb_bus_type[rip]
	mov	rdi, QWORD PTR 8[rbp]
	mov	QWORD PTR 88[r12], rax
	lea	rax, usb_device_type[rip]
	mov	QWORD PTR 80[r12], rax
	mov	eax, DWORD PTR usb_device_groups[rip]
	mov	DWORD PTR 72[r12], eax
	mov	eax, DWORD PTR 4[rdi]
	mov	DWORD PTR 68[r12], eax
	mov	eax, DWORD PTR [rdi]
	mov	DWORD PTR 64[r12], eax
	call	dev_to_node@PLT
	mov	rdi, r15
	mov	esi, eax
	call	set_dev_node@PLT
	mov	eax, DWORD PTR USB_STATE_ATTACHED[rip]
	xor	esi, esi
	mov	DWORD PTR [r12], 1
	lea	rdi, 140[r12]
	mov	DWORD PTR 144[r12], eax
	call	atomic_set@PLT
	lea	rdi, 136[r12]
	call	INIT_LIST_HEAD@PLT
	mov	eax, DWORD PTR USB_DT_ENDPOINT_SIZE[rip]
	xor	edx, edx
	mov	rdi, r12
	lea	rsi, 128[r12]
	mov	DWORD PTR 132[r12], eax
	mov	eax, DWORD PTR USB_DT_ENDPOINT[rip]
	mov	DWORD PTR 128[r12], eax
	call	usb_enable_endpoint@PLT
	xor	edi, edi
	test	rbx, rbx
	mov	DWORD PTR 4[r12], 1
	sete	dil
	call	unlikely@PLT
	lea	rcx, 96[r12]
	mov	QWORD PTR 8[rsp], rcx
	test	rax, rax
	jne	.L24
	mov	rcx, QWORD PTR 8[rbx]
	mov	rdi, QWORD PTR 8[r12]
	cmp	BYTE PTR [rcx], 48
	je	.L25
	mov	r8d, r14d
	lea	rdx, .LC2[rip]
	mov	esi, 8
	xor	eax, eax
	call	snprintf@PLT
	mov	eax, DWORD PTR 16[rbx]
	lea	ecx, -4[0+rax*4]
	cmp	r14d, 14
	jbe	.L26
	mov	eax, 15
	sal	eax, cl
	cdqe
	add	rax, QWORD PTR 120[rbx]
	mov	QWORD PTR 120[r12], rax
.L7:
	lea	rax, 48[rbx]
	mov	rcx, QWORD PTR 8[r12]
	mov	edx, DWORD PTR 0[rbp]
	mov	rdi, r15
	mov	QWORD PTR 56[r12], rax
	lea	rsi, .LC3[rip]
	xor	eax, eax
	call	dev_set_name@PLT
	cmp	QWORD PTR 104[rbx], 0
	mov	esi, r14d
	je	.L27
.L9:
	mov	rdi, rbx
	call	usb_of_get_device_node@PLT
	mov	DWORD PTR 20[r12], r14d
	lea	rdi, 96[r12]
	mov	DWORD PTR 48[r12], eax
	mov	QWORD PTR 112[r12], rbp
	mov	QWORD PTR 104[r12], rbx
	call	INIT_LIST_HEAD@PLT
	mov	rsi, r13
	mov	rdi, r12
	call	usb_dev_authorized@PLT
	mov	rdi, rbp
	mov	DWORD PTR 28[r12], eax
	call	usb_bus_is_wusb@PLT
	test	rax, rax
	setne	al
	movzx	eax, al
	mov	DWORD PTR 24[r12], eax
.L1:
	add	rsp, 24
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	mov	rax, r12
	pop	rbx
	.cfi_def_cfa_offset 48
	pop	rbp
	.cfi_def_cfa_offset 40
	pop	r12
	.cfi_def_cfa_offset 32
	pop	r13
	.cfi_def_cfa_offset 24
	pop	r14
	.cfi_def_cfa_offset 16
	pop	r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L24:
	.cfi_restore_state
	mov	rax, QWORD PTR 8[r12]
	mov	rdi, r15
	mov	BYTE PTR [rax], 48
	mov	rax, QWORD PTR 16[rbp]
	mov	QWORD PTR 120[r12], 0
	mov	rsi, QWORD PTR 8[rbp]
	mov	QWORD PTR 56[r12], rax
	call	device_set_of_node_from_dev@PLT
	mov	edx, DWORD PTR 0[rbp]
	mov	rdi, r15
	xor	eax, eax
	lea	rsi, .LC0[rip]
	call	dev_set_name@PLT
	mov	DWORD PTR 20[r12], r14d
	lea	rdi, 96[r12]
	mov	QWORD PTR 112[r12], rbp
	mov	QWORD PTR 104[r12], rbx
	call	INIT_LIST_HEAD@PLT
	mov	rsi, r13
	mov	rdi, r12
	call	usb_dev_authorized@PLT
	mov	DWORD PTR 28[r12], eax
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L26:
	mov	eax, r14d
	sal	eax, cl
	add	rax, QWORD PTR 120[rbx]
	mov	QWORD PTR 120[r12], rax
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L25:
	mov	ecx, r14d
	lea	rdx, .LC1[rip]
	mov	esi, 8
	xor	eax, eax
	call	snprintf@PLT
	mov	QWORD PTR 120[r12], 0
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L23:
	mov	rdi, rbp
	call	bus_to_hcd@PLT
	mov	rdi, rax
	call	usb_put_hcd@PLT
.L21:
	mov	rdi, r12
	xor	r12d, r12d
	call	kfree@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L27:
	mov	rdi, r13
	call	usb_hcd_find_raw_port_number@PLT
	mov	esi, eax
	jmp	.L9
	.cfi_endproc
.LFE0:
	.size	usb_alloc_dev, .-usb_alloc_dev
	.comm	usb_device_type,4,4
	.comm	usb_device_groups,4,4
	.comm	usb_bus_type,4,4
	.comm	usb_autosuspend_delay,4,4
	.comm	jiffies,8,8
	.comm	USB_STATE_ATTACHED,4,4
	.comm	USB_DT_ENDPOINT_SIZE,4,4
	.comm	USB_DT_ENDPOINT,4,4
	.comm	GFP_KERNEL,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.c_usb_alloc_dev.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"usb%d\000"
	.align	2
.LC1:
	.ascii	"%d\000"
	.align	2
.LC2:
	.ascii	"%s.%d\000"
	.align	2
.LC3:
	.ascii	"%d-%s\000"
	.text
	.align	2
	.global	usb_alloc_dev
	.syntax unified
	.arm
	.fpu softvfp
	.type	usb_alloc_dev, %function
usb_alloc_dev:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	mov	r5, r0
	sub	sp, sp, #12
	mov	r0, r1
	mov	r6, r1
	mov	r8, r2
	bl	bus_to_hcd
	ldr	r3, .L25
	mov	r7, r0
	ldr	r1, [r3]
	mov	r0, #100
	bl	kzalloc
	subs	r4, r0, #0
	beq	.L1
	mov	r0, r7
	bl	usb_get_hcd
	subs	r9, r0, #0
	beq	.L18
	ldr	r3, [r7]
	ldr	r3, [r3]
	cmp	r3, #0
	cmpne	r5, #0
	beq	.L4
	mov	r1, r4
	mov	r0, r7
	blx	r3
	subs	r9, r0, #0
	beq	.L20
.L4:
	add	r9, r4, #36
	mov	r0, r9
	bl	device_initialize
	ldr	r3, .L25+4
	ldr	r0, [r6, #4]
	ldr	r3, [r3]
	ldm	r0, {r1, ip}
	ldr	r2, .L25+8
	str	r3, [r4, #52]
	ldr	r3, .L25+12
	str	ip, [r4, #48]
	str	r2, [r4, #60]
	str	r3, [r4, #56]
	str	r1, [r4, #44]
	bl	dev_to_node
	mov	r1, r0
	mov	r0, r9
	bl	set_dev_node
	mov	fp, #1
	mov	r0, r4
	ldr	r3, .L25+16
	mov	r1, #0
	ldr	r3, [r3]
	add	r10, r4, #64
	str	r3, [r4, #96]
	str	fp, [r0], #92
	bl	atomic_set
	add	r0, r4, #88
	bl	INIT_LIST_HEAD
	mov	r1, r4
	ldr	r2, .L25+20
	ldr	r3, .L25+24
	ldr	r2, [r2]
	ldr	r3, [r3]
	str	r2, [r4, #84]
	mov	r0, r4
	mov	r2, #0
	str	r3, [r1, #80]!
	bl	usb_enable_endpoint
	clz	r0, r5
	str	fp, [r4, #4]
	lsr	r0, r0, #5
	bl	unlikely
	subs	fp, r0, #0
	bne	.L21
	ldr	r3, [r5, #8]
	ldr	r0, [r4, #8]
	ldrb	r2, [r3]	@ zero_extendqisi2
	cmp	r2, #48
	beq	.L22
	mov	r1, #4
	ldr	r2, .L25+28
	str	r8, [sp]
	bl	snprintf
	cmp	r8, #14
	bls	.L23
	mov	r1, #15
	ldr	r3, [r5, #12]
	ldr	r2, [r5, #76]
	sub	r3, r3, #1
	lsl	r3, r3, #2
	add	r3, r2, r1, lsl r3
	str	r3, [r4, #76]
.L7:
	add	r3, r5, #36
	ldr	r1, .L25+32
	str	r3, [r4, #40]
	mov	r0, r9
	ldr	r3, [r4, #8]
	ldr	r2, [r6]
	bl	dev_set_name
	ldr	r3, [r5, #68]
	mov	r1, r8
	cmp	r3, #0
	beq	.L24
.L9:
	mov	r0, r5
	bl	usb_of_get_device_node
	str	r8, [r4, #16]
	str	r0, [r4, #36]
	str	r6, [r4, #72]
	mov	r0, r10
	str	r5, [r4, #68]
	bl	INIT_LIST_HEAD
	mov	r1, r7
	mov	r0, r4
	bl	usb_dev_authorized
	mov	r3, r0
	mov	r0, r6
	str	r3, [r4, #24]
	bl	usb_bus_is_wusb
	subs	r0, r0, #0
	movne	r0, #1
	str	r0, [r4, #20]
.L1:
	mov	r0, r4
	add	sp, sp, #12
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L21:
	mov	r1, #48
	mov	r2, #0
	ldr	r3, [r4, #8]
	mov	r0, r9
	strb	r1, [r3]
	ldr	r3, [r6, #8]
	ldr	r1, [r6, #4]
	str	r3, [r4, #40]
	str	r2, [r4, #76]
	bl	device_set_of_node_from_dev
	ldr	r2, [r6]
	ldr	r1, .L25+36
	mov	r0, r9
	bl	dev_set_name
	mov	r0, r10
	str	r8, [r4, #16]
	str	r6, [r4, #72]
	str	r5, [r4, #68]
	bl	INIT_LIST_HEAD
	mov	r1, r7
	mov	r0, r4
	bl	usb_dev_authorized
	str	r0, [r4, #24]
	mov	r0, r4
	add	sp, sp, #12
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L23:
	ldr	r3, [r5, #12]
	ldr	r2, [r5, #76]
	sub	r3, r3, #1
	lsl	r3, r3, #2
	add	r3, r2, r8, lsl r3
	str	r3, [r4, #76]
	b	.L7
.L22:
	mov	r3, r8
	mov	r1, #4
	ldr	r2, .L25+40
	bl	snprintf
	str	fp, [r4, #76]
	b	.L7
.L20:
	mov	r0, r6
	bl	bus_to_hcd
	bl	usb_put_hcd
.L18:
	mov	r0, r4
	mov	r4, r9
	bl	kfree
	mov	r0, r4
	add	sp, sp, #12
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L24:
	mov	r0, r7
	bl	usb_hcd_find_raw_port_number
	mov	r1, r0
	b	.L9
.L26:
	.align	2
.L25:
	.word	GFP_KERNEL
	.word	usb_device_groups
	.word	usb_bus_type
	.word	usb_device_type
	.word	USB_STATE_ATTACHED
	.word	USB_DT_ENDPOINT_SIZE
	.word	USB_DT_ENDPOINT
	.word	.LC2
	.word	.LC3
	.word	.LC0
	.word	.LC1
	.size	usb_alloc_dev, .-usb_alloc_dev
	.comm	usb_device_type,4,4
	.comm	usb_device_groups,4,4
	.comm	usb_bus_type,4,4
	.comm	usb_autosuspend_delay,4,4
	.comm	jiffies,4,4
	.comm	USB_STATE_ATTACHED,4,4
	.comm	USB_DT_ENDPOINT_SIZE,4,4
	.comm	USB_DT_ENDPOINT,4,4
	.comm	GFP_KERNEL,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
