	.file	"extr_phy.c_e1000e_copper_link_setup_igp.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"Error resetting the PHY.\n"
.LC1:
	.string	"Error Disabling LPLU D0\n"
	.text
	.p2align 4
	.globl	e1000e_copper_link_setup_igp
	.type	e1000e_copper_link_setup_igp, @function
e1000e_copper_link_setup_igp:
.LFB0:
	.cfi_startproc
	endbr64
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	push	r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	push	rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	mov	rbp, rdi
	sub	rsp, 16
	.cfi_def_cfa_offset 48
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 8[rsp], rax
	xor	eax, eax
	call	e1000_phy_hw_reset@PLT
	test	rax, rax
	jne	.L27
	mov	edi, 100
	call	msleep@PLT
	mov	rax, QWORD PTR 24[rbp]
	test	rax, rax
	je	.L4
	xor	esi, esi
	mov	rdi, rbp
	call	rax
	mov	r12, rax
	test	rax, rax
	jne	.L28
.L4:
	mov	esi, DWORD PTR IGP01E1000_PHY_PORT_CTRL[rip]
	lea	r13, 4[rsp]
	mov	rdi, rbp
	mov	rdx, r13
	call	e1e_rphy@PLT
	mov	r12, rax
	test	rax, rax
	jne	.L1
	mov	esi, DWORD PTR IGP01E1000_PSCR_AUTO_MDIX[rip]
	mov	ecx, DWORD PTR 4[rsp]
	mov	eax, DWORD PTR 8[rbp]
	mov	edx, esi
	not	edx
	and	edx, ecx
	cmp	eax, 1
	je	.L5
	cmp	eax, 2
	jne	.L29
	or	edx, DWORD PTR IGP01E1000_PSCR_FORCE_MDI_MDIX[rip]
	mov	DWORD PTR 4[rsp], edx
.L8:
	mov	esi, DWORD PTR IGP01E1000_PHY_PORT_CTRL[rip]
	mov	rdi, rbp
	call	e1e_wphy@PLT
	mov	r12, rax
	test	rax, rax
	jne	.L1
	mov	r12, QWORD PTR 0[rbp]
	test	r12, r12
	je	.L1
	mov	rax, QWORD PTR ADVERTISE_1000_FULL[rip]
	cmp	QWORD PTR 16[rbp], rax
	je	.L9
.L10:
	mov	rdi, rbp
	call	e1000_set_master_slave_mode@PLT
	mov	r12, rax
	.p2align 4,,10
	.p2align 3
.L1:
	mov	rax, QWORD PTR 8[rsp]
	xor	rax, QWORD PTR fs:40
	jne	.L30
	add	rsp, 16
	.cfi_remember_state
	.cfi_def_cfa_offset 32
	mov	rax, r12
	pop	rbp
	.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
.L27:
	.cfi_restore_state
	lea	rdi, .LC0[rip]
	mov	r12, rax
	call	e_dbg@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L29:
	or	esi, ecx
	mov	DWORD PTR 4[rsp], esi
	mov	edx, esi
	jmp	.L8
	.p2align 4,,10
	.p2align 3
.L28:
	lea	rdi, .LC1[rip]
	call	e_dbg@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L5:
	mov	eax, DWORD PTR IGP01E1000_PSCR_FORCE_MDI_MDIX[rip]
	not	eax
	and	edx, eax
	mov	DWORD PTR 4[rsp], edx
	jmp	.L8
	.p2align 4,,10
	.p2align 3
.L9:
	mov	esi, DWORD PTR IGP01E1000_PHY_PORT_CONFIG[rip]
	mov	rdx, r13
	mov	rdi, rbp
	call	e1e_rphy@PLT
	mov	r12, rax
	test	rax, rax
	jne	.L1
	mov	edx, DWORD PTR IGP01E1000_PSCFR_SMART_SPEED[rip]
	mov	esi, DWORD PTR IGP01E1000_PHY_PORT_CONFIG[rip]
	mov	rdi, rbp
	not	edx
	and	edx, DWORD PTR 4[rsp]
	mov	DWORD PTR 4[rsp], edx
	call	e1e_wphy@PLT
	mov	r12, rax
	test	rax, rax
	jne	.L1
	mov	esi, DWORD PTR MII_CTRL1000[rip]
	mov	rdx, r13
	mov	rdi, rbp
	call	e1e_rphy@PLT
	mov	r12, rax
	test	rax, rax
	jne	.L1
	mov	edx, DWORD PTR CTL1000_ENABLE_MASTER[rip]
	mov	esi, DWORD PTR MII_CTRL1000[rip]
	mov	rdi, rbp
	not	edx
	and	edx, DWORD PTR 4[rsp]
	mov	DWORD PTR 4[rsp], edx
	call	e1e_wphy@PLT
	mov	r12, rax
	test	rax, rax
	je	.L10
	jmp	.L1
.L30:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	e1000e_copper_link_setup_igp, .-e1000e_copper_link_setup_igp
	.comm	MII_CTRL1000,4,4
	.comm	IGP01E1000_PSCR_FORCE_MDI_MDIX,4,4
	.comm	IGP01E1000_PSCR_AUTO_MDIX,4,4
	.comm	IGP01E1000_PSCFR_SMART_SPEED,4,4
	.comm	IGP01E1000_PHY_PORT_CTRL,4,4
	.comm	IGP01E1000_PHY_PORT_CONFIG,4,4
	.comm	CTL1000_ENABLE_MASTER,4,4
	.comm	ADVERTISE_1000_FULL,8,8
	.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_phy.c_e1000e_copper_link_setup_igp.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"Error resetting the PHY.\012\000"
	.align	2
