	.file	"extr_bluecard_cs.c_bluecard_receive.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"Unknown device"
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC1:
	.string	"Can't allocate mem for new packet"
	.align 8
.LC2:
	.string	"Unknown HCI packet with type 0x%02x received"
	.text
	.p2align 4
	.type	bluecard_receive, @function
bluecard_receive:
.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, 56
	.cfi_def_cfa_offset 112
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 40[rsp], rax
	xor	eax, eax
	test	rdi, rdi
	je	.L36
	mov	rax, QWORD PTR 40[rdi]
	lea	r14, 32[rdi]
	mov	rbx, rdi
	mov	r13d, esi
	mov	edi, DWORD PTR XMIT_SENDING_READY[rip]
	mov	rsi, r14
	mov	r12d, DWORD PTR [rax]
	call	test_bit@PLT
	test	rax, rax
	jne	.L37
.L4:
	mov	r15, rsp
	mov	edi, r12d
	mov	ecx, 31
	mov	esi, r13d
	mov	rdx, r15
	call	bluecard_read@PLT
	mov	r12d, eax
	lea	eax, -1[rax]
	lea	rbp, 1[rsp+rax]
	test	r12d, r12d
	jg	.L23
	jmp	.L24
	.p2align 4,,10
	.p2align 3
.L9:
	mov	esi, 1
	call	skb_put@PLT
	movzx	ecx, BYTE PTR [r15]
	mov	BYTE PTR [rax], cl
	sub	QWORD PTR 8[rbx], 1
	jne	.L17
	mov	eax, DWORD PTR [rbx]
	cmp	eax, 130
	je	.L18
	jg	.L19
	cmp	eax, 128
	je	.L20
	cmp	eax, 129
	jne	.L17
	mov	rdi, QWORD PTR 24[rbx]
	call	hci_event_hdr@PLT
	mov	DWORD PTR [rbx], 130
	mov	rax, QWORD PTR [rax]
	mov	QWORD PTR 8[rbx], rax
	.p2align 4,,10
	.p2align 3
.L17:
	add	r15, 1
	cmp	rbp, r15
	je	.L24
.L23:
	mov	rdi, QWORD PTR 24[rbx]
	mov	eax, DWORD PTR RECV_WAIT_PACKET_TYPE[rip]
	test	rdi, rdi
	je	.L38
.L7:
	cmp	DWORD PTR [rbx], eax
	jne	.L9
	mov	rax, QWORD PTR 16[rbx]
	mov	QWORD PTR [rdi], rax
	call	bt_cb@PLT
	movzx	ecx, BYTE PTR [r15]
	mov	BYTE PTR [rax], cl
	mov	rdi, QWORD PTR 24[rbx]
	call	bt_cb@PLT
	movzx	eax, BYTE PTR [rax]
	cmp	al, -123
	je	.L10
	ja	.L11
	test	al, al
	je	.L12
	cmp	al, -124
	jne	.L14
	mov	rax, QWORD PTR HCI_SCO_HDR_SIZE[rip]
	add	r15, 1
	mov	DWORD PTR [rbx], 128
	mov	QWORD PTR 8[rbx], rax
	cmp	rbp, r15
	jne	.L23
	.p2align 4,,10
	.p2align 3
.L24:
	mov	rax, QWORD PTR 16[rbx]
	add	DWORD PTR [rax], r12d
.L1:
	mov	rax, QWORD PTR 40[rsp]
	xor	rax, QWORD PTR fs:40
	jne	.L39
	add	rsp, 56
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	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
.L11:
	.cfi_restore_state
	cmp	al, -122
	jne	.L14
	mov	rax, QWORD PTR HCI_ACL_HDR_SIZE[rip]
	mov	DWORD PTR [rbx], 131
	mov	QWORD PTR 8[rbx], rax
	jmp	.L17
	.p2align 4,,10
	.p2align 3
.L19:
	cmp	eax, 131
	jne	.L17
	mov	rdi, QWORD PTR 24[rbx]
	call	hci_acl_hdr@PLT
	mov	edi, DWORD PTR [rax]
	call	__le16_to_cpu@PLT
	mov	DWORD PTR [rbx], 130
	cdqe
	mov	QWORD PTR 8[rbx], rax
	jmp	.L17
	.p2align 4,,10
	.p2align 3
.L38:
	mov	edi, DWORD PTR HCI_MAX_FRAME_SIZE[rip]
	mov	esi, DWORD PTR GFP_ATOMIC[rip]
	mov	DWORD PTR [rbx], eax
	mov	QWORD PTR 8[rbx], 0
	call	bt_skb_alloc@PLT
	mov	QWORD PTR 24[rbx], rax
	mov	rdi, rax
	test	rax, rax
	je	.L8
	mov	eax, DWORD PTR RECV_WAIT_PACKET_TYPE[rip]
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L10:
	mov	rax, QWORD PTR HCI_EVENT_HDR_SIZE[rip]
	mov	DWORD PTR [rbx], 129
	mov	QWORD PTR 8[rbx], rax
	jmp	.L17
	.p2align 4,,10
	.p2align 3
