	.file	"extr_ks7010_sdio.c_write_to_device.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"unknown event=%04X\n"
.LC1:
	.string	"write DATA_WINDOW\n"
.LC2:
	.string	"write WRITE_STATUS_REG\n"
	.text
	.p2align 4
	.type	write_to_device, @function
write_to_device:
.LFB0:
	.cfi_startproc
	endbr64
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	mov	r13, rdx
	push	r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	mov	r12, rsi
	push	rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	mov	rbx, rdi
	mov	edi, DWORD PTR [rsi]
	call	le16_to_cpu@PLT
	cmp	rax, QWORD PTR HIF_DATA_REQ[rip]
	jl	.L4
	mov	edi, DWORD PTR [r12]
	call	le16_to_cpu@PLT
	cmp	rax, QWORD PTR HIF_REQ_MAX[rip]
	jle	.L11
.L4:
	mov	edx, DWORD PTR [r12]
	mov	edi, DWORD PTR [rbx]
	lea	rsi, .LC0[rip]
	xor	eax, eax
	xor	r12d, r12d
	call	netdev_err@PLT
.L1:
	mov	eax, r12d
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L11:
	.cfi_restore_state
	mov	esi, DWORD PTR DATA_WINDOW[rip]
	mov	rdx, r12
	mov	rcx, r13
	mov	rdi, rbx
	call	ks7010_sdio_write@PLT
	mov	r12d, eax
	test	eax, eax
	jne	.L12
	mov	edx, DWORD PTR REG_STATUS_BUSY[rip]
	mov	esi, DWORD PTR WRITE_STATUS_REG[rip]
	mov	rdi, rbx
	call	ks7010_sdio_writeb@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L1
	mov	edi, DWORD PTR [rbx]
	lea	rsi, .LC2[rip]
	xor	eax, eax
	call	netdev_err@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L12:
	mov	edi, DWORD PTR [rbx]
	lea	rsi, .LC1[rip]
	xor	eax, eax
	call	netdev_err@PLT
	mov	eax, r12d
	pop	rbx
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE0:
	.size	write_to_device, .-write_to_device
	.comm	WRITE_STATUS_REG,4,4
	.comm	REG_STATUS_BUSY,4,4
	.comm	HIF_REQ_MAX,8,8
	.comm	HIF_DATA_REQ,8,8
	.comm	DATA_WINDOW,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_ks7010_sdio.c_write_to_device.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"unknown event=%04X\012\000"
	.align	2
.LC1:
	.ascii	"write DATA_WINDOW\012\000"
	.align	2
.LC2:
	.ascii	"write WRITE_STATUS_REG\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	write_to_device, %function
write_to_device:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, lr}
	mov	r5, r0
	ldr	r0, [r1]
	mov	r4, r1
	mov	r6, r2
	bl	le16_to_cpu
	ldr	r3, .L13
	ldr	r3, [r3]
	cmp	r0, r3
	blt	.L4
	ldr	r0, [r4]
	bl	le16_to_cpu
	ldr	r3, .L13+4
	ldr	r3, [r3]
	cmp	r0, r3
	ble	.L11
.L4:
	ldr	r2, [r4]
	ldr	r0, [r5]
	ldr	r1, .L13+8
	bl	netdev_err
	mov	r4, #0
.L1:
	mov	r0, r4
	pop	{r4, r5, r6, pc}
.L11:
	ldr	r1, .L13+12
	mov	r2, r4
	mov	r3, r6
	mov	r0, r5
	ldr	r1, [r1]
	bl	ks7010_sdio_write
	subs	r4, r0, #0
	bne	.L12
	ldr	r3, .L13+16
	ldr	r2, .L13+20
	mov	r0, r5
	ldr	r2, [r2]
	ldr	r1, [r3]
	bl	ks7010_sdio_writeb
	subs	r4, r0, #0
	beq	.L1
	ldr	r0, [r5]
	ldr	r1, .L13+24
	bl	netdev_err
	b	.L1
.L12:
	ldr	r0, [r5]
	ldr	r1, .L13+28
	bl	netdev_err
	mov	r0, r4
	pop	{r4, r5, r6, pc}
.L14:
	.align	2
.L13:
	.word	HIF_DATA_REQ
	.word	HIF_REQ_MAX
	.word	.LC0
	.word	DATA_WINDOW
	.word	WRITE_STATUS_REG
	.word	REG_STATUS_BUSY
	.word	.LC2
	.word	.LC1
	.size	write_to_device, .-write_to_device
	.comm	WRITE_STATUS_REG,4,4
	.comm	REG_STATUS_BUSY,4,4
	.comm	HIF_REQ_MAX,4,4
	.comm	HIF_DATA_REQ,4,4
	.comm	DATA_WINDOW,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
