	.file	"extr_et1310_eeprom.c_EepromReadByte.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	EepromReadByte
	.type	EepromReadByte, @function
EepromReadByte:
.LFB0:
	.cfi_startproc
	endbr64
	push	r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	push	r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	push	rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	sub	rsp, 16
	.cfi_def_cfa_offset 64
	mov	ecx, DWORD PTR MAX_NUM_REGISTER_POLLS[rip]
	mov	rbp, QWORD PTR [rdi]
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 8[rsp], rax
	xor	eax, eax
	mov	DWORD PTR 4[rsp], 0
	test	ecx, ecx
	jle	.L3
	mov	r13d, esi
	mov	r14, rdx
	lea	r12, 4[rsp]
	xor	ebx, ebx
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L33:
	mov	edi, DWORD PTR 4[rsp]
	call	EXTRACT_STATUS_REGISTER@PLT
	test	DWORD PTR LBCIF_STATUS_PHY_QUEUE_AVAIL[rip], eax
	je	.L4
	test	DWORD PTR LBCIF_STATUS_I2C_IDLE[rip], eax
	jne	.L5
.L4:
	add	ebx, 1
	cmp	DWORD PTR MAX_NUM_REGISTER_POLLS[rip], ebx
	jle	.L3
.L6:
	mov	esi, DWORD PTR LBCIF_DWORD1_GROUP_OFFSET[rip]
	mov	rdx, r12
	mov	rdi, rbp
	call	pci_read_config_dword@PLT
	test	rax, rax
	je	.L33
.L3:
	mov	eax, DWORD PTR FAILURE[rip]
.L1:
	mov	rcx, QWORD PTR 8[rsp]
	xor	rcx, QWORD PTR fs:40
	jne	.L34
	add	rsp, 16
	.cfi_remember_state
	.cfi_def_cfa_offset 48
	pop	rbx
	.cfi_def_cfa_offset 40
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L5:
	.cfi_restore_state
	cmp	DWORD PTR MAX_NUM_REGISTER_POLLS[rip], ebx
	jle	.L3
	mov	edx, DWORD PTR LBCIF_CONTROL_LBCIF_ENABLE[rip]
	mov	esi, DWORD PTR LBCIF_CONTROL_REGISTER_OFFSET[rip]
	mov	rdi, rbp
	call	pci_write_config_byte@PLT
	test	rax, rax
	jne	.L3
	mov	esi, DWORD PTR LBCIF_ADDRESS_REGISTER_OFFSET[rip]
	mov	edx, r13d
	mov	rdi, rbp
	call	pci_write_config_dword@PLT
	mov	r8, rax
	mov	eax, DWORD PTR FAILURE[rip]
	test	r8, r8
	jne	.L1
	mov	eax, DWORD PTR MAX_NUM_REGISTER_POLLS[rip]
	xor	r13d, r13d
	test	eax, eax
	jg	.L10
	jmp	.L3
	.p2align 4,,10
	.p2align 3
.L35:
	mov	edi, DWORD PTR 4[rsp]
	call	EXTRACT_STATUS_REGISTER@PLT
	mov	ebx, eax
	test	DWORD PTR LBCIF_STATUS_PHY_QUEUE_AVAIL[rip], eax
	je	.L13
	test	DWORD PTR LBCIF_STATUS_I2C_IDLE[rip], eax
	jne	.L14
.L13:
	add	r13d, 1
	cmp	DWORD PTR MAX_NUM_REGISTER_POLLS[rip], r13d
	jle	.L3
.L10:
	mov	esi, DWORD PTR LBCIF_DWORD1_GROUP_OFFSET[rip]
	mov	rdx, r12
	mov	rdi, rbp
	call	pci_read_config_dword@PLT
	test	rax, rax
	je	.L35
	jmp	.L3
.L14:
	cmp	DWORD PTR MAX_NUM_REGISTER_POLLS[rip], r13d
	jle	.L3
	mov	edi, DWORD PTR 4[rsp]
	call	EXTRACT_DATA_REGISTER@PLT
	mov	DWORD PTR [r14], eax
	mov	eax, DWORD PTR FAILURE[rip]
	test	DWORD PTR LBCIF_STATUS_ACK_ERROR[rip], ebx
	cmove	eax, DWORD PTR SUCCESS[rip]
	jmp	.L1
.L34:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	EepromReadByte, .-EepromReadByte
	.comm	SUCCESS,4,4
	.comm	MAX_NUM_REGISTER_POLLS,4,4
	.comm	LBCIF_STATUS_PHY_QUEUE_AVAIL,4,4
	.comm	LBCIF_STATUS_I2C_IDLE,4,4
	.comm	LBCIF_STATUS_ACK_ERROR,4,4
	.comm	LBCIF_DWORD1_GROUP_OFFSET,4,4
	.comm	LBCIF_CONTROL_REGISTER_OFFSET,4,4
	.comm	LBCIF_CONTROL_LBCIF_ENABLE,4,4
	.comm	LBCIF_ADDRESS_REGISTER_OFFSET,4,4
	.comm	FAILURE,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_et1310_eeprom.c_EepromReadByte.c"
	.text
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC0:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	EepromReadByte
	.syntax unified
	.arm
	.fpu softvfp
	.type	EepromReadByte, %function
