	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function rtl8125_read_mmd
_rtl8125_read_mmd:                      ## @rtl8125_read_mmd
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r15
	movl	%esi, %ebx
	movq	%rdi, %r14
	callq	_rtlgen_read_mmd
	movq	_EOPNOTSUPP@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	addl	%eax, %ecx
	jne	LBB0_9
## %bb.1:
	movq	_MDIO_MMD_PCS@GOTPCREL(%rip), %rcx
	cmpl	%ebx, (%rcx)
	jne	LBB0_4
## %bb.2:
	movq	_MDIO_PCS_EEE_ABLE2@GOTPCREL(%rip), %rcx
	cmpq	%r15, (%rcx)
	jne	LBB0_4
## %bb.3:
	movl	$22, %r12d
	movl	$2670, %esi                     ## imm = 0xA6E
	jmp	LBB0_8
LBB0_4:
	movq	_MDIO_MMD_AN@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	$2669, %esi                     ## imm = 0xA6D
	cmpl	%ebx, %ecx
	jne	LBB0_6
## %bb.5:
	movq	_MDIO_AN_EEE_ADV2@GOTPCREL(%rip), %rdx
	movl	$18, %r12d
	cmpq	%r15, (%rdx)
	je	LBB0_8
LBB0_6:
	cmpl	%ebx, %ecx
	jne	LBB0_9
## %bb.7:
	movq	_MDIO_AN_EEE_LPABLE2@GOTPCREL(%rip), %rcx
	movl	$16, %r12d
	cmpq	%r15, (%rcx)
	jne	LBB0_9
LBB0_8:
	movq	%r14, %rdi
	callq	_rtl821x_write_page
	movq	%r14, %rdi
	movl	%r12d, %esi
	callq	___phy_read
	movl	%eax, %ebx
	movq	%r14, %rdi
	xorl	%esi, %esi
	callq	_rtl821x_write_page
	movl	%ebx, %eax
LBB0_9:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EOPNOTSUPP,4,2                 ## @EOPNOTSUPP
	.comm	_MDIO_MMD_PCS,4,2               ## @MDIO_MMD_PCS
	.comm	_MDIO_PCS_EEE_ABLE2,8,3         ## @MDIO_PCS_EEE_ABLE2
	.comm	_MDIO_MMD_AN,4,2                ## @MDIO_MMD_AN
	.comm	_MDIO_AN_EEE_ADV2,8,3           ## @MDIO_AN_EEE_ADV2
	.comm	_MDIO_AN_EEE_LPABLE2,8,3        ## @MDIO_AN_EEE_LPABLE2
	.no_dead_strip	_rtl8125_read_mmd
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function rtl8125_read_mmd
_rtl8125_read_mmd:                      ; @rtl8125_read_mmd
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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	x20, x2
	mov	x21, x1
	mov	x19, x0
	bl	_rtlgen_read_mmd
Lloh0:
	adrp	x8, _EOPNOTSUPP@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EOPNOTSUPP@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmn	w0, w8
	b.ne	LBB0_9
; %bb.1:
Lloh3:
	adrp	x8, _MDIO_MMD_PCS@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MDIO_MMD_PCS@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
Lloh6:
	adrp	x9, _MDIO_PCS_EEE_ABLE2@GOTPAGE
Lloh7:
	ldr	x9, [x9, _MDIO_PCS_EEE_ABLE2@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	cmp	w8, w21
	ccmp	x9, x20, #0, eq
	b.eq	LBB0_5
; %bb.2:
Lloh9:
	adrp	x8, _MDIO_MMD_AN@GOTPAGE
Lloh10:
	ldr	x8, [x8, _MDIO_MMD_AN@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
Lloh12:
	adrp	x9, _MDIO_AN_EEE_ADV2@GOTPAGE
Lloh13:
	ldr	x9, [x9, _MDIO_AN_EEE_ADV2@GOTPAGEOFF]
Lloh14:
	ldr	x9, [x9]
	cmp	w8, w21
	ccmp	x9, x20, #0, eq
	b.eq	LBB0_6
; %bb.3:
Lloh15:
	adrp	x9, _MDIO_AN_EEE_LPABLE2@GOTPAGE
Lloh16:
	ldr	x9, [x9, _MDIO_AN_EEE_LPABLE2@GOTPAGEOFF]
Lloh17:
	ldr	x9, [x9]
	cmp	w8, w21
	ccmp	x9, x20, #0, eq
	b.ne	LBB0_9
; %bb.4:
	mov	w20, #16
	b	LBB0_7
LBB0_5:
	mov	w20, #22
	mov	w1, #2670
	b	LBB0_8
LBB0_6:
	mov	w20, #18
LBB0_7:
	mov	w1, #2669
LBB0_8:
	mov	x0, x19
	bl	_rtl821x_write_page
	mov	x0, x19
	mov	x1, x20
	bl	___phy_read
	mov	x20, x0
	mov	x0, x19
	mov	w1, #0
	bl	_rtl821x_write_page
	mov	x0, x20
LBB0_9:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_EOPNOTSUPP,4,2                 ; @EOPNOTSUPP
	.comm	_MDIO_MMD_PCS,4,2               ; @MDIO_MMD_PCS
	.comm	_MDIO_PCS_EEE_ABLE2,8,3         ; @MDIO_PCS_EEE_ABLE2
	.comm	_MDIO_MMD_AN,4,2                ; @MDIO_MMD_AN
	.comm	_MDIO_AN_EEE_ADV2,8,3           ; @MDIO_AN_EEE_ADV2
	.comm	_MDIO_AN_EEE_LPABLE2,8,3        ; @MDIO_AN_EEE_LPABLE2
	.no_dead_strip	_rtl8125_read_mmd
.subsections_via_symbols
