	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_genphy_config_advert           ## -- Begin function genphy_config_advert
	.p2align	4, 0x90
_genphy_config_advert:                  ## @genphy_config_advert
	.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
	movl	(%rdi), %r14d
	andl	4(%rdi), %r14d
	movl	%r14d, (%rdi)
	movq	_MII_ADVERTISE@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	callq	_phy_read
	movl	%eax, %r15d
	testl	%eax, %eax
	js	LBB0_9
## %bb.1:
	movq	_ADVERTISE_ALL@GOTPCREL(%rip), %rax
	movq	_ADVERTISE_100BASE4@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ebx
	orl	(%rax), %ebx
	movq	_ADVERTISE_PAUSE_CAP@GOTPCREL(%rip), %rax
	orl	(%rax), %ebx
	movq	_ADVERTISE_PAUSE_ASYM@GOTPCREL(%rip), %rax
	orl	(%rax), %ebx
	notl	%ebx
	andl	%r15d, %ebx
	movl	%r14d, %edi
	callq	_ethtool_adv_to_mii_adv_t
	orl	%ebx, %eax
	xorl	%ebx, %ebx
	cmpl	%r15d, %eax
	je	LBB0_3
## %bb.2:
	movl	(%r13), %esi
	movq	%r12, %rdi
	movl	%eax, %edx
	callq	_phy_write
	movl	$1, %ebx
	testl	%eax, %eax
	js	LBB0_7
LBB0_3:
	movq	_SUPPORTED_1000baseT_Half@GOTPCREL(%rip), %rax
	movq	_SUPPORTED_1000baseT_Full@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	testl	%ecx, 4(%r12)
	je	LBB0_10
## %bb.4:
	movq	_MII_CTRL1000@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_phy_read
	movl	%eax, %r15d
	testl	%eax, %eax
	js	LBB0_9
## %bb.5:
	movq	_ADVERTISE_1000FULL@GOTPCREL(%rip), %rax
	movq	_ADVERTISE_1000HALF@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r13d
	orl	(%rax), %r13d
	notl	%r13d
	andl	%r15d, %r13d
	movl	%r14d, %edi
	callq	_ethtool_adv_to_mii_ctrl1000_t
	orl	%r13d, %eax
	cmpl	%r15d, %eax
	je	LBB0_10
## %bb.6:
	movq	_MII_CTRL1000@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movq	%r12, %rdi
	movl	%eax, %edx
	callq	_phy_write
	movl	$1, %ebx
	testl	%eax, %eax
	jns	LBB0_10
LBB0_7:
	movl	%eax, %ebx
	jmp	LBB0_10
LBB0_9:
	movl	%r15d, %ebx
LBB0_10:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MII_ADVERTISE,4,2              ## @MII_ADVERTISE
	.comm	_ADVERTISE_ALL,4,2              ## @ADVERTISE_ALL
	.comm	_ADVERTISE_100BASE4,4,2         ## @ADVERTISE_100BASE4
	.comm	_ADVERTISE_PAUSE_CAP,4,2        ## @ADVERTISE_PAUSE_CAP
	.comm	_ADVERTISE_PAUSE_ASYM,4,2       ## @ADVERTISE_PAUSE_ASYM
	.comm	_SUPPORTED_1000baseT_Half,4,2   ## @SUPPORTED_1000baseT_Half
	.comm	_SUPPORTED_1000baseT_Full,4,2   ## @SUPPORTED_1000baseT_Full
	.comm	_MII_CTRL1000,4,2               ## @MII_CTRL1000
	.comm	_ADVERTISE_1000FULL,4,2         ## @ADVERTISE_1000FULL
	.comm	_ADVERTISE_1000HALF,4,2         ## @ADVERTISE_1000HALF
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_genphy_config_advert           ; -- Begin function genphy_config_advert
	.p2align	2
_genphy_config_advert:                  ; @genphy_config_advert
	.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
	ldp	w9, w8, [x0]
	and	w21, w9, w8
	str	w21, [x0]
Lloh0:
	adrp	x22, _MII_ADVERTISE@GOTPAGE
Lloh1:
	ldr	x22, [x22, _MII_ADVERTISE@GOTPAGEOFF]
	ldr	w1, [x22]
	bl	_phy_read
	mov	x20, x0
	tbnz	w0, #31, LBB0_12
; %bb.1:
Lloh2:
	adrp	x8, _ADVERTISE_ALL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _ADVERTISE_ALL@GOTPAGEOFF]
Lloh4:
	adrp	x9, _ADVERTISE_100BASE4@GOTPAGE
