	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function xgbe_phy_init
_xgbe_phy_init:                         ## @xgbe_phy_init
	.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, %rbx
	addq	$116, %rdi
	callq	_mutex_init
	leaq	112(%rbx), %rdi
	movq	_xgbe_an_irq_work@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_INIT_WORK
	leaq	108(%rbx), %rdi
	movq	_xgbe_an_state_machine@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_INIT_WORK
	movq	_MDIO_MMD_PCS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 104(%rbx)
	movq	_MDIO_MMD_PMAPMD@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_MDIO_PMA_10GBR_FECABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_XMDIO_READ
	movl	%eax, (%rbx)
	movq	_MDIO_PMA_10GBR_FECABLE_ABLE@GOTPCREL(%rip), %rcx
	movq	_MDIO_PMA_10GBR_FECABLE_ERRABLE@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	orl	(%rcx), %edx
	andl	%eax, %edx
	movl	%edx, (%rbx)
	movq	%rbx, %rdi
	callq	*96(%rbx)
	movl	%eax, %r14d
	testl	%eax, %eax
	jne	LBB0_12
## %bb.1:
	leaq	80(%rbx), %r15
	movq	_advertising@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_supported@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r15, %rdi
	movq	%r15, %rdx
	callq	_XGBE_LM_COPY
	movq	$0, 72(%rbx)
	movq	_Autoneg@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_XGBE_ADV
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	movq	_AUTONEG_ENABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 64(%rbx)
	movq	_SPEED_UNKNOWN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_DUPLEX_UNKNOWN@GOTPCREL(%rip), %rcx
	jmp	LBB0_4
LBB0_3:
	movq	_AUTONEG_DISABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 64(%rbx)
	movq	%rbx, %rdi
	callq	_xgbe_phy_best_advertised_speed
	movq	_DUPLEX_FULL@GOTPCREL(%rip), %rcx
LBB0_4:
	movl	(%rcx), %ecx
	movl	%eax, 60(%rbx)
	movl	%ecx, 56(%rbx)
	movq	$0, 48(%rbx)
	movl	88(%rbx), %eax
	movl	%eax, 40(%rbx)
	movdqu	8(%rbx), %xmm0
	pshufd	$78, %xmm0, %xmm0               ## xmm0 = xmm0[2,3,0,1]
	movdqu	%xmm0, 24(%rbx)
	movq	_Pause@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	movq	%r15, %rdi
	callq	_XGBE_CLR_ADV
	movq	_Asym_Pause@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movq	%r15, %rdi
	callq	_XGBE_CLR_ADV
	cmpq	$0, 16(%rbx)
	je	LBB0_6
## %bb.5:
	movl	(%r13), %esi
	movq	%r15, %rdi
	callq	_XGBE_SET_ADV
	movl	(%r12), %esi
	movq	%r15, %rdi
	callq	_XGBE_SET_ADV
LBB0_6:
	cmpq	$0, 8(%rbx)
	je	LBB0_10
## %bb.7:
	movl	(%r12), %esi
	movq	%r15, %rdi
	callq	_XGBE_ADV
	movl	(%r12), %esi
	movq	%r15, %rdi
	testq	%rax, %rax
	je	LBB0_9
## %bb.8:
	callq	_XGBE_CLR_ADV
	jmp	LBB0_10
LBB0_9:
	callq	_XGBE_SET_ADV
LBB0_10:
	movq	%rbx, %rdi
	callq	_netif_msg_drv
	testq	%rax, %rax
	je	LBB0_12
## %bb.11:
	movq	%rbx, %rdi
	callq	_xgbe_dump_phy_registers
