	.file	"extr_usb_hid.c_hid_get_item.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"Using last usage\n"
.LC1:
	.string	"%u,%u,%u\n"
.LC2:
	.string	"bad length %u (data=0x%02x)\n"
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC3:
	.string	"Number of items(%u) truncated to %u\n"
	.section	.rodata.str1.1
.LC4:
	.string	"invalid end collection\n"
.LC5:
	.string	"Main bTag=%d\n"
.LC6:
	.string	"Cannot push item @ %d\n"
.LC7:
	.string	"Cannot pop item @ %d\n"
.LC8:
	.string	"Global bTag=%d\n"
.LC9:
	.string	"max usage reached\n"
.LC10:
	.string	"Usage set dropped\n"
.LC11:
	.string	"Local bTag=%d\n"
.LC12:
	.string	"default bType=%d\n"
	.text
	.p2align 4
	.globl	hid_get_item
	.type	hid_get_item, @function
hid_get_item:
.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
	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
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	sub	rsp, 40
	.cfi_def_cfa_offset 96
	mov	QWORD PTR 24[rsp], rsi
	test	rdi, rdi
	je	.L9
	mov	rax, QWORD PTR [rdi]
	mov	r14, rdi
	lea	r12, .L35[rip]
	lea	rbp, .L51[rip]
	lea	rdx, [rax+rax*4]
	lea	rbx, [rax+rdx*2]
	mov	rdx, QWORD PTR 16[rdi]
	sal	rbx, 4
	add	rbx, QWORD PTR 104[rdi]
.L4:
	mov	rax, QWORD PTR 8[r14]
	cmp	rax, rdx
	jge	.L5
	mov	rdx, QWORD PTR 24[r14]
	cmp	rdx, QWORD PTR 32[r14]
	jnb	.L6
	mov	rcx, QWORD PTR 40[r14]
	mov	rsi, QWORD PTR 48[r14]
	mov	rdi, QWORD PTR [rcx+rdx*8]
	add	rdi, rsi
	mov	QWORD PTR [rbx], rdi
	mov	rcx, rdi
	mov	QWORD PTR 56[r14], rdi
	mov	rdi, QWORD PTR 64[r14]
	cmp	QWORD PTR [rdi+rdx*8], rcx
	je	.L102
	add	rsi, 1
	mov	QWORD PTR 48[r14], rsi
.L8:
	mov	ecx, DWORD PTR 8[rbx]
	mov	r13d, DWORD PTR 72[r14]
	add	rax, 1
	mov	QWORD PTR 8[r14], rax
	sar	r13d, cl
	and	r13d, 1
	jne	.L103
.L5:
	mov	QWORD PTR 8[r14], 0
	mov	rdi, rbx
	mov	QWORD PTR 16[r14], 0
	mov	QWORD PTR 24[r14], 0
	mov	QWORD PTR 32[r14], 0
	mov	DWORD PTR 76[r14], 0
	mov	QWORD PTR 48[r14], 0
	call	hid_clear_local@PLT
	mov	rax, QWORD PTR 80[r14]
	cmp	QWORD PTR 88[r14], rax
	jne	.L69
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L107:
	test	r9d, r9d
	je	.L104
.L12:
	mov	edx, r9d
	lea	rsi, .LC12[rip]
	xor	edi, edi
	xor	eax, eax
	call	DPRINTFN@PLT
.L17:
	mov	rax, QWORD PTR 88[r14]
	cmp	QWORD PTR 80[r14], rax
	je	.L9
.L69:
	mov	esi, 1
	mov	rdi, r14
	call	hid_get_byte@PLT
	cmp	eax, 254
	je	.L105
	mov	r9d, eax
	mov	edx, eax
	and	eax, 3
	shr	r9d, 2
	shr	edx, 4
	and	r9d, 3
	cmp	eax, 3
	je	.L14
	cmp	eax, 1
	je	.L11
	cmp	eax, 2
	jne	.L106
.L13:
	mov	esi, 1
	mov	rdi, r14
	mov	DWORD PTR 20[rsp], r9d
	mov	DWORD PTR [rsp], edx
	call	hid_get_byte@PLT
	mov	esi, 1
	mov	rdi, r14
	mov	r13d, eax
	call	hid_get_byte@PLT
	mov	edx, DWORD PTR [rsp]
	mov	r9d, DWORD PTR 20[rsp]
	sal	eax, 8
	or	r13d, eax
	mov	eax, 2
	movsx	r15, r13d
	mov	r13d, 65535
.L16:
	cmp	r9d, 1
	je	.L18
	cmp	r9d, 2
	jne	.L107
	cmp	edx, 10
	ja	.L49
	mov	ecx, edx
	movsx	rcx, DWORD PTR 0[rbp+rcx*4]
	add	rcx, rbp
	notrack jmp	rcx
	.section	.rodata
	.align 4
	.align 4
.L51:
	.long	.L60-.L51
	.long	.L59-.L51
	.long	.L58-.L51
	.long	.L57-.L51
	.long	.L56-.L51
	.long	.L55-.L51
	.long	.L49-.L51
	.long	.L54-.L51
	.long	.L53-.L51
	.long	.L52-.L51
	.long	.L50-.L51
	.text
	.p2align 4,,10
	.p2align 3
