	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function at803x_aneg_done
_at803x_aneg_done:                      ## @at803x_aneg_done
	.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
	callq	_genphy_aneg_done
	movl	%eax, %r14d
	movq	_BMSR_ANEGCOMPLETE@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r14d
	jne	LBB0_5
## %bb.1:
	movq	_AT803X_REG_CHIP_CONFIG@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movq	%rbx, %rdi
	callq	_phy_read
	movl	%eax, %r15d
	movq	_AT803X_MODE_CFG_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	%r15d, %eax
	movq	_AT803X_MODE_CFG_SGMII@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_5
## %bb.2:
	movl	(%r12), %esi
	movq	_AT803X_BT_BX_REG_SEL@GOTPCREL(%rip), %r13
	movl	(%r13), %edx
	notl	%edx
	andl	%r15d, %edx
	movq	%rbx, %rdi
	callq	_phy_write
	movq	_AT803X_PSSR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_phy_read
	movq	_AT803X_PSSR_MR_AN_COMPLETE@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_4
## %bb.3:
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdi
	callq	_phydev_warn
	xorl	%r14d, %r14d
LBB0_4:
	movl	(%r12), %esi
	movl	(%r13), %edx
	orl	%r15d, %edx
	movq	%rbx, %rdi
	callq	_phy_write
LBB0_5:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_BMSR_ANEGCOMPLETE,4,2          ## @BMSR_ANEGCOMPLETE
	.comm	_AT803X_REG_CHIP_CONFIG,4,2     ## @AT803X_REG_CHIP_CONFIG
	.comm	_AT803X_MODE_CFG_MASK,4,2       ## @AT803X_MODE_CFG_MASK
	.comm	_AT803X_MODE_CFG_SGMII,4,2      ## @AT803X_MODE_CFG_SGMII
	.comm	_AT803X_BT_BX_REG_SEL,4,2       ## @AT803X_BT_BX_REG_SEL
	.comm	_AT803X_PSSR,4,2                ## @AT803X_PSSR
	.comm	_AT803X_PSSR_MR_AN_COMPLETE,4,2 ## @AT803X_PSSR_MR_AN_COMPLETE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"803x_aneg_done: SGMII link is not ok\n"

	.no_dead_strip	_at803x_aneg_done
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function at803x_aneg_done
_at803x_aneg_done:                      ; @at803x_aneg_done
	.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
	bl	_genphy_aneg_done
	mov	x20, x0
Lloh0:
	adrp	x8, _BMSR_ANEGCOMPLETE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _BMSR_ANEGCOMPLETE@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w0, w8
	b.ne	LBB0_5
; %bb.1:
Lloh3:
	adrp	x22, _AT803X_REG_CHIP_CONFIG@GOTPAGE
Lloh4:
	ldr	x22, [x22, _AT803X_REG_CHIP_CONFIG@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x19
	bl	_phy_read
Lloh5:
	adrp	x8, _AT803X_MODE_CFG_MASK@GOTPAGE
Lloh6:
	ldr	x8, [x8, _AT803X_MODE_CFG_MASK@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	and	w8, w8, w0
Lloh8:
	adrp	x9, _AT803X_MODE_CFG_SGMII@GOTPAGE
Lloh9:
	ldr	x9, [x9, _AT803X_MODE_CFG_SGMII@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_5
; %bb.2:
	mov	x21, x0
	ldr	w1, [x22]
Lloh11:
	adrp	x23, _AT803X_BT_BX_REG_SEL@GOTPAGE
Lloh12:
	ldr	x23, [x23, _AT803X_BT_BX_REG_SEL@GOTPAGEOFF]
	ldr	w8, [x23]
	bic	w2, w0, w8
	mov	x0, x19
	bl	_phy_write
Lloh13:
	adrp	x8, _AT803X_PSSR@GOTPAGE
Lloh14:
	ldr	x8, [x8, _AT803X_PSSR@GOTPAGEOFF]
Lloh15:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_phy_read
Lloh16:
	adrp	x8, _AT803X_PSSR_MR_AN_COMPLETE@GOTPAGE
Lloh17:
	ldr	x8, [x8, _AT803X_PSSR_MR_AN_COMPLETE@GOTPAGEOFF]
Lloh18:
	ldr	w8, [x8]
	tst	w8, w0
	b.ne	LBB0_4
; %bb.3:
Lloh19:
	adrp	x1, l_.str@PAGE
Lloh20:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_phydev_warn
	mov	w20, #0
LBB0_4:
	ldr	w1, [x22]
	ldr	w8, [x23]
	orr	w2, w8, w21
	mov	x0, x19
	bl	_phy_write
LBB0_5:
	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	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpAdd	Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_BMSR_ANEGCOMPLETE,4,2          ; @BMSR_ANEGCOMPLETE
	.comm	_AT803X_REG_CHIP_CONFIG,4,2     ; @AT803X_REG_CHIP_CONFIG
	.comm	_AT803X_MODE_CFG_MASK,4,2       ; @AT803X_MODE_CFG_MASK
	.comm	_AT803X_MODE_CFG_SGMII,4,2      ; @AT803X_MODE_CFG_SGMII
	.comm	_AT803X_BT_BX_REG_SEL,4,2       ; @AT803X_BT_BX_REG_SEL
	.comm	_AT803X_PSSR,4,2                ; @AT803X_PSSR
	.comm	_AT803X_PSSR_MR_AN_COMPLETE,4,2 ; @AT803X_PSSR_MR_AN_COMPLETE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"803x_aneg_done: SGMII link is not ok\n"

	.no_dead_strip	_at803x_aneg_done
.subsections_via_symbols
