	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sun4i_mdio_read
_sun4i_mdio_read:                       ## @sun4i_mdio_read
	.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
	movl	%esi, %eax
	movq	(%rdi), %r14
	shll	$8, %eax
	orl	%edx, %eax
	movq	_EMAC_MAC_MADR_REG@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rsi
	addq	(%r14), %rsi
	movl	%eax, %edi
	callq	_writel
	movq	_EMAC_MAC_MCMD_REG@GOTPCREL(%rip), %r15
	movq	(%r15), %rsi
	addq	(%r14), %rsi
	movl	$1, %edi
	callq	_writel
	movq	_jiffies@GOTPCREL(%rip), %rax
	movq	_MDIO_TIMEOUT@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rbx
	addq	(%rax), %rbx
	movq	_EMAC_MAC_MIND_REG@GOTPCREL(%rip), %r12
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r12), %rdi
	addq	(%r14), %rdi
	callq	_readl
	testb	$1, %al
	je	LBB0_4
## %bb.2:                               ##   in Loop: Header=BB0_1 Depth=1
	movq	%rbx, %rdi
	callq	_time_is_before_jiffies
	testq	%rax, %rax
	jne	LBB0_5
## %bb.3:                               ##   in Loop: Header=BB0_1 Depth=1
	movl	$1, %edi
	callq	_msleep
	jmp	LBB0_1
LBB0_4:
	movq	(%r15), %rsi
	addq	(%r14), %rsi
	xorl	%edi, %edi
	callq	_writel
	movq	_EMAC_MAC_MRDD_REG@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	(%r14), %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_readl                          ## TAILCALL
LBB0_5:
	movq	_ETIMEDOUT@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EMAC_MAC_MADR_REG,8,3          ## @EMAC_MAC_MADR_REG
	.comm	_EMAC_MAC_MCMD_REG,8,3          ## @EMAC_MAC_MCMD_REG
	.comm	_jiffies,8,3                    ## @jiffies
	.comm	_MDIO_TIMEOUT,8,3               ## @MDIO_TIMEOUT
	.comm	_EMAC_MAC_MIND_REG,8,3          ## @EMAC_MAC_MIND_REG
	.comm	_ETIMEDOUT,4,2                  ## @ETIMEDOUT
	.comm	_EMAC_MAC_MRDD_REG,8,3          ## @EMAC_MAC_MRDD_REG
	.no_dead_strip	_sun4i_mdio_read
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sun4i_mdio_read
_sun4i_mdio_read:                       ; @sun4i_mdio_read
	.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
	ldr	x20, [x0]
	orr	w0, w2, w1, lsl #8
	ldr	x8, [x20]
Lloh0:
	adrp	x9, _EMAC_MAC_MADR_REG@GOTPAGE
Lloh1:
	ldr	x9, [x9, _EMAC_MAC_MADR_REG@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	add	x1, x9, x8
	bl	_writel
	ldr	x8, [x20]
Lloh3:
	adrp	x21, _EMAC_MAC_MCMD_REG@GOTPAGE
Lloh4:
	ldr	x21, [x21, _EMAC_MAC_MCMD_REG@GOTPAGEOFF]
	ldr	x9, [x21]
	add	x1, x9, x8
	mov	w0, #1
	bl	_writel
Lloh5:
	adrp	x8, _jiffies@GOTPAGE
Lloh6:
	ldr	x8, [x8, _jiffies@GOTPAGEOFF]
Lloh7:
	ldr	x19, [x8]
Lloh8:
	adrp	x8, _MDIO_TIMEOUT@GOTPAGE
Lloh9:
	ldr	x8, [x8, _MDIO_TIMEOUT@GOTPAGEOFF]
Lloh10:
	ldr	x23, [x8]
	ldr	x8, [x20]
Lloh11:
	adrp	x22, _EMAC_MAC_MIND_REG@GOTPAGE
Lloh12:
	ldr	x22, [x22, _EMAC_MAC_MIND_REG@GOTPAGEOFF]
	ldr	x9, [x22]
	add	x0, x9, x8
	bl	_readl
	tbz	w0, #0, LBB0_4
; %bb.1:
	add	x19, x23, x19
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	bl	_time_is_before_jiffies
	cbnz	x0, LBB0_5
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	mov	w0, #1
	bl	_msleep
	ldr	x8, [x20]
	ldr	x9, [x22]
	add	x0, x9, x8
	bl	_readl
	tbnz	w0, #0, LBB0_2
LBB0_4:
	ldr	x8, [x20]
	ldr	x9, [x21]
	add	x1, x9, x8
	mov	w0, #0
	bl	_writel
	ldr	x8, [x20]
Lloh13:
	adrp	x9, _EMAC_MAC_MRDD_REG@GOTPAGE
Lloh14:
	ldr	x9, [x9, _EMAC_MAC_MRDD_REG@GOTPAGEOFF]
Lloh15:
	ldr	x9, [x9]
	add	x0, x9, x8
	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
	b	_readl
LBB0_5:
Lloh16:
	adrp	x8, _ETIMEDOUT@GOTPAGE
Lloh17:
	ldr	x8, [x8, _ETIMEDOUT@GOTPAGEOFF]
Lloh18:
	ldr	w8, [x8]
	neg	w0, w8
	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	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_EMAC_MAC_MADR_REG,8,3          ; @EMAC_MAC_MADR_REG
	.comm	_EMAC_MAC_MCMD_REG,8,3          ; @EMAC_MAC_MCMD_REG
	.comm	_jiffies,8,3                    ; @jiffies
	.comm	_MDIO_TIMEOUT,8,3               ; @MDIO_TIMEOUT
	.comm	_EMAC_MAC_MIND_REG,8,3          ; @EMAC_MAC_MIND_REG
	.comm	_ETIMEDOUT,4,2                  ; @ETIMEDOUT
	.comm	_EMAC_MAC_MRDD_REG,8,3          ; @EMAC_MAC_MRDD_REG
	.no_dead_strip	_sun4i_mdio_read
.subsections_via_symbols