.L18:
	cmp	edx, 11
	ja	.L33
	movsx	rax, DWORD PTR [r12+rdx*4]
	add	rax, r12
	notrack jmp	rax
	.section	.rodata
	.align 4
	.align 4
.L35:
	.long	.L46-.L35
	.long	.L45-.L35
	.long	.L44-.L35
	.long	.L43-.L35
	.long	.L42-.L35
	.long	.L41-.L35
	.long	.L40-.L35
	.long	.L39-.L35
	.long	.L38-.L35
	.long	.L37-.L35
	.long	.L36-.L35
	.long	.L34-.L35
	.text
	.p2align 4,,10
	.p2align 3
.L104:
	lea	ecx, -8[rdx]
	cmp	ecx, 4
	ja	.L20
	lea	rdx, .L22[rip]
	movsx	rax, DWORD PTR [rdx+rcx*4]
	add	rax, rdx
	notrack jmp	rax
	.section	.rodata
	.align 4
	.align 4
.L22:
	.long	.L26-.L22
	.long	.L25-.L22
	.long	.L24-.L22
	.long	.L23-.L22
	.long	.L21-.L22
	.text
	.p2align 4,,10
	.p2align 3
.L106:
	xor	r15d, r15d
	xor	r13d, r13d
	test	eax, eax
	je	.L16
	mov	r13d, 1
.L15:
	mov	esi, r13d
	mov	rdi, r14
	call	hid_get_byte@PLT
	mov	edx, r13d
	lea	rsi, .LC2[rip]
	xor	edi, edi
	movsx	rcx, eax
	xor	eax, eax
	call	DPRINTFN@PLT
	mov	rax, QWORD PTR 88[r14]
	cmp	QWORD PTR 80[r14], rax
	jne	.L69
	.p2align 4,,10
	.p2align 3
.L9:
	xor	r13d, r13d
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L105:
	mov	esi, 1
	mov	rdi, r14
	call	hid_get_byte@PLT
	mov	esi, 1
	mov	rdi, r14
	mov	r13d, eax
	call	hid_get_byte@PLT
	mov	esi, 1
	mov	rdi, r14
	sal	eax, 8
	or	r13d, eax
	call	hid_get_byte@PLT
	mov	r9d, 255
	mov	edx, eax
	cmp	r13d, 1
	je	.L11
	jbe	.L12
	cmp	r13d, 2
	je	.L13
	cmp	r13d, 4
	jne	.L15
.L14:
	mov	esi, 1
	mov	rdi, r14
	mov	DWORD PTR 20[rsp], r9d
	mov	DWORD PTR [rsp], edx
	call	hid_get_byte@PLT
	mov	esi, 1
	mov	rdi, r14
	mov	r15d, eax
	call	hid_get_byte@PLT
	mov	esi, 1
	mov	rdi, r14
	mov	r13d, eax
	call	hid_get_byte@PLT
	sal	r13d, 8
	mov	esi, 1
	mov	rdi, r14
	sal	eax, 16
	or	r13d, eax
	call	hid_get_byte@PLT
	or	r15d, r13d
	mov	edx, DWORD PTR [rsp]
	mov	r9d, DWORD PTR 20[rsp]
	sal	eax, 24
	mov	r13d, 4294967295
	or	r15d, eax
	mov	eax, 4
	movsx	r15, r15d
	jmp	.L16
	.p2align 4,,10
	.p2align 3
.L11:
	mov	esi, 1
	mov	rdi, r14
	mov	DWORD PTR [rsp], edx
	mov	r13d, 255
	mov	DWORD PTR 20[rsp], r9d
	call	hid_get_byte@PLT
	mov	edx, DWORD PTR [rsp]
	mov	r9d, DWORD PTR 20[rsp]
	movsx	r15, eax
	mov	eax, 1
	jmp	.L16
.L23:
	mov	eax, DWORD PTR hid_feature[rip]
	mov	DWORD PTR 8[rbx], eax
.L27:
	mov	r9d, DWORD PTR 96[r14]
	mov	eax, DWORD PTR 100[r14]
	mov	DWORD PTR 12[rbx], r15d
	mov	DWORD PTR 104[rbx], r9d
	mov	DWORD PTR 100[rbx], eax
	test	DWORD PTR HIO_VARIABLE[rip], r15d
	je	.L28
	mov	rcx, QWORD PTR MAXLOCCNT[rip]
	movsx	rdx, r9d
	cmp	rdx, rcx
	jg	.L108
	mov	QWORD PTR 16[r14], rdx
.L30:
	mov	DWORD PTR 104[rbx], 1
	jmp	.L4
.L24:
	mov	eax, DWORD PTR hid_collection[rip]
	add	DWORD PTR 160[rbx], 1
	mov	QWORD PTR 168[rbx], r15
	mov	DWORD PTR 8[rbx], eax
	mov	rax, QWORD PTR 56[r14]
	mov	QWORD PTR [rbx], rax
	mov	rax, QWORD PTR 24[rsp]
	movdqu	xmm0, XMMWORD PTR [rbx]
	movups	XMMWORD PTR [rax], xmm0
	movdqu	xmm1, XMMWORD PTR 16[rbx]
	movups	XMMWORD PTR 16[rax], xmm1
	movdqu	xmm2, XMMWORD PTR 32[rbx]
	movups	XMMWORD PTR 32[rax], xmm2
	movdqu	xmm3, XMMWORD PTR 48[rbx]
	movups	XMMWORD PTR 48[rax], xmm3
