	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_emac_sgmii_init_fsm9900        ## -- Begin function emac_sgmii_init_fsm9900
	.p2align	4, 0x90
_emac_sgmii_init_fsm9900:               ## @emac_sgmii_init_fsm9900
	.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, %r12
	movq	8(%rdi), %r14
	movq	_physical_coding_sublayer_programming@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movl	%r15d, %edi
	callq	_ARRAY_SIZE
	movq	%r14, %rdi
	movl	%r15d, %esi
	movl	%eax, %edx
	callq	_emac_reg_write_all
	movq	8(%r12), %r14
	movq	_sysclk_refclk_setting@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movl	%r15d, %edi
	callq	_ARRAY_SIZE
	movq	%r14, %rdi
	movl	%r15d, %esi
	movl	%eax, %edx
	callq	_emac_reg_write_all
	movq	8(%r12), %r14
	movq	_pll_setting@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movl	%r15d, %edi
	callq	_ARRAY_SIZE
	movq	%r14, %rdi
	movl	%r15d, %esi
	movl	%eax, %edx
	callq	_emac_reg_write_all
	movq	8(%r12), %r14
	movq	_cdr_setting@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movl	%r15d, %edi
	callq	_ARRAY_SIZE
	movq	%r14, %rdi
	movl	%r15d, %esi
	movl	%eax, %edx
	callq	_emac_reg_write_all
	movq	8(%r12), %r14
	movq	_tx_rx_setting@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movl	%r15d, %edi
	callq	_ARRAY_SIZE
	movq	%r14, %rdi
	movl	%r15d, %esi
	movl	%eax, %edx
	callq	_emac_reg_write_all
	movq	_SERDES_START@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_EMAC_SGMII_PHY_SERDES_START@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	8(%r12), %rsi
	callq	_writel
	movq	_SERDES_START_WAIT_TIMES@GOTPCREL(%rip), %r14
	cmpl	$0, (%r14)
	je	LBB0_6
## %bb.1:
	xorl	%ebx, %ebx
	movq	_EMAC_QSERDES_COM_RESET_SM@GOTPCREL(%rip), %r15
	movq	_READY@GOTPCREL(%rip), %r13
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r15), %rdi
	addq	8(%r12), %rdi
	callq	_readl
	testl	%eax, (%r13)
	jne	LBB0_3
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	$100, %edi
	movl	$200, %esi
	callq	_usleep_range
	incl	%ebx
	movl	(%r14), %eax
	cmpl	%eax, %ebx
	jb	LBB0_2
## %bb.5:
	cmpl	%eax, %ebx
	jne	LBB0_7
LBB0_6:
	movl	(%r12), %edi
	leaq	L_.str(%rip), %rsi
	callq	_netdev_err
	movq	_EIO@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_8
LBB0_3:
	movl	(%r14), %eax
	cmpl	%eax, %ebx
	je	LBB0_6
LBB0_7:
	movq	_EMAC_SGMII_PHY_INTERRUPT_MASK@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	8(%r12), %rsi
	xorl	%ebx, %ebx
	xorl	%edi, %edi
	callq	_writel
LBB0_8:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_physical_coding_sublayer_programming,4,2 ## @physical_coding_sublayer_programming
	.comm	_sysclk_refclk_setting,4,2      ## @sysclk_refclk_setting
	.comm	_pll_setting,4,2                ## @pll_setting
	.comm	_cdr_setting,4,2                ## @cdr_setting
	.comm	_tx_rx_setting,4,2              ## @tx_rx_setting
	.comm	_SERDES_START,4,2               ## @SERDES_START
	.comm	_EMAC_SGMII_PHY_SERDES_START,8,3 ## @EMAC_SGMII_PHY_SERDES_START
	.comm	_SERDES_START_WAIT_TIMES,4,2    ## @SERDES_START_WAIT_TIMES
	.comm	_EMAC_QSERDES_COM_RESET_SM,8,3  ## @EMAC_QSERDES_COM_RESET_SM
	.comm	_READY,4,2                      ## @READY
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"error: ser/des failed to start\n"

	.comm	_EIO,4,2                        ## @EIO
	.comm	_EMAC_SGMII_PHY_INTERRUPT_MASK,8,3 ## @EMAC_SGMII_PHY_INTERRUPT_MASK
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_emac_sgmii_init_fsm9900        ; -- Begin function emac_sgmii_init_fsm9900
	.p2align	2