LBB0_12:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_xgbe_an_irq_work,4,2           ## @xgbe_an_irq_work
	.comm	_xgbe_an_state_machine,4,2      ## @xgbe_an_state_machine
	.comm	_MDIO_MMD_PCS,4,2               ## @MDIO_MMD_PCS
	.comm	_MDIO_MMD_PMAPMD,4,2            ## @MDIO_MMD_PMAPMD
	.comm	_MDIO_PMA_10GBR_FECABLE,4,2     ## @MDIO_PMA_10GBR_FECABLE
	.comm	_MDIO_PMA_10GBR_FECABLE_ABLE,4,2 ## @MDIO_PMA_10GBR_FECABLE_ABLE
	.comm	_MDIO_PMA_10GBR_FECABLE_ERRABLE,4,2 ## @MDIO_PMA_10GBR_FECABLE_ERRABLE
	.comm	_advertising,4,2                ## @advertising
	.comm	_supported,4,2                  ## @supported
	.comm	_Autoneg,4,2                    ## @Autoneg
	.comm	_AUTONEG_ENABLE,4,2             ## @AUTONEG_ENABLE
	.comm	_SPEED_UNKNOWN,4,2              ## @SPEED_UNKNOWN
	.comm	_DUPLEX_UNKNOWN,4,2             ## @DUPLEX_UNKNOWN
	.comm	_AUTONEG_DISABLE,4,2            ## @AUTONEG_DISABLE
	.comm	_DUPLEX_FULL,4,2                ## @DUPLEX_FULL
	.comm	_Pause,4,2                      ## @Pause
	.comm	_Asym_Pause,4,2                 ## @Asym_Pause
	.no_dead_strip	_xgbe_phy_init
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function xgbe_phy_init
_xgbe_phy_init:                         ; @xgbe_phy_init
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x0
	add	x0, x0, #116
	bl	_mutex_init
	add	x0, x19, #112
Lloh0:
	adrp	x8, _xgbe_an_irq_work@GOTPAGE