.L100:
	movdqu	xmm4, XMMWORD PTR 64[rbx]
	mov	r13d, 1
	movups	XMMWORD PTR 64[rax], xmm4
	movdqu	xmm5, XMMWORD PTR 80[rbx]
	movups	XMMWORD PTR 80[rax], xmm5
	movdqu	xmm6, XMMWORD PTR 96[rbx]
	movups	XMMWORD PTR 96[rax], xmm6
	movdqu	xmm7, XMMWORD PTR 112[rbx]
	movups	XMMWORD PTR 112[rax], xmm7
	movdqu	xmm0, XMMWORD PTR 128[rbx]
	movups	XMMWORD PTR 128[rax], xmm0
	movdqu	xmm1, XMMWORD PTR 144[rbx]
	movups	XMMWORD PTR 144[rax], xmm1
	movdqu	xmm2, XMMWORD PTR 160[rbx]
	movaps	XMMWORD PTR [rsp], xmm2
	movups	XMMWORD PTR 160[rax], xmm2
.L1:
	add	rsp, 40
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	mov	eax, r13d
	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
.L25:
	.cfi_restore_state
	mov	eax, DWORD PTR hid_output[rip]
	mov	DWORD PTR 8[rbx], eax
	jmp	.L27
.L26:
	mov	eax, DWORD PTR hid_input[rip]
	mov	DWORD PTR 8[rbx], eax
	jmp	.L27
.L21:
	mov	eax, DWORD PTR hid_endcollection[rip]
	mov	r13d, DWORD PTR 160[rbx]
	mov	DWORD PTR 8[rbx], eax
	test	r13d, r13d
	je	.L109
	mov	rax, QWORD PTR 24[rsp]
	movdqu	xmm4, XMMWORD PTR [rbx]
	sub	r13d, 1
	mov	DWORD PTR 160[rbx], r13d
	movups	XMMWORD PTR [rax], xmm4
	movdqu	xmm5, XMMWORD PTR 16[rbx]
	movups	XMMWORD PTR 16[rax], xmm5
	movdqu	xmm6, XMMWORD PTR 32[rbx]
	movups	XMMWORD PTR 32[rax], xmm6
	movdqu	xmm7, XMMWORD PTR 48[rbx]
	movups	XMMWORD PTR 48[rax], xmm7
	jmp	.L100
	.p2align 4,,10
	.p2align 3
.L28:
	mov	QWORD PTR 16[r14], 1
	mov	edx, 1
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L6:
	lea	rsi, .LC0[rip]
	mov	edi, 1
	xor	eax, eax
	call	DPRINTFN@PLT
	mov	rax, QWORD PTR 8[r14]
	jmp	.L8
.L20:
	lea	rsi, .LC5[rip]
	xor	edi, edi
	xor	eax, eax
	call	DPRINTFN@PLT
	jmp	.L17
	.p2align 4,,10
	.p2align 3
.L102:
	add	rdx, 1
	mov	QWORD PTR 48[r14], 0
	mov	QWORD PTR 24[r14], rdx
	jmp	.L8
.L50:
	mov	QWORD PTR 40[rbx], r15
	jmp	.L17
.L49:
	lea	rsi, .LC11[rip]
	xor	edi, edi
	xor	eax, eax
	call	DPRINTFN@PLT
	jmp	.L17
.L60:
	cmp	eax, 4
	je	.L61
	and	r15, r13
	or	r15, QWORD PTR 16[rbx]
.L61:
	mov	rax, QWORD PTR 32[r14]
	cmp	rax, QWORD PTR MAXUSAGE[rip]
	mov	QWORD PTR 56[r14], r15
	jnb	.L62
	mov	rdx, QWORD PTR 40[r14]
	mov	QWORD PTR [rdx+rax*8], r15
	mov	rax, QWORD PTR 64[r14]
	mov	rdx, QWORD PTR 32[r14]
	mov	QWORD PTR [rax+rdx*8], r15
	add	QWORD PTR 32[r14], 1
.L68:
	mov	DWORD PTR 76[r14], 0
	jmp	.L17
.L59:
	mov	ecx, DWORD PTR 76[r14]
	or	ecx, 1
	mov	DWORD PTR 76[r14], ecx
	cmp	eax, 4
	je	.L64
	and	r15, r13
	or	r15, QWORD PTR 16[rbx]
.L64:
	mov	QWORD PTR 24[rbx], r15
.L65:
	cmp	ecx, 3
	jne	.L17
	mov	rax, QWORD PTR 32[r14]
	cmp	rax, QWORD PTR MAXUSAGE[rip]
	jnb	.L67
	mov	rdx, QWORD PTR 24[rbx]
	cmp	rdx, QWORD PTR 32[rbx]
	jg	.L67
	mov	rcx, QWORD PTR 40[r14]
	mov	QWORD PTR [rcx+rax*8], rdx
	mov	rax, QWORD PTR 64[r14]
	mov	rcx, QWORD PTR 32[rbx]
	mov	rdx, QWORD PTR 32[r14]
	mov	QWORD PTR [rax+rdx*8], rcx
	add	QWORD PTR 32[r14], 1
	jmp	.L68
