	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function stmmac_xgmac2_mdio_write
_stmmac_xgmac2_mdio_write:              ## @stmmac_xgmac2_mdio_write
	.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
	subq	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%ecx, %ebx
	movl	%edx, %r13d
	movl	%esi, %r14d
	movq	(%rdi), %rdi
	callq	_netdev_priv
	movq	%rax, %r12
	movq	_MII_ADDR_C45@GOTPCREL(%rip), %rax
	testl	%r13d, (%rax)
	je	LBB0_3
## %bb.1:
	movq	_EOPNOTSUPP@GOTPCREL(%rip), %rcx
LBB0_2:
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_7
LBB0_3:
	movl	%ebx, -52(%rbp)                 ## 4-byte Spill
	movq	16(%r12), %rax
	movl	(%rax), %ebx
	movl	4(%rax), %eax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movq	_MII_XGMAC_BUSY@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	leaq	-56(%rbp), %rcx
	movq	%r12, %rdi
	movl	%r14d, %esi
	movl	%r13d, %edx
	callq	_stmmac_xgmac2_c22_format
	testl	%eax, %eax
	je	LBB0_4
LBB0_7:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	movl	%r15d, -48(%rbp)                ## 4-byte Spill
	movq	%rbx, -72(%rbp)                 ## 8-byte Spill
	movl	(%r12), %r14d
	movq	16(%r12), %rax
	movl	8(%rax), %ecx
	movl	%ecx, -44(%rbp)                 ## 4-byte Spill
	movl	12(%rax), %r13d
	movq	_MII_XGMAC_SADDR@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movq	_MII_XGMAC_WRITE@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	8(%r12), %rdi
	addq	-64(%rbp), %rdi                 ## 8-byte Folded Reload
	movl	$1, %edx
	movl	$100, %ecx
	movl	$10000, %r8d                    ## imm = 0x2710
	callq	_readl_poll_timeout
	testl	%eax, %eax
	je	LBB0_6
## %bb.5:
	movq	_EBUSY@GOTPCREL(%rip), %rcx
	jmp	LBB0_2
LBB0_6:
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
                                        ## kill: def $cl killed $cl killed $ecx
	shll	%cl, %r14d
	andl	%r13d, %r14d
	movl	%ebx, %eax
	movl	-48(%rbp), %ebx                 ## 4-byte Reload
	orl	-52(%rbp), %ebx                 ## 4-byte Folded Reload
	orl	%r14d, %ebx
	orl	%r15d, %ebx
	orl	%eax, %ebx
	movl	-56(%rbp), %edi
	movq	-72(%rbp), %rsi                 ## 8-byte Reload
	addq	8(%r12), %rsi
	callq	_writel
	movq	8(%r12), %rsi
	movq	-64(%rbp), %r14                 ## 8-byte Reload
	addq	%r14, %rsi
	movl	%ebx, %edi
	callq	_writel
	addq	8(%r12), %r14
	movq	%r14, %rdi
	movl	$1, %edx
	movl	$100, %ecx
	movl	$10000, %r8d                    ## imm = 0x2710
	callq	_readl_poll_timeout
	jmp	LBB0_7
	.cfi_endproc
                                        ## -- End function
	.comm	_MII_XGMAC_BUSY,4,2             ## @MII_XGMAC_BUSY
	.comm	_MII_ADDR_C45,4,2               ## @MII_ADDR_C45
	.comm	_EOPNOTSUPP,4,2                 ## @EOPNOTSUPP
	.comm	_MII_XGMAC_SADDR,4,2            ## @MII_XGMAC_SADDR
	.comm	_MII_XGMAC_WRITE,4,2            ## @MII_XGMAC_WRITE
	.comm	_EBUSY,4,2                      ## @EBUSY
	.no_dead_strip	_stmmac_xgmac2_mdio_write
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function stmmac_xgmac2_mdio_write
_stmmac_xgmac2_mdio_write:              ; @stmmac_xgmac2_mdio_write
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x20, x3
	mov	x21, x2
	mov	x22, x1
	ldr	x0, [x0]
	bl	_netdev_priv
Lloh0:
	adrp	x8, _MII_ADDR_C45@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MII_ADDR_C45@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	tst	w8, w21
	b.eq	LBB0_3
; %bb.1:
Lloh3:
	adrp	x8, _EOPNOTSUPP@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EOPNOTSUPP@GOTPAGEOFF]
LBB0_2:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_4
LBB0_3:
	mov	x19, x0
	ldr	x8, [x0, #16]
	ldp	w24, w23, [x8]
Lloh5:
	adrp	x8, _MII_XGMAC_BUSY@GOTPAGE
Lloh6:
	ldr	x8, [x8, _MII_XGMAC_BUSY@GOTPAGEOFF]
Lloh7:
	ldr	w25, [x8]
	add	x3, sp, #12
	mov	x1, x22
	mov	x2, x21
	bl	_stmmac_xgmac2_c22_format
	cbz	w0, LBB0_5
LBB0_4:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_5:
	ldr	w21, [x19]
Lloh8:
	adrp	x8, _MII_XGMAC_SADDR@GOTPAGE
Lloh9:
	ldr	x8, [x8, _MII_XGMAC_SADDR@GOTPAGEOFF]
	ldp	x10, x9, [x19, #8]
	ldp	w28, w27, [x9, #8]
Lloh10:
	ldr	w22, [x8]
Lloh11:
	adrp	x8, _MII_XGMAC_WRITE@GOTPAGE
Lloh12:
	ldr	x8, [x8, _MII_XGMAC_WRITE@GOTPAGEOFF]
Lloh13:
	ldr	w26, [x8]
	add	x0, x10, x23
	mov	w2, #1
	mov	w3, #100
	mov	w4, #10000
	bl	_readl_poll_timeout
	cbz	w0, LBB0_7
; %bb.6:
Lloh14:
	adrp	x8, _EBUSY@GOTPAGE
Lloh15:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
	b	LBB0_2
LBB0_7:
	lsl	w8, w21, w28
	and	w8, w8, w27
	orr	w9, w25, w20
	orr	w8, w9, w8
	orr	w8, w8, w22
	orr	w20, w8, w26
	ldr	w0, [sp, #12]
	ldr	x8, [x19, #8]
	add	x1, x8, x24
	bl	_writel
	ldr	x8, [x19, #8]
	add	x1, x8, x23
	mov	x0, x20
	bl	_writel
	ldr	x8, [x19, #8]
	add	x0, x8, x23
	mov	w2, #1
	mov	w3, #100
	mov	w4, #10000
	bl	_readl_poll_timeout
	b	LBB0_4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.comm	_MII_XGMAC_BUSY,4,2             ; @MII_XGMAC_BUSY
	.comm	_MII_ADDR_C45,4,2               ; @MII_ADDR_C45
	.comm	_EOPNOTSUPP,4,2                 ; @EOPNOTSUPP
	.comm	_MII_XGMAC_SADDR,4,2            ; @MII_XGMAC_SADDR
	.comm	_MII_XGMAC_WRITE,4,2            ; @MII_XGMAC_WRITE
	.comm	_EBUSY,4,2                      ; @EBUSY
	.no_dead_strip	_stmmac_xgmac2_mdio_write
.subsections_via_symbols
