	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function e1000_setup_copper_link
_e1000_setup_copper_link:               ## @e1000_setup_copper_link
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	callq	_e1000_copper_link_preconfig
	movq	%rax, %rbx
	testq	%rax, %rax
	jne	LBB0_23
## %bb.1:
	movq	(%r14), %rax
	movq	_e1000_phy_igp@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_3
## %bb.2:
	movq	%r14, %rdi
	callq	_e1000_copper_link_igp_setup
	jmp	LBB0_5
LBB0_3:
	movq	_e1000_phy_m88@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_6
## %bb.4:
	movq	%r14, %rdi
	callq	_e1000_copper_link_mgp_setup
LBB0_5:
	movq	%rax, %rbx
	testq	%rax, %rax
	jne	LBB0_23
	jmp	LBB0_8
LBB0_6:
	movq	%r14, %rdi
	callq	_gbe_dhg_phy_setup
	testq	%rax, %rax
	je	LBB0_8
## %bb.7:
	movq	%rax, %rbx
	leaq	L_.str(%rip), %rdi
	callq	_e_dbg
	jmp	LBB0_23
LBB0_8:
	cmpq	$0, 8(%r14)
	je	LBB0_10
## %bb.9:
	movq	%r14, %rdi
	callq	_e1000_copper_link_autoneg
	movq	%rax, %rbx
	testq	%rax, %rax
	jne	LBB0_23
	jmp	LBB0_12
LBB0_10:
	leaq	L_.str.1(%rip), %rdi
	callq	_e_dbg
	movq	%r14, %rdi
	callq	_e1000_phy_force_speed_duplex
	testq	%rax, %rax
	je	LBB0_12
## %bb.11:
	movq	%rax, %rbx
	leaq	L_.str.2(%rip), %rdi
	callq	_e_dbg
	jmp	LBB0_23
LBB0_12:
	movl	$10, %r12d
	movq	_PHY_STATUS@GOTPCREL(%rip), %r13
	leaq	-44(%rbp), %r15
	.p2align	4, 0x90
LBB0_13:                                ## =>This Inner Loop Header: Depth=1
	movl	(%r13), %esi
	movq	%r14, %rdi
	movq	%r15, %rdx
	callq	_e1000_read_phy_reg
	testq	%rax, %rax
	jne	LBB0_19
## %bb.14:                              ##   in Loop: Header=BB0_13 Depth=1
	movl	(%r13), %esi
	movq	%r14, %rdi
	movq	%r15, %rdx
	callq	_e1000_read_phy_reg
	testq	%rax, %rax
	jne	LBB0_19
## %bb.15:                              ##   in Loop: Header=BB0_13 Depth=1
	movq	_MII_SR_LINK_STATUS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, -44(%rbp)
	jne	LBB0_20
## %bb.16:                              ##   in Loop: Header=BB0_13 Depth=1
	movl	$10, %edi
	callq	_udelay
	decl	%r12d
	jne	LBB0_13
## %bb.17:
	leaq	L_.str.4(%rip), %rdi
	jmp	LBB0_22
LBB0_19:
	movq	%rax, %rbx
	jmp	LBB0_23
LBB0_20:
	movq	%r14, %rdi
	callq	_e1000_copper_link_postconfig
	movq	%rax, %rbx
	testq	%rax, %rax
	jne	LBB0_23
## %bb.21:
	leaq	L_.str.3(%rip), %rdi
LBB0_22:
	callq	_e_dbg
	movq	_E1000_SUCCESS@GOTPCREL(%rip), %rax
	movq	(%rax), %rbx
LBB0_23:
	movq	%rbx, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_e1000_phy_igp,8,3              ## @e1000_phy_igp
	.comm	_e1000_phy_m88,8,3              ## @e1000_phy_m88
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"gbe_dhg_phy_setup failed!\n"

L_.str.1:                               ## @.str.1
	.asciz	"Forcing speed and duplex\n"

L_.str.2:                               ## @.str.2
	.asciz	"Error Forcing Speed and Duplex\n"

	.comm	_PHY_STATUS,4,2                 ## @PHY_STATUS
	.comm	_MII_SR_LINK_STATUS,4,2         ## @MII_SR_LINK_STATUS
L_.str.3:                               ## @.str.3
	.asciz	"Valid link established!!!\n"

	.comm	_E1000_SUCCESS,8,3              ## @E1000_SUCCESS
L_.str.4:                               ## @.str.4
	.asciz	"Unable to establish link!!!\n"

	.no_dead_strip	_e1000_setup_copper_link
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function e1000_setup_copper_link
_e1000_setup_copper_link:               ; @e1000_setup_copper_link
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x0
	bl	_e1000_copper_link_preconfig
	mov	x20, x0
	cbz	x0, LBB0_2
LBB0_1:
	mov	x0, x20
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_2:
	ldr	x8, [x19]
Lloh0:
	adrp	x9, _e1000_phy_igp@GOTPAGE