.L55:
	mov	QWORD PTR 72[rbx], r15
	jmp	.L17
.L57:
	mov	QWORD PTR 88[rbx], r15
	jmp	.L17
.L56:
	mov	QWORD PTR 80[rbx], r15
	jmp	.L17
.L58:
	mov	ecx, DWORD PTR 76[r14]
	or	ecx, 2
	mov	DWORD PTR 76[r14], ecx
	cmp	eax, 4
	je	.L66
	and	r15, r13
	or	r15, QWORD PTR 16[rbx]
.L66:
	mov	QWORD PTR 32[rbx], r15
	jmp	.L65
.L53:
	mov	QWORD PTR 56[rbx], r15
	jmp	.L17
.L52:
	mov	QWORD PTR 48[rbx], r15
	jmp	.L17
.L54:
	mov	QWORD PTR 64[rbx], r15
	jmp	.L17
.L34:
	mov	rax, QWORD PTR [r14]
	lea	rdx, -1[rax]
	cmp	rdx, QWORD PTR MAXPUSH[rip]
	mov	QWORD PTR [r14], rdx
	jnb	.L48
	lea	rcx, [rdx+rdx*4]
	mov	eax, DWORD PTR 96[rbx]
	lea	rbx, [rdx+rcx*2]
	sal	rbx, 4
	add	rbx, QWORD PTR 104[r14]
	mov	edx, DWORD PTR 100[rbx]
	mov	DWORD PTR 100[r14], edx
	mov	edx, DWORD PTR 104[rbx]
	mov	DWORD PTR 96[r14], edx
	mov	DWORD PTR 96[rbx], eax
	mov	QWORD PTR 100[rbx], 0
	jmp	.L17
.L46:
	sal	r15, 16
	mov	QWORD PTR 16[rbx], r15
	jmp	.L17
.L45:
	mov	QWORD PTR 152[rbx], r15
	jmp	.L17
.L44:
	mov	QWORD PTR 144[rbx], r15
	jmp	.L17
.L43:
	mov	QWORD PTR 136[rbx], r15
	jmp	.L17
.L42:
	mov	QWORD PTR 128[rbx], r15
	jmp	.L17
.L37:
	and	r15d, r13d
	mov	DWORD PTR 96[r14], r15d
	jmp	.L17
.L36:
	mov	rax, QWORD PTR [r14]
	lea	rdx, 1[rax]
	cmp	rdx, QWORD PTR MAXPUSH[rip]
	mov	QWORD PTR [r14], rdx
	jnb	.L47
	lea	rax, [rdx+rdx*4]
	movdqu	xmm4, XMMWORD PTR [rbx]
	lea	rax, [rdx+rax*2]
	mov	edx, DWORD PTR 100[r14]
	sal	rax, 4
	add	rax, QWORD PTR 104[r14]
	movups	XMMWORD PTR [rax], xmm4
	movdqu	xmm5, XMMWORD PTR 16[rbx]
	movups	XMMWORD PTR 16[rax], xmm5
	movdqu	xmm6, XMMWORD PTR 32[rbx]
	movups	XMMWORD PTR 32[rax], xmm6
	movdqu	xmm7, XMMWORD PTR 48[rbx]
	movups	XMMWORD PTR 48[rax], xmm7
	movdqu	xmm0, XMMWORD PTR 64[rbx]
	movups	XMMWORD PTR 64[rax], xmm0
	movdqu	xmm1, XMMWORD PTR 80[rbx]
	movups	XMMWORD PTR 80[rax], xmm1
	movdqu	xmm2, XMMWORD PTR 96[rbx]
	movups	XMMWORD PTR 96[rax], xmm2
	movdqu	xmm3, XMMWORD PTR 112[rbx]
	movups	XMMWORD PTR 112[rax], xmm3
	movdqu	xmm4, XMMWORD PTR 128[rbx]
	movups	XMMWORD PTR 128[rax], xmm4
	movdqu	xmm5, XMMWORD PTR 144[rbx]
	movups	XMMWORD PTR 144[rax], xmm5
	movdqu	xmm6, XMMWORD PTR 160[rbx]
	movups	XMMWORD PTR 160[rax], xmm6
	mov	DWORD PTR 100[rbx], edx
	mov	edx, DWORD PTR 96[r14]
	mov	DWORD PTR 104[rbx], edx
	mov	rbx, rax
	jmp	.L17
.L41:
	mov	QWORD PTR 120[rbx], r15
	jmp	.L17
.L40:
	mov	QWORD PTR 112[rbx], r15
	jmp	.L17
.L39:
	and	r15d, r13d
	mov	DWORD PTR 100[r14], r15d
	jmp	.L17
.L38:
	mov	rdx, r13
	mov	rsi, rbx
	mov	rdi, r14
	and	rdx, r15
	call	hid_switch_rid@PLT
	jmp	.L17