Lloh5:
	ldr	x9, [x9, _ADVERTISE_100BASE4@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
Lloh7:
	ldr	w9, [x9]
	orr	w8, w9, w8
Lloh8:
	adrp	x9, _ADVERTISE_PAUSE_CAP@GOTPAGE
Lloh9:
	ldr	x9, [x9, _ADVERTISE_PAUSE_CAP@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
	orr	w8, w8, w9
Lloh11:
	adrp	x9, _ADVERTISE_PAUSE_ASYM@GOTPAGE
Lloh12:
	ldr	x9, [x9, _ADVERTISE_PAUSE_ASYM@GOTPAGEOFF]
Lloh13:
	ldr	w9, [x9]
	orr	w8, w8, w9
	bic	w23, w20, w8
	mov	x0, x21
	bl	_ethtool_adv_to_mii_adv_t
	orr	w2, w23, w0
	cmp	w2, w20
	b.ne	LBB0_3
; %bb.2:
	mov	w20, #0
	b	LBB0_5
LBB0_3:
	ldr	w1, [x22]
	mov	x0, x19
	bl	_phy_write
	tbnz	w0, #31, LBB0_10
; %bb.4:
	mov	w20, #1
LBB0_5:
	ldr	w8, [x19, #4]
Lloh14:
	adrp	x9, _SUPPORTED_1000baseT_Half@GOTPAGE
Lloh15:
	ldr	x9, [x9, _SUPPORTED_1000baseT_Half@GOTPAGEOFF]
Lloh16:
	ldr	w9, [x9]
Lloh17:
	adrp	x10, _SUPPORTED_1000baseT_Full@GOTPAGE
Lloh18:
	ldr	x10, [x10, _SUPPORTED_1000baseT_Full@GOTPAGEOFF]
Lloh19:
	ldr	w10, [x10]
	orr	w9, w10, w9
	tst	w9, w8
	b.eq	LBB0_12
; %bb.6:
Lloh20:
	adrp	x23, _MII_CTRL1000@GOTPAGE
Lloh21:
	ldr	x23, [x23, _MII_CTRL1000@GOTPAGEOFF]
	ldr	w1, [x23]
	mov	x0, x19
	bl	_phy_read
	mov	x22, x0
	tbnz	w0, #31, LBB0_11
; %bb.7:
Lloh22:
	adrp	x8, _ADVERTISE_1000FULL@GOTPAGE
Lloh23:
	ldr	x8, [x8, _ADVERTISE_1000FULL@GOTPAGEOFF]
Lloh24:
	ldr	w8, [x8]
Lloh25:
	adrp	x9, _ADVERTISE_1000HALF@GOTPAGE
Lloh26:
	ldr	x9, [x9, _ADVERTISE_1000HALF@GOTPAGEOFF]
Lloh27:
	ldr	w9, [x9]
	orr	w8, w9, w8
	bic	w24, w22, w8
	mov	x0, x21
	bl	_ethtool_adv_to_mii_ctrl1000_t
	orr	w2, w24, w0
	cmp	w2, w22
	b.eq	LBB0_12
; %bb.8:
	ldr	w1, [x23]
	mov	x0, x19
	bl	_phy_write
	tbnz	w0, #31, LBB0_10
; %bb.9:
	mov	w20, #1
	b	LBB0_12
LBB0_10:
	mov	x20, x0
	b	LBB0_12
LBB0_11:
	mov	x20, x22
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 AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh6
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.cfi_endproc
                                        ; -- End function
	.comm	_MII_ADVERTISE,4,2              ; @MII_ADVERTISE
	.comm	_ADVERTISE_ALL,4,2              ; @ADVERTISE_ALL
	.comm	_ADVERTISE_100BASE4,4,2         ; @ADVERTISE_100BASE4
	.comm	_ADVERTISE_PAUSE_CAP,4,2        ; @ADVERTISE_PAUSE_CAP
	.comm	_ADVERTISE_PAUSE_ASYM,4,2       ; @ADVERTISE_PAUSE_ASYM
	.comm	_SUPPORTED_1000baseT_Half,4,2   ; @SUPPORTED_1000baseT_Half
	.comm	_SUPPORTED_1000baseT_Full,4,2   ; @SUPPORTED_1000baseT_Full
	.comm	_MII_CTRL1000,4,2               ; @MII_CTRL1000
	.comm	_ADVERTISE_1000FULL,4,2         ; @ADVERTISE_1000FULL
	.comm	_ADVERTISE_1000HALF,4,2         ; @ADVERTISE_1000HALF
.subsections_via_symbols
