	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function xm_phy_write
_xm_phy_write:                          ## @xm_phy_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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%ecx, -44(%rbp)                 ## 4-byte Spill
	movl	%edx, %ecx
	movl	%esi, %r14d
	movq	%rdi, %r15
	movq	_XM_PHY_ADDR@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	orl	(%rdi), %ecx
	callq	_xm_write16
	movq	_PHY_RETRIES@GOTPCREL(%rip), %r12
	cmpl	$0, (%r12)
	jle	LBB0_4
## %bb.1:
	xorl	%r13d, %r13d
	movq	_XM_MMU_CMD@GOTPCREL(%rip), %rbx
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%rbx), %edx
	movq	%r15, %rdi
	movl	%r14d, %esi
	callq	_xm_read16
	movq	_XM_MMU_PHY_BUSY@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_5
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	$1, %edi
	callq	_udelay
	incl	%r13d
	cmpl	(%r12), %r13d
	jl	LBB0_2
LBB0_4:
	movq	_EIO@GOTPCREL(%rip), %rcx
	jmp	LBB0_11
LBB0_5:
	movq	%rbx, %r13
	movq	_XM_PHY_DATA@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r15, %rdi
	movl	%r14d, %esi
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	callq	_xm_write16
	cmpl	$0, (%r12)
	jle	LBB0_10
## %bb.6:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r13), %edx
	movq	%r15, %rdi
	movl	%r14d, %esi
	callq	_xm_read16
	movq	_XM_MMU_PHY_BUSY@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_8
## %bb.9:                               ##   in Loop: Header=BB0_7 Depth=1
	movl	$1, %edi
	callq	_udelay
	incl	%ebx
	cmpl	(%r12), %ebx
	jl	LBB0_7
LBB0_10:
	movq	_ETIMEDOUT@GOTPCREL(%rip), %rcx
LBB0_11:
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_12:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_8:
	xorl	%eax, %eax
	jmp	LBB0_12
	.cfi_endproc
                                        ## -- End function
	.comm	_XM_PHY_ADDR,4,2                ## @XM_PHY_ADDR
	.comm	_PHY_RETRIES,4,2                ## @PHY_RETRIES
	.comm	_XM_MMU_CMD,4,2                 ## @XM_MMU_CMD
	.comm	_XM_MMU_PHY_BUSY,4,2            ## @XM_MMU_PHY_BUSY
	.comm	_EIO,4,2                        ## @EIO
	.comm	_XM_PHY_DATA,4,2                ## @XM_PHY_DATA
	.comm	_ETIMEDOUT,4,2                  ## @ETIMEDOUT
	.no_dead_strip	_xm_phy_write
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function xm_phy_write
_xm_phy_write:                          ; @xm_phy_write
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x21, x3
	mov	x19, x1
	mov	x20, x0
Lloh0:
	adrp	x8, _XM_PHY_ADDR@GOTPAGE
Lloh1:
	ldr	x8, [x8, _XM_PHY_ADDR@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	ldr	w9, [x0]
	orr	w3, w9, w2
	mov	x2, x8
	bl	_xm_write16
Lloh3:
	adrp	x22, _PHY_RETRIES@GOTPAGE
Lloh4:
	ldr	x22, [x22, _PHY_RETRIES@GOTPAGEOFF]
	ldr	w8, [x22]
	cmp	w8, #1
	b.lt	LBB0_4
; %bb.1:
	mov	w25, #0
Lloh5:
	adrp	x23, _XM_MMU_CMD@GOTPAGE
Lloh6:
	ldr	x23, [x23, _XM_MMU_CMD@GOTPAGEOFF]
Lloh7:
	adrp	x24, _XM_MMU_PHY_BUSY@GOTPAGE
Lloh8:
	ldr	x24, [x24, _XM_MMU_PHY_BUSY@GOTPAGEOFF]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w2, [x23]
	mov	x0, x20
	mov	x1, x19
	bl	_xm_read16
	ldr	w8, [x24]
	tst	w8, w0
	b.eq	LBB0_5
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	mov	w0, #1
	bl	_udelay
	add	w25, w25, #1
	ldr	w8, [x22]
	cmp	w25, w8
	b.lt	LBB0_2
LBB0_4:
Lloh9:
	adrp	x8, _EIO@GOTPAGE
Lloh10:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
	b	LBB0_10
LBB0_5:
Lloh11:
	adrp	x8, _XM_PHY_DATA@GOTPAGE
Lloh12:
	ldr	x8, [x8, _XM_PHY_DATA@GOTPAGEOFF]
Lloh13:
	ldr	w2, [x8]
	mov	x0, x20
	mov	x1, x19
	mov	x3, x21
	bl	_xm_write16
	ldr	w8, [x22]
	cmp	w8, #1
	b.lt	LBB0_9
; %bb.6:
	mov	w21, #0
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w2, [x23]
	mov	x0, x20
	mov	x1, x19
	bl	_xm_read16
	ldr	w8, [x24]
	tst	w8, w0
	b.eq	LBB0_12
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	mov	w0, #1
	bl	_udelay
	add	w21, w21, #1
	ldr	w8, [x22]
	cmp	w21, w8
	b.lt	LBB0_7
LBB0_9:
Lloh14:
	adrp	x8, _ETIMEDOUT@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ETIMEDOUT@GOTPAGEOFF]
LBB0_10:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_11:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_12:
	mov	w0, #0
	b	LBB0_11
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.comm	_XM_PHY_ADDR,4,2                ; @XM_PHY_ADDR
	.comm	_PHY_RETRIES,4,2                ; @PHY_RETRIES
	.comm	_XM_MMU_CMD,4,2                 ; @XM_MMU_CMD
	.comm	_XM_MMU_PHY_BUSY,4,2            ; @XM_MMU_PHY_BUSY
	.comm	_EIO,4,2                        ; @EIO
	.comm	_XM_PHY_DATA,4,2                ; @XM_PHY_DATA
	.comm	_ETIMEDOUT,4,2                  ; @ETIMEDOUT
	.no_dead_strip	_xm_phy_write
.subsections_via_symbols
