	.file	"extr_usbreset.c_find_device.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"/sys/bus/usb/devices"
	.text
	.p2align 4
	.globl	find_device
	.type	find_device, @function
find_device:
.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	r14, rsi
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	mov	r13, r8
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	mov	rbp, rdx
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	mov	rbx, rdi
	lea	rdi, .LC0[rip]
	sub	rsp, 24
	.cfi_def_cfa_offset 80
	mov	QWORD PTR 8[rsp], rcx
	call	opendir@PLT
	mov	r15, rax
	test	rax, rax
	jne	.L7
	jmp	.L23
	.p2align 4,,10
	.p2align 3
.L4:
	test	rbp, rbp
	je	.L6
	mov	eax, DWORD PTR 0[rbp]
	cmp	DWORD PTR 8[r12], eax
	je	.L24
.L6:
	test	r13, r13
	jne	.L25
.L7:
	mov	rdi, r15
	call	parse_devlist@PLT
	mov	r12, rax
	test	rax, rax
	je	.L5
	test	rbx, rbx
	je	.L4
	mov	eax, DWORD PTR [rbx]
	cmp	DWORD PTR [r12], eax
	jne	.L4
	mov	eax, DWORD PTR [r14]
	cmp	DWORD PTR 4[r12], eax
	jne	.L4
	.p2align 4,,10
	.p2align 3
.L5:
	mov	rdi, r15
	call	closedir@PLT
.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[rsp]
	mov	eax, DWORD PTR [rax]
	cmp	DWORD PTR 12[r12], eax
	je	.L5
	test	r13, r13
	je	.L7
.L25:
	mov	edi, DWORD PTR 16[r12]
	mov	rsi, r13
	call	strcasecmp@PLT
	test	eax, eax
	jne	.L7
	jmp	.L5
.L23:
	xor	r12d, r12d
	jmp	.L1
	.cfi_endproc
.LFE0:
	.size	find_device, .-find_device
	.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_usbreset.c_find_device.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"/sys/bus/usb/devices\000"
	.text
	.align	2
	.global	find_device
	.syntax unified
	.arm
	.fpu softvfp
	.type	find_device, %function
find_device:
	@ args = 4, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, lr}
	mov	r5, r0
	ldr	r0, .L26
	mov	r9, r1
	mov	r6, r2
	mov	r10, r3
	ldr	r8, [sp, #32]
	bl	opendir
	subs	r7, r0, #0
	bne	.L7
	b	.L23
.L4:
	cmp	r6, #0
	beq	.L6
	ldr	r2, [r4, #8]
	ldr	r3, [r6]
	cmp	r2, r3
	beq	.L24
.L6:
	cmp	r8, #0
	bne	.L25
.L7:
	mov	r0, r7
	bl	parse_devlist
	subs	r4, r0, #0
	beq	.L5
	cmp	r5, #0
	beq	.L4
	ldr	r2, [r4]
	ldr	r3, [r5]
	cmp	r2, r3
	bne	.L4
	ldr	r2, [r4, #4]
	ldr	r3, [r9]
	cmp	r2, r3
	bne	.L4
.L5:
	mov	r0, r7
	bl	closedir
.L1:
	mov	r0, r4
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L24:
	ldr	r2, [r4, #12]
	ldr	r3, [r10]
	cmp	r2, r3
	beq	.L5
	cmp	r8, #0
	beq	.L7
.L25:
	mov	r1, r8
	ldr	r0, [r4, #16]
	bl	strcasecmp
	cmp	r0, #0
	bne	.L7
	b	.L5
.L23:
	mov	r4, r7
	b	.L1
.L27:
	.align	2
.L26:
	.word	.LC0
	.size	find_device, .-find_device
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