.L14:
	mov	rdi, QWORD PTR 24[rbx]
	call	bt_cb@PLT
	lea	rdi, .LC2[rip]
	movzx	esi, BYTE PTR [rax]
	xor	eax, eax
	call	BT_ERR@PLT
	mov	rax, QWORD PTR 16[rbx]
	add	DWORD PTR 4[rax], 1
.L34:
	mov	rdi, QWORD PTR 24[rbx]
	call	kfree_skb@PLT
	mov	QWORD PTR 24[rbx], 0
	jmp	.L17
	.p2align 4,,10
	.p2align 3
.L12:
	test	r13d, r13d
	je	.L34
	mov	edi, DWORD PTR XMIT_BUF_ONE_READY[rip]
	mov	rsi, r14
	call	set_bit@PLT
	mov	edi, DWORD PTR XMIT_BUF_TWO_READY[rip]
	mov	rsi, r14
	call	set_bit@PLT
	mov	edi, DWORD PTR XMIT_SENDING_READY[rip]
	mov	rsi, r14
	call	set_bit@PLT
	mov	rdi, rbx
	call	bluecard_write_wakeup@PLT
	jmp	.L34
	.p2align 4,,10
	.p2align 3
.L18:
	mov	rdi, QWORD PTR 24[rbx]
	call	hci_recv_frame@PLT
	mov	QWORD PTR 24[rbx], 0
	jmp	.L17
	.p2align 4,,10
	.p2align 3
.L20:
	mov	rdi, QWORD PTR 24[rbx]
	call	hci_sco_hdr@PLT
	mov	DWORD PTR [rbx], 130
	movsx	rax, DWORD PTR [rax]
	mov	QWORD PTR 8[rbx], rax
	jmp	.L17
	.p2align 4,,10
	.p2align 3
.L37:
	mov	rdi, rbx
	call	bluecard_enable_activity_led@PLT
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L36:
	lea	rdi, .LC0[rip]
	call	BT_ERR@PLT
	jmp	.L1
.L8:
	lea	rdi, .LC1[rip]
	xor	eax, eax
	call	BT_ERR@PLT
	jmp	.L1
.L39:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	bluecard_receive, .-bluecard_receive
	.comm	XMIT_SENDING_READY,4,4
	.comm	XMIT_BUF_TWO_READY,4,4
	.comm	XMIT_BUF_ONE_READY,4,4
	.comm	RECV_WAIT_PACKET_TYPE,4,4
	.comm	HCI_SCO_HDR_SIZE,8,8
	.comm	HCI_MAX_FRAME_SIZE,4,4
	.comm	HCI_EVENT_HDR_SIZE,8,8
	.comm	HCI_ACL_HDR_SIZE,8,8
	.comm	GFP_ATOMIC,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_bluecard_cs.c_bluecard_receive.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"Unknown device\000"
	.align	2
.LC1:
	.ascii	"Can't allocate mem for new packet\000"
	.align	2
