	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bnx2_5706s_linkup
_bnx2_5706s_linkup:                     ## @bnx2_5706s_linkup
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -24
	movq	%rdi, %rbx
	movl	$1, (%rdi)
	movq	_SPEED_1000@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 28(%rdi)
	movl	24(%rdi), %esi
	leaq	-20(%rbp), %rdx
	callq	_bnx2_read_phy
	movl	-20(%rbp), %eax
	movq	_BMCR_FULLDPLX@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	andl	%eax, %ecx
	jne	LBB0_1
## %bb.2:
	movq	_DUPLEX_HALF@GOTPCREL(%rip), %rcx
	jmp	LBB0_3
LBB0_1:
	movq	_DUPLEX_FULL@GOTPCREL(%rip), %rcx
LBB0_3:
	movq	(%rcx), %rcx
	movq	%rcx, 8(%rbx)
	movq	_BMCR_ANENABLE@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_9
## %bb.4:
	movl	20(%rbx), %esi
	leaq	-16(%rbp), %rdx
	movq	%rbx, %rdi
	callq	_bnx2_read_phy
	movl	16(%rbx), %esi
	leaq	-12(%rbp), %rdx
	movq	%rbx, %rdi
	callq	_bnx2_read_phy
	movl	-12(%rbp), %eax
	andl	-16(%rbp), %eax
	movq	_ADVERTISE_1000XHALF@GOTPCREL(%rip), %rdx
	movq	_ADVERTISE_1000XFULL@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	(%rdx), %edx
	orl	%ecx, %edx
	testl	%eax, %edx
	je	LBB0_9
## %bb.5:
	testl	%eax, %ecx
	jne	LBB0_6
## %bb.7:
	movq	_DUPLEX_HALF@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_6:
	movq	_DUPLEX_FULL@GOTPCREL(%rip), %rax
LBB0_8:
	movq	(%rax), %rax
	movq	%rax, 8(%rbx)
LBB0_9:
	xorl	%eax, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SPEED_1000,4,2                 ## @SPEED_1000
	.comm	_BMCR_FULLDPLX,4,2              ## @BMCR_FULLDPLX
	.comm	_DUPLEX_FULL,8,3                ## @DUPLEX_FULL
	.comm	_DUPLEX_HALF,8,3                ## @DUPLEX_HALF
	.comm	_BMCR_ANENABLE,4,2              ## @BMCR_ANENABLE
	.comm	_ADVERTISE_1000XHALF,4,2        ## @ADVERTISE_1000XHALF
	.comm	_ADVERTISE_1000XFULL,4,2        ## @ADVERTISE_1000XFULL
	.no_dead_strip	_bnx2_5706s_linkup
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bnx2_5706s_linkup
_bnx2_5706s_linkup:                     ; @bnx2_5706s_linkup
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x19, x0
	mov	w8, #1
	str	w8, [x0]
Lloh0:
	adrp	x8, _SPEED_1000@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SPEED_1000@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	str	w8, [x0, #28]
	ldr	w1, [x0, #24]
	add	x2, sp, #12
	bl	_bnx2_read_phy
	ldr	w8, [sp, #12]
Lloh3:
	adrp	x9, _BMCR_FULLDPLX@GOTPAGE
Lloh4:
	ldr	x9, [x9, _BMCR_FULLDPLX@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
Lloh6:
	adrp	x20, _DUPLEX_HALF@GOTPAGE
Lloh7:
	ldr	x20, [x20, _DUPLEX_HALF@GOTPAGEOFF]
Lloh8:
	adrp	x21, _DUPLEX_FULL@GOTPAGE
Lloh9:
	ldr	x21, [x21, _DUPLEX_FULL@GOTPAGEOFF]
	tst	w9, w8
	csel	x9, x20, x21, eq
	ldr	x9, [x9]
	str	x9, [x19, #8]
Lloh10:
	adrp	x9, _BMCR_ANENABLE@GOTPAGE
Lloh11:
	ldr	x9, [x9, _BMCR_ANENABLE@GOTPAGEOFF]
Lloh12:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_3
; %bb.1:
	ldr	w1, [x19, #20]
	add	x2, sp, #8
	mov	x0, x19
	bl	_bnx2_read_phy
	ldr	w1, [x19, #16]
	add	x2, sp, #4
	mov	x0, x19
	bl	_bnx2_read_phy
	ldp	w9, w8, [sp, #4]
	and	w8, w9, w8
Lloh13:
	adrp	x9, _ADVERTISE_1000XHALF@GOTPAGE
Lloh14:
	ldr	x9, [x9, _ADVERTISE_1000XHALF@GOTPAGEOFF]
Lloh15:
	ldr	w10, [x9]
Lloh16:
	adrp	x9, _ADVERTISE_1000XFULL@GOTPAGE
Lloh17:
	ldr	x9, [x9, _ADVERTISE_1000XFULL@GOTPAGEOFF]
Lloh18:
	ldr	w9, [x9]
	orr	w10, w9, w10
	tst	w10, w8
	b.eq	LBB0_3
; %bb.2:
	tst	w9, w8
	csel	x8, x20, x21, eq
	ldr	x8, [x8]
	str	x8, [x19, #8]
LBB0_3:
	mov	w0, #0
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.comm	_SPEED_1000,4,2                 ; @SPEED_1000
	.comm	_BMCR_FULLDPLX,4,2              ; @BMCR_FULLDPLX
	.comm	_DUPLEX_FULL,8,3                ; @DUPLEX_FULL
	.comm	_DUPLEX_HALF,8,3                ; @DUPLEX_HALF
	.comm	_BMCR_ANENABLE,4,2              ; @BMCR_ANENABLE
	.comm	_ADVERTISE_1000XHALF,4,2        ; @ADVERTISE_1000XHALF
	.comm	_ADVERTISE_1000XFULL,4,2        ; @ADVERTISE_1000XFULL
	.no_dead_strip	_bnx2_5706s_linkup
.subsections_via_symbols