.L67:
	lea	rsi, .LC10[rip]
	xor	edi, edi
	xor	eax, eax
	call	DPRINTFN@PLT
	jmp	.L68
	.p2align 4,,10
	.p2align 3
.L108:
	mov	edx, r9d
	lea	rsi, .LC3[rip]
	xor	edi, edi
	xor	eax, eax
	call	DPRINTFN@PLT
	mov	rdx, QWORD PTR MAXLOCCNT[rip]
	mov	QWORD PTR 16[r14], rdx
	jmp	.L30
.L33:
	lea	rsi, .LC8[rip]
	xor	edi, edi
	xor	eax, eax
	call	DPRINTFN@PLT
	jmp	.L17
.L109:
	lea	rsi, .LC4[rip]
	xor	edi, edi
	xor	eax, eax
	call	DPRINTFN@PLT
	jmp	.L1
.L62:
	lea	rsi, .LC9[rip]
	xor	edi, edi
	xor	eax, eax
	call	DPRINTFN@PLT
	jmp	.L68
.L47:
	lea	rsi, .LC6[rip]
	xor	edi, edi
	xor	eax, eax
	call	DPRINTFN@PLT
	jmp	.L17
.L48:
	lea	rsi, .LC7[rip]
	xor	edi, edi
	xor	eax, eax
	call	DPRINTFN@PLT
	jmp	.L17
.L103:
	mov	rax, QWORD PTR 24[rsp]
	movdqu	xmm7, XMMWORD PTR [rbx]
	mov	edi, 1
	lea	rsi, .LC1[rip]
	movups	XMMWORD PTR [rax], xmm7
	movdqu	xmm7, XMMWORD PTR 16[rbx]
	movups	XMMWORD PTR 16[rax], xmm7
	movdqu	xmm0, XMMWORD PTR 32[rbx]
	movups	XMMWORD PTR 32[rax], xmm0
	movdqu	xmm1, XMMWORD PTR 48[rbx]
	movups	XMMWORD PTR 48[rax], xmm1
	movdqu	xmm2, XMMWORD PTR 64[rbx]
	movups	XMMWORD PTR 64[rax], xmm2
	movdqu	xmm3, XMMWORD PTR 80[rbx]
	movups	XMMWORD PTR 80[rax], xmm3
	movdqu	xmm7, XMMWORD PTR 96[rbx]
	movups	XMMWORD PTR 96[rax], xmm7
	movdqu	xmm0, XMMWORD PTR 112[rbx]
	mov	ecx, DWORD PTR 100[rax]
	mov	edx, DWORD PTR 96[rax]
	mov	r8d, DWORD PTR 104[rax]
	movups	XMMWORD PTR 112[rax], xmm0
	movdqu	xmm1, XMMWORD PTR 128[rbx]
	movups	XMMWORD PTR 128[rax], xmm1
	movdqu	xmm2, XMMWORD PTR 144[rbx]
	movups	XMMWORD PTR 144[rax], xmm2
	movdqu	xmm3, XMMWORD PTR 160[rbx]
	movups	XMMWORD PTR 160[rax], xmm3
	xor	eax, eax
	call	DPRINTFN@PLT
	mov	eax, DWORD PTR 100[rbx]
	imul	eax, DWORD PTR 104[rbx]
	add	DWORD PTR 96[rbx], eax
	jmp	.L1
	.cfi_endproc
.LFE0:
	.size	hid_get_item, .-hid_get_item
	.comm	hid_output,4,4
	.comm	hid_input,4,4
	.comm	hid_feature,4,4
	.comm	hid_endcollection,4,4
	.comm	hid_collection,4,4
	.comm	MAXUSAGE,8,8
	.comm	MAXPUSH,8,8
	.comm	MAXLOCCNT,8,8
	.comm	HIO_VARIABLE,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_hid.c_hid_get_item.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"Using last usage\012\000"
	.align	2
.LC1:
	.ascii	"%u,%u,%u\012\000"
	.align	2
.LC2:
	.ascii	"bad length %u (data=0x%02x)\012\000"
	.align	2
.LC3:
	.ascii	"Number of items(%u) truncated to %u\012\000"
	.align	2
.LC4:
	.ascii	"invalid end collection\012\000"
	.align	2
.LC5:
	.ascii	"Main bTag=%d\012\000"
	.align	2
.LC6:
	.ascii	"Cannot push item @ %d\012\000"
	.align	2
.LC7:
	.ascii	"Cannot pop item @ %d\012\000"
	.align	2
.LC8:
	.ascii	"Global bTag=%d\012\000"
	.align	2
.LC9:
	.ascii	"max usage reached\012\000"
	.align	2
.LC10:
	.ascii	"Usage set dropped\012\000"
	.align	2
.LC11:
	.ascii	"Local bTag=%d\012\000"
	.align	2
.LC12:
	.ascii	"default bType=%d\012\000"
	.text
	.align	2
	.global	hid_get_item
	.syntax unified
	.arm
	.fpu softvfp
	.type	hid_get_item, %function