.LC2:
	.ascii	"Unknown HCI packet with type 0x%02x received\000"
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC3:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	bluecard_receive, %function
bluecard_receive:
	@ args = 0, pretend = 0, frame = 48
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	ldr	r3, .L41
	sub	sp, sp, #52
	subs	r4, r0, #0
	ldr	r3, [r3]
	str	r3, [sp, #44]
	mov	r3,#0
	beq	.L35
	ldr	r2, .L41+4
	ldr	r3, [r4, #20]
	add	r10, r4, #16
	mov	r7, r1
	ldr	r0, [r2]
	mov	r1, r10
	ldr	r5, [r3]
	bl	test_bit
	cmp	r0, #0
	bne	.L36
.L4:
	mov	r3, #31
	mov	r0, r5
	mov	r1, r7
	add	r2, sp, #12
	bl	bluecard_read
	subs	r3, r0, #0
	str	r3, [sp, #4]
	ble	.L24
	ldr	r3, [sp, #4]
	add	fp, sp, #12
	ldr	r5, .L41+8
	ldr	r9, .L41+12
	ldr	r8, .L41+16
	add	r6, fp, r3
.L23:
	ldr	r0, [r4, #12]
	ldr	r3, [r5]
	cmp	r0, #0
	beq	.L37
.L7:
	ldr	r2, [r4]
	cmp	r2, r3
	beq	.L38
	mov	r1, #1
	bl	skb_put
	ldrb	r3, [fp]	@ zero_extendqisi2
	strb	r3, [r0]
	ldr	r3, [r4, #4]
	sub	r3, r3, #1
	cmp	r3, #0
	str	r3, [r4, #4]
	bne	.L17
	ldr	r3, [r4]
	sub	r3, r3, #128
	cmp	r3, #3
	ldrls	pc, [pc, r3, asl #2]
	b	.L17
.L19:
	.word	.L22
	.word	.L21
	.word	.L20
	.word	.L18
.L18:
	ldr	r0, [r4, #12]
	bl	hci_acl_hdr
	ldr	r0, [r0]
	bl	__le16_to_cpu
	mov	r3, #130
	str	r0, [r4, #4]
	str	r3, [r4]
.L17:
	add	fp, fp, #1
	cmp	r6, fp
	bne	.L23
.L24:
	ldr	r3, [r4, #8]
	ldr	r2, [sp, #4]
	ldr	r0, [r3]
	add	r0, r0, r2
	str	r0, [r3]
.L1:
	ldr	r3, .L41
	ldr	r2, [r3]
	ldr	r3, [sp, #44]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L39
	add	sp, sp, #52
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L21:
	ldr	r0, [r4, #12]
	bl	hci_event_hdr
	mov	r2, #130
	ldr	r3, [r0]
	stm	r4, {r2, r3}
	b	.L17
.L22:
	ldr	r0, [r4, #12]
	bl	hci_sco_hdr
	mov	r2, #130
	ldr	r3, [r0]
	stm	r4, {r2, r3}
	b	.L17
.L20:
	ldr	r0, [r4, #12]
	bl	hci_recv_frame
	mov	r3, #0
	str	r3, [r4, #12]
	b	.L17
.L38:
	ldr	r3, [r4, #8]
	str	r3, [r0]
	bl	bt_cb
	ldrb	r3, [fp]	@ zero_extendqisi2
	strb	r3, [r0]
	ldr	r0, [r4, #12]
	bl	bt_cb
	ldrb	r3, [r0]	@ zero_extendqisi2
	cmp	r3, #133
	beq	.L10
	bhi	.L11
	cmp	r3, #0
	beq	.L12
	cmp	r3, #132
	bne	.L14
	mov	r2, #128
	ldr	r3, .L41+20
	str	r2, [r4]
	ldr	r3, [r3]
	str	r3, [r4, #4]
	b	.L17
.L11:
	cmp	r3, #134
	bne	.L14
	mov	r2, #131
	ldr	r3, .L41+24
	ldr	r3, [r3]
	stm	r4, {r2, r3}
	b	.L17
.L37:
	str	r0, [r4, #4]
	ldr	r1, [r9]
	ldr	r0, [r8]
	str	r3, [r4]
	bl	bt_skb_alloc
	cmp	r0, #0
	str	r0, [r4, #12]
	beq	.L8
	ldr	r3, [r5]
	b	.L7
.L10:
	mov	r2, #129
	ldr	r3, .L41+28
	ldr	r3, [r3]
	stm	r4, {r2, r3}
	b	.L17
.L14:
	ldr	r0, [r4, #12]
	bl	bt_cb
	mov	r3, r0
	ldr	r0, .L41+32
	ldrb	r1, [r3]	@ zero_extendqisi2
	bl	BT_ERR
	ldr	r2, [r4, #8]
	ldr	r0, [r4, #12]
	ldr	r3, [r2, #4]
	add	r3, r3, #1
	str	r3, [r2, #4]
	bl	kfree_skb
	mov	r3, #0
	str	r3, [r4, #12]
	b	.L17
.L12:
	cmp	r7, #0
	bne	.L40
.L16:
	ldr	r0, [r4, #12]
	bl	kfree_skb
	mov	r3, #0
	str	r3, [r4, #12]
	b	.L17
.L36:
	mov	r0, r4
	bl	bluecard_enable_activity_led
	b	.L4
.L40:
	ldr	r3, .L41+36
	mov	r1, r10
	ldr	r0, [r3]
	bl	set_bit
	ldr	r3, .L41+40
	mov	r1, r10
	ldr	r0, [r3]
	bl	set_bit
	ldr	r3, .L41+4
	mov	r1, r10
	ldr	r0, [r3]
	bl	set_bit
	mov	r0, r4
	bl	bluecard_write_wakeup
	b	.L16
.L35:
	ldr	r0, .L41+44
	bl	BT_ERR
	b	.L1
.L8:
	ldr	r0, .L41+48
	bl	BT_ERR
	b	.L1
.L39:
	bl	__stack_chk_fail
.L42:
	.align	2
.L41:
	.word	.LC3
	.word	XMIT_SENDING_READY
	.word	RECV_WAIT_PACKET_TYPE
	.word	GFP_ATOMIC
	.word	HCI_MAX_FRAME_SIZE
	.word	HCI_SCO_HDR_SIZE
	.word	HCI_ACL_HDR_SIZE
	.word	HCI_EVENT_HDR_SIZE
	.word	.LC2
	.word	XMIT_BUF_ONE_READY
	.word	XMIT_BUF_TWO_READY
	.word	.LC0
	.word	.LC1
	.size	bluecard_receive, .-bluecard_receive
	.comm	XMIT_SENDING_READY,4,4
	.comm	XMIT_BUF_TWO_READY,4,4
	.comm	XMIT_BUF_ONE_READY,4,4
	.comm	RECV_WAIT_PACKET_TYPE,4,4
	.comm	HCI_SCO_HDR_SIZE,4,4
	.comm	HCI_MAX_FRAME_SIZE,4,4
	.comm	HCI_EVENT_HDR_SIZE,4,4
	.comm	HCI_ACL_HDR_SIZE,4,4
	.comm	GFP_ATOMIC,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