Lloh1:
	ldr	x8, [x8, _xgbe_an_irq_work@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_INIT_WORK
	add	x0, x19, #108
Lloh3:
	adrp	x8, _xgbe_an_state_machine@GOTPAGE
Lloh4:
	ldr	x8, [x8, _xgbe_an_state_machine@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	bl	_INIT_WORK
Lloh6:
	adrp	x8, _MDIO_MMD_PCS@GOTPAGE
Lloh7:
	ldr	x8, [x8, _MDIO_MMD_PCS@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	str	w8, [x19, #104]
Lloh9:
	adrp	x8, _MDIO_MMD_PMAPMD@GOTPAGE
Lloh10:
	ldr	x8, [x8, _MDIO_MMD_PMAPMD@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
Lloh12:
	adrp	x8, _MDIO_PMA_10GBR_FECABLE@GOTPAGE
Lloh13:
	ldr	x8, [x8, _MDIO_PMA_10GBR_FECABLE@GOTPAGEOFF]
Lloh14:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_XMDIO_READ
	str	w0, [x19]
Lloh15:
	adrp	x8, _MDIO_PMA_10GBR_FECABLE_ABLE@GOTPAGE
Lloh16:
	ldr	x8, [x8, _MDIO_PMA_10GBR_FECABLE_ABLE@GOTPAGEOFF]
Lloh17:
	adrp	x9, _MDIO_PMA_10GBR_FECABLE_ERRABLE@GOTPAGE
Lloh18:
	ldr	x9, [x9, _MDIO_PMA_10GBR_FECABLE_ERRABLE@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
Lloh20:
	ldr	w9, [x9]
	orr	w8, w9, w8
	and	w8, w8, w0
	str	w8, [x19]
	ldr	x8, [x19, #96]
	mov	x0, x19
	blr	x8
	mov	x20, x0
	cbnz	w0, LBB0_12
; %bb.1:
	add	x21, x19, #80
Lloh21:
	adrp	x8, _advertising@GOTPAGE
Lloh22:
	ldr	x8, [x8, _advertising@GOTPAGEOFF]
Lloh23:
	ldr	w1, [x8]
Lloh24:
	adrp	x8, _supported@GOTPAGE
Lloh25:
	ldr	x8, [x8, _supported@GOTPAGEOFF]
Lloh26:
	ldr	w3, [x8]
	mov	x0, x21
	mov	x2, x21
	bl	_XGBE_LM_COPY
	str	xzr, [x19, #72]
Lloh27:
	adrp	x8, _Autoneg@GOTPAGE
Lloh28:
	ldr	x8, [x8, _Autoneg@GOTPAGEOFF]
Lloh29:
	ldr	w1, [x8]
	mov	x0, x21
	bl	_XGBE_ADV
	cbz	x0, LBB0_3
; %bb.2:
Lloh30:
	adrp	x8, _AUTONEG_ENABLE@GOTPAGE
Lloh31:
	ldr	x8, [x8, _AUTONEG_ENABLE@GOTPAGEOFF]
Lloh32:
	ldr	w8, [x8]
	str	w8, [x19, #64]
Lloh33:
	adrp	x8, _SPEED_UNKNOWN@GOTPAGE
Lloh34:
	ldr	x8, [x8, _SPEED_UNKNOWN@GOTPAGEOFF]
Lloh35:
	ldr	w0, [x8]
Lloh36:
	adrp	x8, _DUPLEX_UNKNOWN@GOTPAGE
Lloh37:
	ldr	x8, [x8, _DUPLEX_UNKNOWN@GOTPAGEOFF]
	b	LBB0_4
LBB0_3:
Lloh38:
	adrp	x8, _AUTONEG_DISABLE@GOTPAGE
Lloh39:
	ldr	x8, [x8, _AUTONEG_DISABLE@GOTPAGEOFF]
Lloh40:
	ldr	w8, [x8]
	str	w8, [x19, #64]
	mov	x0, x19
	bl	_xgbe_phy_best_advertised_speed
Lloh41:
	adrp	x8, _DUPLEX_FULL@GOTPAGE
Lloh42:
	ldr	x8, [x8, _DUPLEX_FULL@GOTPAGEOFF]
LBB0_4:
	ldr	w8, [x8]
	stp	w8, w0, [x19, #56]
	str	xzr, [x19, #48]
	ldr	w8, [x19, #88]
	str	w8, [x19, #40]
	ldur	q0, [x19, #8]
	ext.16b	v0, v0, v0, #8
	stur	q0, [x19, #24]
Lloh43:
	adrp	x23, _Pause@GOTPAGE
Lloh44:
	ldr	x23, [x23, _Pause@GOTPAGEOFF]
	ldr	w1, [x23]
	mov	x0, x21
	bl	_XGBE_CLR_ADV
Lloh45:
	adrp	x22, _Asym_Pause@GOTPAGE
Lloh46:
	ldr	x22, [x22, _Asym_Pause@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x21
	bl	_XGBE_CLR_ADV
	ldr	x8, [x19, #16]
	cbz	x8, LBB0_6
; %bb.5:
	ldr	w1, [x23]
	mov	x0, x21
	bl	_XGBE_SET_ADV
	ldr	w1, [x22]
	mov	x0, x21
	bl	_XGBE_SET_ADV
LBB0_6:
	ldr	x8, [x19, #8]
	cbz	x8, LBB0_10
; %bb.7:
	ldr	w1, [x22]
	mov	x0, x21
	bl	_XGBE_ADV
	ldr	w1, [x22]
	cbz	x0, LBB0_9
; %bb.8:
	mov	x0, x21
	bl	_XGBE_CLR_ADV
	b	LBB0_10
LBB0_9:
	mov	x0, x21
	bl	_XGBE_SET_ADV
LBB0_10:
	mov	x0, x19
	bl	_netif_msg_drv
	cbz	x0, LBB0_12
; %bb.11:
	mov	x0, x19
	bl	_xgbe_dump_phy_registers
LBB0_12:
	mov	x0, x20
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh19
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGot	Lloh41, Lloh42
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh40
	.loh AdrpLdrGot	Lloh45, Lloh46
	.loh AdrpLdrGot	Lloh43, Lloh44
	.cfi_endproc
                                        ; -- End function
	.comm	_xgbe_an_irq_work,4,2           ; @xgbe_an_irq_work
	.comm	_xgbe_an_state_machine,4,2      ; @xgbe_an_state_machine
	.comm	_MDIO_MMD_PCS,4,2               ; @MDIO_MMD_PCS
	.comm	_MDIO_MMD_PMAPMD,4,2            ; @MDIO_MMD_PMAPMD
	.comm	_MDIO_PMA_10GBR_FECABLE,4,2     ; @MDIO_PMA_10GBR_FECABLE
	.comm	_MDIO_PMA_10GBR_FECABLE_ABLE,4,2 ; @MDIO_PMA_10GBR_FECABLE_ABLE
	.comm	_MDIO_PMA_10GBR_FECABLE_ERRABLE,4,2 ; @MDIO_PMA_10GBR_FECABLE_ERRABLE
	.comm	_advertising,4,2                ; @advertising
	.comm	_supported,4,2                  ; @supported
	.comm	_Autoneg,4,2                    ; @Autoneg
	.comm	_AUTONEG_ENABLE,4,2             ; @AUTONEG_ENABLE
	.comm	_SPEED_UNKNOWN,4,2              ; @SPEED_UNKNOWN
	.comm	_DUPLEX_UNKNOWN,4,2             ; @DUPLEX_UNKNOWN
	.comm	_AUTONEG_DISABLE,4,2            ; @AUTONEG_DISABLE
	.comm	_DUPLEX_FULL,4,2                ; @DUPLEX_FULL
	.comm	_Pause,4,2                      ; @Pause
	.comm	_Asym_Pause,4,2                 ; @Asym_Pause
	.no_dead_strip	_xgbe_phy_init
.subsections_via_symbols