hid_get_item:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	subs	r5, r0, #0
	sub	sp, sp, #12
	beq	.L9
	mov	r10, r1
	ldr	r3, [r5]
	ldr	r7, [r5, #60]
	add	r3, r3, r3, lsl #1
	ldr	r2, [r5, #8]
	ldr	r8, .L101
	add	r7, r7, r3, lsl #5
.L4:
	ldr	r3, [r5, #4]
	cmp	r3, r2
	bge	.L5
	ldr	r2, [r5, #12]
	ldr	r1, [r5, #16]
	cmp	r2, r1
	bcs	.L6
	ldr	r1, [r5, #20]
	ldr	r0, [r5, #24]
	ldr	r1, [r1, r2, lsl #2]
	ldr	ip, [r5, #32]
	add	r1, r0, r1
	str	r1, [r7]
	str	r1, [r5, #28]
	ldr	ip, [ip, r2, lsl #2]
	cmp	ip, r1
	moveq	r1, #0
	addeq	r2, r2, #1
	addne	r0, r0, #1
	streq	r2, [r5, #12]
	streq	r1, [r5, #24]
	strne	r0, [r5, #24]
.L8:
	ldr	r1, [r7, #4]
	ldr	r2, [r5, #36]
	add	r3, r3, #1
	asr	r2, r2, r1
	ands	r2, r2, #1
	str	r3, [r5, #4]
	bne	.L95
.L5:
	mov	r3, #0
	mov	r0, r7
	str	r3, [r5, #4]
	str	r3, [r5, #8]
	str	r3, [r5, #12]
	str	r3, [r5, #16]
	str	r3, [r5, #40]
	str	r3, [r5, #24]
	bl	hid_clear_local
	ldr	r2, [r5, #48]
	ldr	r3, [r5, #44]
	cmp	r2, r3
	beq	.L9
.L71:
	mov	r1, #1
	mov	r0, r5
	bl	hid_get_byte
	cmp	r0, #254
	beq	.L96
	and	r3, r0, #3
	lsr	r6, r0, #2
	cmp	r3, #3
	and	r6, r6, #3
	lsr	r4, r0, #4
	beq	.L12
	sub	r3, r3, #1
	cmp	r3, #1
	ldrls	pc, [pc, r3, asl #2]
	b	.L76
.L18:
	.word	.L15
	.word	.L14
.L73:
	mov	r6, #255
.L15:
	mov	r1, #1
	mov	r0, r5
	bl	hid_get_byte
	mov	r3, #1
	mov	r2, #255
.L17:
	cmp	r6, #1
	beq	.L20
.L98:
	cmp	r6, #2
	beq	.L21
	cmp	r6, #0
	beq	.L97
.L16:
	mov	r2, r6
	mov	r1, r8
	mov	r0, #0
	bl	DPRINTFN
.L19:
	ldr	r2, [r5, #44]
	ldr	r3, [r5, #48]
	cmp	r2, r3
	bne	.L71
.L9:
	mov	r4, #0
	mov	r0, r4
	add	sp, sp, #12
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L74:
	mov	r6, #255
.L14:
	mov	r1, #1
	mov	r0, r5
	bl	hid_get_byte
	mov	r1, #1
	mov	r9, r0
	mov	r0, r5
	bl	hid_get_byte
	cmp	r6, #1
	mov	r3, #2
	ldr	r2, .L101+4
	orr	r0, r9, r0, lsl #8
	bne	.L98
.L20:
	cmp	r4, #11
	ldrls	pc, [pc, r4, asl #2]
	b	.L35
.L37:
	.word	.L48
	.word	.L47
	.word	.L46
	.word	.L45
	.word	.L44
	.word	.L43
	.word	.L42
	.word	.L41
	.word	.L40
	.word	.L39
	.word	.L38
	.word	.L36
.L97:
	sub	r3, r4, #8
	cmp	r3, #4
	ldrls	pc, [pc, r3, asl #2]
	b	.L22
.L24:
	.word	.L28
	.word	.L27
	.word	.L26
	.word	.L25
	.word	.L23
.L21:
	cmp	r4, #10
	ldrls	pc, [pc, r4, asl #2]
	b	.L51
.L53:
	.word	.L62
	.word	.L61
	.word	.L60
	.word	.L59
	.word	.L58
	.word	.L57
	.word	.L51
	.word	.L56
	.word	.L55
	.word	.L54
	.word	.L52
.L96:
	mov	r1, #1
	mov	r0, r5
	bl	hid_get_byte
	mov	r1, #1
	mov	r6, r0
	mov	r0, r5
	bl	hid_get_byte
	mov	r2, r0
	mov	r1, #1
	mov	r0, r5
	orr	r6, r6, r2, lsl #8
	bl	hid_get_byte
	mov	r4, r0
	cmp	r6, #4
	ldrls	pc, [pc, r6, asl #2]
	b	.L11
.L13:
	.word	.L72
	.word	.L73
	.word	.L74
	.word	.L11
	.word	.L75
.L11:
	mov	r1, r6
	mov	r0, r5
	bl	hid_get_byte
	mov	r2, r6
	mov	r3, r0
	ldr	r1, .L101+8
	mov	r0, #0
	bl	DPRINTFN
	b	.L19
.L75:
	mov	r6, #255
.L12:
	mov	r1, #1
	mov	r0, r5
	bl	hid_get_byte
	mov	r1, #1
	mov	fp, r0
	mov	r0, r5
	bl	hid_get_byte
	mov	r1, #1
	mov	r9, r0
	mov	r0, r5
	bl	hid_get_byte
	mov	r1, #1
	lsl	r3, r0, #16
	mov	r0, r5
	orr	r9, r3, r9, lsl #8
	bl	hid_get_byte
	orr	r9, r9, fp
	mov	r3, #4
	mvn	r2, #0
	orr	r0, r9, r0, lsl #24
	b	.L17
.L23:
	ldr	r3, .L101+12
	ldr	r4, [r7, #88]
	ldr	r3, [r3]
	cmp	r4, #0
	str	r3, [r7, #4]
	beq	.L99
	sub	r4, r4, #1
	str	r4, [r7, #88]
	mov	r1, r7
	mov	r0, r10
	mov	r2, #96
	bl	memcpy
	mov	r4, #1
.L1:
	mov	r0, r4
	add	sp, sp, #12
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L25:
	ldr	r3, .L101+16
	ldr	r3, [r3]
	str	r3, [r7, #4]
.L29:
	ldr	r3, .L101+20
	ldr	r2, [r5, #52]
	ldr	r3, [r3]
	str	r0, [r7, #8]
	tst	r0, r3
	ldr	r3, [r5, #56]
	str	r2, [r7, #60]
	moveq	r2, #1
	str	r3, [r7, #56]
	streq	r2, [r5, #8]
	beq	.L4
	ldr	r4, .L101+24
	ldr	r3, [r4]
	cmp	r2, r3
	strle	r2, [r5, #8]
	bgt	.L100
.L32:
	mov	r3, #1
	str	r3, [r7, #60]
	b	.L4
.L26:
	mov	r4, #1
	ldr	r2, .L101+28
	ldr	r3, [r7, #88]
	ldr	r1, [r5, #28]
	ldr	r2, [r2]
	add	r3, r3, #1
	stm	r7, {r1, r2}
	str	r0, [r7, #92]
	mov	r1, r7
	mov	r0, r10
	mov	r2, #96
	str	r3, [r7, #88]
	bl	memcpy
	mov	r0, r4
	add	sp, sp, #12
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L27:
	ldr	r3, .L101+32
	ldr	r3, [r3]
	str	r3, [r7, #4]
	b	.L29
.L28:
	ldr	r3, .L101+36
	ldr	r3, [r3]
	str	r3, [r7, #4]
	b	.L29
.L72:
	mov	r6, #255
	b	.L16
.L6:
	mov	r0, #1
	ldr	r1, .L101+40
	bl	DPRINTFN
	ldr	r3, [r5, #4]
	b	.L8
.L52:
	str	r0, [r7, #24]
	b	.L19
.L51:
	mov	r2, r4
	ldr	r1, .L101+44
	mov	r0, #0
	bl	DPRINTFN
	b	.L19
.L62:
	cmp	r3, #4
	ldrne	r3, [r7, #12]
	andne	r0, r0, r2
	ldr	r2, .L101+48
	orrne	r0, r0, r3
	ldr	r2, [r2]
	ldr	r3, [r5, #16]
	str	r0, [r5, #28]
	cmp	r3, r2
	bcs	.L64
	ldr	r1, [r5, #20]
	ldr	r2, [r5, #32]
	str	r0, [r1, r3, lsl #2]
	ldr	r3, [r5, #16]
	str	r0, [r2, r3, lsl #2]
	ldr	r3, [r5, #16]
	add	r3, r3, #1
	str	r3, [r5, #16]
.L70:
	mov	r3, #0
	str	r3, [r5, #40]
	b	.L19
.L61:
	ldr	r1, [r5, #40]
	cmp	r3, #4
	orr	r3, r1, #1
	ldrne	r1, [r7, #12]
	andne	r0, r0, r2
	orrne	r0, r0, r1
	str	r3, [r5, #40]
	str	r0, [r7, #16]
.L67:
	cmp	r3, #3
	bne	.L19
	ldr	r2, .L101+48
	ldr	r3, [r5, #16]
	ldr	r2, [r2]
	cmp	r3, r2
	bcs	.L69
	ldr	r2, [r7, #16]
	ldr	r1, [r7, #20]
	cmp	r2, r1
	bgt	.L69
	ldr	r0, [r5, #20]
	ldr	r1, [r5, #32]
	str	r2, [r0, r3, lsl #2]
	ldr	r3, [r5, #16]
	ldr	r2, [r7, #20]
	str	r2, [r1, r3, lsl #2]
	ldr	r3, [r5, #16]
	add	r3, r3, #1
	str	r3, [r5, #16]
	b	.L70
.L57:
	str	r0, [r7, #40]
	b	.L19
.L59:
	str	r0, [r7, #48]
	b	.L19
.L58:
	str	r0, [r7, #44]
	b	.L19
.L60:
	ldr	r1, [r5, #40]
	cmp	r3, #4
	orr	r3, r1, #2
	ldrne	r1, [r7, #12]
	andne	r0, r0, r2
	orrne	r0, r0, r1
	str	r3, [r5, #40]
	str	r0, [r7, #20]
	b	.L67
.L55:
	str	r0, [r7, #32]
	b	.L19
.L54:
	str	r0, [r7, #28]
	b	.L19
.L56:
	str	r0, [r7, #36]
	b	.L19
.L46:
	str	r0, [r7, #80]
	b	.L19
.L45:
	str	r0, [r7, #76]
	b	.L19
.L44:
	str	r0, [r7, #72]
	b	.L19
.L43:
	str	r0, [r7, #68]
	b	.L19
.L42:
	str	r0, [r7, #64]
	b	.L19
.L41:
	and	r2, r2, r0
	str	r2, [r5, #56]
	b	.L19
.L40:
	and	r2, r2, r0
	mov	r1, r7
	mov	r0, r5
	bl	hid_switch_rid
	b	.L19
.L39:
	and	r2, r2, r0
	str	r2, [r5, #52]
	b	.L19
.L38:
	ldr	r3, .L101+52
	ldr	r2, [r5]
	ldr	r3, [r3]
	add	r2, r2, #1
	cmp	r2, r3
	str	r2, [r5]
	bcs	.L49
	ldr	r3, [r5, #60]
	add	r2, r2, r2, lsl #1
	add	r3, r3, r2, lsl #5
	mov	r1, r7
	mov	r2, #96
	mov	r0, r3
	bl	memcpy
	ldr	r1, [r5, #56]
	ldr	r2, [r5, #52]
	str	r1, [r7, #56]
	str	r2, [r7, #60]
	mov	r7, r0
	b	.L19
.L36:
	ldr	r3, .L101+52
	ldr	r2, [r5]
	ldr	r3, [r3]
	sub	r2, r2, #1
	cmp	r2, r3
	str	r2, [r5]
	bcs	.L50
	mov	r3, #0
	ldr	r0, [r5, #60]
	add	r2, r2, r2, lsl #1
	ldr	r1, [r7, #52]
	add	r7, r0, r2, lsl #5
	ldr	r0, [r7, #56]
	ldr	r2, [r7, #60]
	str	r0, [r5, #56]
	str	r2, [r5, #52]
	str	r1, [r7, #52]
	str	r3, [r7, #56]
	str	r3, [r7, #60]
	b	.L19
.L48:
	lsl	r0, r0, #16
	str	r0, [r7, #12]
	b	.L19
.L47:
	str	r0, [r7, #84]
	b	.L19
.L69:
	ldr	r1, .L101+56
	mov	r0, #0
	bl	DPRINTFN
	b	.L70
.L100:
	mov	r0, #0
	ldr	r1, .L101+60
	bl	DPRINTFN
	ldr	r2, [r4]
	str	r2, [r5, #8]
	b	.L32
.L99:
	mov	r0, r4
	ldr	r1, .L101+64
	bl	DPRINTFN
	b	.L1
.L64:
	ldr	r1, .L101+68
	mov	r0, #0
	bl	DPRINTFN
	b	.L70
.L50:
	ldr	r1, .L101+72
	mov	r0, #0
	bl	DPRINTFN
	b	.L19
.L49:
	ldr	r1, .L101+76
	mov	r0, #0
	bl	DPRINTFN
	b	.L19
.L95:
	mov	r1, r7
	mov	r4, r2
	mov	r0, r10
	mov	r2, #96
	bl	memcpy
	ldr	r2, [r10, #60]
	ldr	r3, [r10, #56]
	str	r2, [sp]
	ldr	r2, [r10, #52]
	ldr	r1, .L101+80
	mov	r0, #1
	bl	DPRINTFN
	ldr	r2, [r7, #52]
	ldr	r3, [r7, #56]
	ldr	r1, [r7, #60]
	mla	r3, r1, r3, r2
	str	r3, [r7, #52]
	b	.L1
.L76:
	mov	r3, #0
	mov	r0, r3
	mov	r2, r3
	b	.L17
.L22:
	mov	r2, r4
	ldr	r1, .L101+84
	mov	r0, #0
	bl	DPRINTFN
	b	.L19
.L35:
	mov	r2, r4
	ldr	r1, .L101+88
	mov	r0, #0
	bl	DPRINTFN
	b	.L19
.L102:
	.align	2
.L101:
	.word	.LC12
	.word	65535
	.word	.LC2
	.word	hid_endcollection
	.word	hid_feature
	.word	HIO_VARIABLE
	.word	MAXLOCCNT
	.word	hid_collection
	.word	hid_output
	.word	hid_input
	.word	.LC0
	.word	.LC11
	.word	MAXUSAGE
	.word	MAXPUSH
	.word	.LC10
	.word	.LC3
	.word	.LC4
	.word	.LC9
	.word	.LC7
	.word	.LC6
	.word	.LC1
	.word	.LC5
	.word	.LC8
	.size	hid_get_item, .-hid_get_item
	.comm	hid_output,4,4
	.comm	hid_input,4,4
	.comm	hid_feature,4,4
	.comm	hid_endcollection,4,4
	.comm	hid_collection,4,4
	.comm	MAXUSAGE,4,4
	.comm	MAXPUSH,4,4
	.comm	MAXLOCCNT,4,4
	.comm	HIO_VARIABLE,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