_emac_sgmii_init_fsm9900:               ; @emac_sgmii_init_fsm9900
	.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
	ldr	x20, [x0, #8]
Lloh0:
	adrp	x8, _physical_coding_sublayer_programming@GOTPAGE
Lloh1:
	ldr	x8, [x8, _physical_coding_sublayer_programming@GOTPAGEOFF]
Lloh2:
	ldr	w21, [x8]
	mov	x0, x21
	bl	_ARRAY_SIZE
	mov	x2, x0
	mov	x0, x20
	mov	x1, x21
	bl	_emac_reg_write_all
	ldr	x20, [x19, #8]
Lloh3:
	adrp	x8, _sysclk_refclk_setting@GOTPAGE
Lloh4:
	ldr	x8, [x8, _sysclk_refclk_setting@GOTPAGEOFF]
Lloh5:
	ldr	w21, [x8]
	mov	x0, x21
	bl	_ARRAY_SIZE
	mov	x2, x0
	mov	x0, x20
	mov	x1, x21
	bl	_emac_reg_write_all
	ldr	x20, [x19, #8]
Lloh6:
	adrp	x8, _pll_setting@GOTPAGE
Lloh7:
	ldr	x8, [x8, _pll_setting@GOTPAGEOFF]
Lloh8:
	ldr	w21, [x8]
	mov	x0, x21
	bl	_ARRAY_SIZE
	mov	x2, x0
	mov	x0, x20
	mov	x1, x21
	bl	_emac_reg_write_all
	ldr	x20, [x19, #8]
Lloh9:
	adrp	x8, _cdr_setting@GOTPAGE
Lloh10:
	ldr	x8, [x8, _cdr_setting@GOTPAGEOFF]
Lloh11:
	ldr	w21, [x8]
	mov	x0, x21
	bl	_ARRAY_SIZE
	mov	x2, x0
	mov	x0, x20
	mov	x1, x21
	bl	_emac_reg_write_all
	ldr	x20, [x19, #8]
Lloh12:
	adrp	x8, _tx_rx_setting@GOTPAGE
Lloh13:
	ldr	x8, [x8, _tx_rx_setting@GOTPAGEOFF]
Lloh14:
	ldr	w21, [x8]
	mov	x0, x21
	bl	_ARRAY_SIZE
	mov	x2, x0
	mov	x0, x20
	mov	x1, x21
	bl	_emac_reg_write_all
Lloh15:
	adrp	x8, _SERDES_START@GOTPAGE
Lloh16:
	ldr	x8, [x8, _SERDES_START@GOTPAGEOFF]
Lloh17:
	ldr	w0, [x8]
	ldr	x8, [x19, #8]
Lloh18:
	adrp	x9, _EMAC_SGMII_PHY_SERDES_START@GOTPAGE
Lloh19:
	ldr	x9, [x9, _EMAC_SGMII_PHY_SERDES_START@GOTPAGEOFF]
Lloh20:
	ldr	x9, [x9]
	add	x1, x9, x8
	bl	_writel
Lloh21:
	adrp	x21, _SERDES_START_WAIT_TIMES@GOTPAGE
Lloh22:
	ldr	x21, [x21, _SERDES_START_WAIT_TIMES@GOTPAGEOFF]
	ldr	w8, [x21]
	cbz	w8, LBB0_5
; %bb.1:
	mov	w20, #0
Lloh23:
	adrp	x22, _EMAC_QSERDES_COM_RESET_SM@GOTPAGE
Lloh24:
	ldr	x22, [x22, _EMAC_QSERDES_COM_RESET_SM@GOTPAGEOFF]
Lloh25:
	adrp	x23, _READY@GOTPAGE
Lloh26:
	ldr	x23, [x23, _READY@GOTPAGEOFF]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #8]
	ldr	x9, [x22]
	add	x0, x9, x8
	bl	_readl
	ldr	w8, [x23]
	tst	w8, w0
	b.ne	LBB0_6
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	mov	w0, #100
	mov	w1, #200
	bl	_usleep_range
	add	w20, w20, #1
	ldr	w8, [x21]
	cmp	w20, w8
	b.lo	LBB0_2
; %bb.4:
	cmp	w20, w8
	b.ne	LBB0_7
LBB0_5:
	ldr	w0, [x19]
Lloh27:
	adrp	x1, l_.str@PAGE
Lloh28:
	add	x1, x1, l_.str@PAGEOFF
	bl	_netdev_err
Lloh29:
	adrp	x8, _EIO@GOTPAGE
Lloh30:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh31:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_8
LBB0_6:
	ldr	w8, [x21]
	cmp	w20, w8
	b.eq	LBB0_5
LBB0_7:
	ldr	x8, [x19, #8]
Lloh32:
	adrp	x9, _EMAC_SGMII_PHY_INTERRUPT_MASK@GOTPAGE
Lloh33:
	ldr	x9, [x9, _EMAC_SGMII_PHY_INTERRUPT_MASK@GOTPAGEOFF]
Lloh34:
	ldr	x9, [x9]
	add	x1, x9, x8
	mov	w0, #0
	bl	_writel
	mov	w0, #0
LBB0_8:
	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 AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.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 AdrpLdrGot	Lloh25, Lloh26
	.loh AdrpLdrGot	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.cfi_endproc
                                        ; -- End function
	.comm	_physical_coding_sublayer_programming,4,2 ; @physical_coding_sublayer_programming
	.comm	_sysclk_refclk_setting,4,2      ; @sysclk_refclk_setting
	.comm	_pll_setting,4,2                ; @pll_setting
	.comm	_cdr_setting,4,2                ; @cdr_setting
	.comm	_tx_rx_setting,4,2              ; @tx_rx_setting
	.comm	_SERDES_START,4,2               ; @SERDES_START
	.comm	_EMAC_SGMII_PHY_SERDES_START,8,3 ; @EMAC_SGMII_PHY_SERDES_START
	.comm	_SERDES_START_WAIT_TIMES,4,2    ; @SERDES_START_WAIT_TIMES
	.comm	_EMAC_QSERDES_COM_RESET_SM,8,3  ; @EMAC_QSERDES_COM_RESET_SM
	.comm	_READY,4,2                      ; @READY
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"error: ser/des failed to start\n"

	.comm	_EIO,4,2                        ; @EIO
	.comm	_EMAC_SGMII_PHY_INTERRUPT_MASK,8,3 ; @EMAC_SGMII_PHY_INTERRUPT_MASK
.subsections_via_symbols