Lloh1:
	ldr	x9, [x9, _e1000_phy_igp@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_4
; %bb.3:
	mov	x0, x19
	bl	_e1000_copper_link_igp_setup
	mov	x20, x0
	cbnz	x0, LBB0_1
	b	LBB0_8
LBB0_4:
Lloh3:
	adrp	x9, _e1000_phy_m88@GOTPAGE
Lloh4:
	ldr	x9, [x9, _e1000_phy_m88@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	mov	x0, x19
	cmp	x8, x9
	b.ne	LBB0_6
; %bb.5:
	bl	_e1000_copper_link_mgp_setup
	mov	x20, x0
	cbnz	x0, LBB0_1
	b	LBB0_8
LBB0_6:
	bl	_gbe_dhg_phy_setup
	cbz	x0, LBB0_8
; %bb.7:
	mov	x20, x0
Lloh6:
	adrp	x0, l_.str@PAGE
Lloh7:
	add	x0, x0, l_.str@PAGEOFF
	bl	_e_dbg
	b	LBB0_1
LBB0_8:
	ldr	x8, [x19, #8]
	cbz	x8, LBB0_10
; %bb.9:
	mov	x0, x19
	bl	_e1000_copper_link_autoneg
	mov	x20, x0
	cbnz	x0, LBB0_1
	b	LBB0_12
LBB0_10:
Lloh8:
	adrp	x0, l_.str.1@PAGE
Lloh9:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_e_dbg
	mov	x0, x19
	bl	_e1000_phy_force_speed_duplex
	cbz	x0, LBB0_12
; %bb.11:
	mov	x20, x0
Lloh10:
	adrp	x0, l_.str.2@PAGE
Lloh11:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_e_dbg
	b	LBB0_1
LBB0_12:
	mov	w21, #10
Lloh12:
	adrp	x22, _PHY_STATUS@GOTPAGE
Lloh13:
	ldr	x22, [x22, _PHY_STATUS@GOTPAGEOFF]
Lloh14:
	adrp	x23, _MII_SR_LINK_STATUS@GOTPAGE
Lloh15:
	ldr	x23, [x23, _MII_SR_LINK_STATUS@GOTPAGEOFF]
LBB0_13:                                ; =>This Inner Loop Header: Depth=1
	ldr	w1, [x22]
	add	x2, sp, #12
	mov	x0, x19
	bl	_e1000_read_phy_reg
	cbnz	x0, LBB0_18
; %bb.14:                               ;   in Loop: Header=BB0_13 Depth=1
	ldr	w1, [x22]
	add	x2, sp, #12
	mov	x0, x19
	bl	_e1000_read_phy_reg
	cbnz	x0, LBB0_18
; %bb.15:                               ;   in Loop: Header=BB0_13 Depth=1
	ldr	w8, [sp, #12]
	ldr	w9, [x23]
	tst	w9, w8
	b.ne	LBB0_19
; %bb.16:                               ;   in Loop: Header=BB0_13 Depth=1
	mov	w0, #10
	bl	_udelay
	subs	w21, w21, #1
	b.ne	LBB0_13
; %bb.17:
Lloh16:
	adrp	x0, l_.str.4@PAGE
Lloh17:
	add	x0, x0, l_.str.4@PAGEOFF
	b	LBB0_21
LBB0_18:
	mov	x20, x0
	b	LBB0_1
LBB0_19:
	mov	x0, x19
	bl	_e1000_copper_link_postconfig
	mov	x20, x0
	cbnz	x0, LBB0_1
; %bb.20:
Lloh18:
	adrp	x0, l_.str.3@PAGE
Lloh19:
	add	x0, x0, l_.str.3@PAGEOFF
LBB0_21:
	bl	_e_dbg
Lloh20:
	adrp	x8, _E1000_SUCCESS@GOTPAGE
Lloh21:
	ldr	x8, [x8, _E1000_SUCCESS@GOTPAGEOFF]
Lloh22:
	ldr	x20, [x8]
	b	LBB0_1
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.cfi_endproc
                                        ; -- End function
	.comm	_e1000_phy_igp,8,3              ; @e1000_phy_igp
	.comm	_e1000_phy_m88,8,3              ; @e1000_phy_m88
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"gbe_dhg_phy_setup failed!\n"

l_.str.1:                               ; @.str.1
	.asciz	"Forcing speed and duplex\n"

l_.str.2:                               ; @.str.2
	.asciz	"Error Forcing Speed and Duplex\n"

	.comm	_PHY_STATUS,4,2                 ; @PHY_STATUS
	.comm	_MII_SR_LINK_STATUS,4,2         ; @MII_SR_LINK_STATUS
l_.str.3:                               ; @.str.3
	.asciz	"Valid link established!!!\n"

	.comm	_E1000_SUCCESS,8,3              ; @E1000_SUCCESS
l_.str.4:                               ; @.str.4
	.asciz	"Unable to establish link!!!\n"

	.no_dead_strip	_e1000_setup_copper_link
.subsections_via_symbols