.LC1:
	.ascii	"Error Disabling LPLU D0\012\000"
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC2:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	e1000e_copper_link_setup_igp
	.syntax unified
	.arm
	.fpu softvfp
	.type	e1000e_copper_link_setup_igp, %function
e1000e_copper_link_setup_igp:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, lr}
	ldr	r3, .L31
	sub	sp, sp, #8
	ldr	r3, [r3]
	str	r3, [sp, #4]
	mov	r3,#0
	mov	r5, r0
	bl	e1000_phy_hw_reset
	subs	r4, r0, #0
	bne	.L27
	mov	r0, #100
	bl	msleep
	ldr	r3, [r5, #12]
	cmp	r3, #0
	beq	.L4
	mov	r1, r4
	mov	r0, r5
	blx	r3
	subs	r4, r0, #0
	bne	.L28
.L4:
	ldr	r6, .L31+4
	mov	r2, sp
	mov	r0, r5
	ldr	r1, [r6]
	bl	e1e_rphy
	subs	r4, r0, #0
	bne	.L1
	ldr	r2, .L31+8
	ldr	r3, [r5, #4]
	ldr	r0, [r2]
	ldr	r1, [sp]
	cmp	r3, #1
	bic	r2, r1, r0
	beq	.L5
	cmp	r3, #2
	bne	.L29
	ldr	r3, .L31+12
	ldr	r3, [r3]
	orr	r2, r2, r3
	str	r2, [sp]
.L8:
	mov	r0, r5
	ldr	r1, [r6]
	bl	e1e_wphy
	subs	r4, r0, #0
	bne	.L1
	ldr	r4, [r5]
	cmp	r4, #0
	beq	.L1
	ldr	r3, .L31+16
	ldr	r2, [r5, #8]
	ldr	r3, [r3]
	cmp	r2, r3
	beq	.L9
.L10:
	mov	r0, r5
	bl	e1000_set_master_slave_mode
	mov	r4, r0
.L1:
	ldr	r3, .L31
	ldr	r2, [r3]
	ldr	r3, [sp, #4]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L30
	mov	r0, r4
	add	sp, sp, #8
	@ sp needed
	pop	{r4, r5, r6, pc}
.L27:
	ldr	r0, .L31+20
	bl	e_dbg
	b	.L1
.L29:
	orr	r2, r0, r1
	str	r2, [sp]
	b	.L8
.L28:
	ldr	r0, .L31+24
	bl	e_dbg
	b	.L1
.L5:
	ldr	r3, .L31+12
	ldr	r3, [r3]
	bic	r2, r2, r3
	str	r2, [sp]
	b	.L8
.L9:
	ldr	r6, .L31+28
	mov	r2, sp
	mov	r0, r5
	ldr	r1, [r6]
	bl	e1e_rphy
	subs	r4, r0, #0
	bne	.L1
	ldr	r3, .L31+32
	ldr	r2, [sp]
	ldr	r3, [r3]
	mov	r0, r5
	bic	r2, r2, r3
	ldr	r1, [r6]
	str	r2, [sp]
	bl	e1e_wphy
	subs	r4, r0, #0
	bne	.L1
	ldr	r6, .L31+36
	mov	r2, sp
	mov	r0, r5
	ldr	r1, [r6]
	bl	e1e_rphy
	subs	r4, r0, #0
	bne	.L1
	ldr	r3, .L31+40
	ldr	r2, [sp]
	ldr	r3, [r3]
	mov	r0, r5
	bic	r2, r2, r3
	ldr	r1, [r6]
	str	r2, [sp]
	bl	e1e_wphy
	subs	r4, r0, #0
	beq	.L10
	b	.L1
.L30:
	bl	__stack_chk_fail
.L32:
	.align	2
.L31:
	.word	.LC2
	.word	IGP01E1000_PHY_PORT_CTRL
	.word	IGP01E1000_PSCR_AUTO_MDIX
	.word	IGP01E1000_PSCR_FORCE_MDI_MDIX
	.word	ADVERTISE_1000_FULL
	.word	.LC0
	.word	.LC1
	.word	IGP01E1000_PHY_PORT_CONFIG
	.word	IGP01E1000_PSCFR_SMART_SPEED
	.word	MII_CTRL1000
	.word	CTL1000_ENABLE_MASTER
	.size	e1000e_copper_link_setup_igp, .-e1000e_copper_link_setup_igp
	.comm	MII_CTRL1000,4,4
	.comm	IGP01E1000_PSCR_FORCE_MDI_MDIX,4,4
	.comm	IGP01E1000_PSCR_AUTO_MDIX,4,4
	.comm	IGP01E1000_PSCFR_SMART_SPEED,4,4
	.comm	IGP01E1000_PHY_PORT_CTRL,4,4
	.comm	IGP01E1000_PHY_PORT_CONFIG,4,4
	.comm	CTL1000_ENABLE_MASTER,4,4
	.comm	ADVERTISE_1000_FULL,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