EepromReadByte:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	mov	r4, #0
	ldr	r5, .L35
	sub	sp, sp, #12
	ldr	r3, [r5]
	ldr	r6, [r0]
	cmp	r3, r4
	ldr	r3, .L35+4
	ldr	r3, [r3]
	str	r3, [sp, #4]
	mov	r3,#0
	str	r4, [sp]
	ble	.L3
	mov	r10, r1
	mov	fp, r2
	ldr	r7, .L35+8
	ldr	r8, .L35+12
	ldr	r9, .L35+16
	b	.L6
.L32:
	ldr	r0, [sp]
	bl	EXTRACT_STATUS_REGISTER
	ldr	r3, [r8]
	tst	r0, r3
	beq	.L4
	ldr	r3, [r9]
	tst	r0, r3
	bne	.L5
.L4:
	ldr	r3, [r5]
	add	r4, r4, #1
	cmp	r3, r4
	ble	.L3
.L6:
	mov	r2, sp
	mov	r0, r6
	ldr	r1, [r7]
	bl	pci_read_config_dword
	cmp	r0, #0
	beq	.L32
.L3:
	ldr	r3, .L35+20
	ldr	r0, [r3]
.L1:
	ldr	r3, .L35+4
	ldr	r2, [r3]
	ldr	r3, [sp, #4]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L33
	add	sp, sp, #12
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L5:
	ldr	r3, [r5]
	cmp	r3, r4
	ble	.L3
	ldr	r3, .L35+24
	ldr	r2, .L35+28
	mov	r0, r6
	ldr	r2, [r2]
	ldr	r1, [r3]
	bl	pci_write_config_byte
	cmp	r0, #0
	bne	.L3
	ldr	r3, .L35+32
	mov	r2, r10
	mov	r0, r6
	ldr	r1, [r3]
	bl	pci_write_config_dword
	subs	r10, r0, #0
	bne	.L3
	ldr	r3, [r5]
	cmp	r3, #0
	bgt	.L10
	b	.L3
.L34:
	ldr	r0, [sp]
	bl	EXTRACT_STATUS_REGISTER
	ldr	r3, [r8]
	mov	r4, r0
	tst	r0, r3
	beq	.L13
	ldr	r3, [r9]
	tst	r0, r3
	bne	.L14
.L13:
	ldr	r3, [r5]
	add	r10, r10, #1
	cmp	r3, r10
	ble	.L3
.L10:
	mov	r2, sp
	mov	r0, r6
	ldr	r1, [r7]
	bl	pci_read_config_dword
	cmp	r0, #0
	beq	.L34
	b	.L3
.L14:
	ldr	r3, [r5]
	cmp	r3, r10
	ble	.L3
	ldr	r0, [sp]
	bl	EXTRACT_DATA_REGISTER
	ldr	r3, .L35+36
	str	r0, [fp]
	ldr	r3, [r3]
	tst	r4, r3
	bne	.L3
	ldr	r3, .L35+40
	ldr	r0, [r3]
	b	.L1
.L33:
	bl	__stack_chk_fail
.L36:
	.align	2
.L35:
	.word	MAX_NUM_REGISTER_POLLS
	.word	.LC0
	.word	LBCIF_DWORD1_GROUP_OFFSET
	.word	LBCIF_STATUS_PHY_QUEUE_AVAIL
	.word	LBCIF_STATUS_I2C_IDLE
	.word	FAILURE
	.word	LBCIF_CONTROL_REGISTER_OFFSET
	.word	LBCIF_CONTROL_LBCIF_ENABLE
	.word	LBCIF_ADDRESS_REGISTER_OFFSET
	.word	LBCIF_STATUS_ACK_ERROR
	.word	SUCCESS
	.size	EepromReadByte, .-EepromReadByte
	.comm	SUCCESS,4,4
	.comm	MAX_NUM_REGISTER_POLLS,4,4
	.comm	LBCIF_STATUS_PHY_QUEUE_AVAIL,4,4
	.comm	LBCIF_STATUS_I2C_IDLE,4,4
	.comm	LBCIF_STATUS_ACK_ERROR,4,4
	.comm	LBCIF_DWORD1_GROUP_OFFSET,4,4
	.comm	LBCIF_CONTROL_REGISTER_OFFSET,4,4
	.comm	LBCIF_CONTROL_LBCIF_ENABLE,4,4
	.comm	LBCIF_ADDRESS_REGISTER_OFFSET,4,4
	.comm	FAILURE,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
