	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mvebu_comphy_init_plls
_mvebu_comphy_init_plls:                ## @mvebu_comphy_init_plls
	.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, %r14
	movq	8(%rdi), %r12
	movq	(%r12), %rbx
	movl	(%rdi), %edi
	callq	_MVEBU_COMPHY_SERDES_CFG0
	addq	%rax, %rbx
	movq	%rbx, %rdi
	callq	_readl
	movl	%eax, %ebx
	movq	_MVEBU_COMPHY_SERDES_CFG0_PU_PLL@GOTPCREL(%rip), %rax
	movq	_MVEBU_COMPHY_SERDES_CFG0_PU_RX@GOTPCREL(%rip), %rcx
	movq	_MVEBU_COMPHY_SERDES_CFG0_PU_TX@GOTPCREL(%rip), %rdx
	orl	(%rax), %ebx
	orl	(%rcx), %ebx
	orl	(%rdx), %ebx
	movq	(%r12), %r15
	movl	(%r14), %edi
	callq	_MVEBU_COMPHY_SERDES_CFG0
	addq	%rax, %r15
	movl	%ebx, %edi
	movq	%r15, %rsi
	callq	_writel
	movq	(%r12), %r15
	movl	(%r14), %edi
	callq	_MVEBU_COMPHY_SERDES_STATUS0
	addq	%rax, %r15
	movq	_MVEBU_COMPHY_SERDES_STATUS0_RX_PLL_RDY@GOTPCREL(%rip), %rax
	movq	_MVEBU_COMPHY_SERDES_STATUS0_TX_PLL_RDY@GOTPCREL(%rip), %r13
	movl	(%r13), %edx
	orl	(%rax), %edx
	andl	%ebx, %edx
	movq	%r15, %rdi
	movl	%ebx, %esi
	movl	$1000, %ecx                     ## imm = 0x3E8
	movl	$150000, %r8d                   ## imm = 0x249F0
	callq	_readl_poll_timeout
	movl	(%r13), %eax
	movq	_MVEBU_COMPHY_SERDES_STATUS0_RX_PLL_RDY@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	testl	%ebx, %eax
	je	LBB0_1
## %bb.2:
	movq	(%r12), %rbx
	movl	(%r14), %edi
	callq	_MVEBU_COMPHY_SERDES_CFG1
	addq	%rax, %rbx
	movq	%rbx, %rdi
	callq	_readl
	movl	%eax, %r15d
	movq	_MVEBU_COMPHY_SERDES_CFG1_RX_INIT@GOTPCREL(%rip), %rax
	orl	(%rax), %r15d
	movq	(%r12), %rbx
	movl	(%r14), %edi
	callq	_MVEBU_COMPHY_SERDES_CFG1
	addq	%rax, %rbx
	movl	%r15d, %edi
	movq	%rbx, %rsi
	callq	_writel
	movq	(%r12), %rbx
	movl	(%r14), %edi
	callq	_MVEBU_COMPHY_SERDES_STATUS0
	addq	%rax, %rbx
	movq	_MVEBU_COMPHY_SERDES_STATUS0_RX_INIT@GOTPCREL(%rip), %r13
	movl	(%r13), %edx
	andl	%r15d, %edx
	movq	%rbx, %rdi
	movl	%r15d, %esi
	movl	$1000, %ecx                     ## imm = 0x3E8
	movl	$10000, %r8d                    ## imm = 0x2710
	callq	_readl_poll_timeout
	testl	%r15d, (%r13)
	je	LBB0_1
## %bb.3:
	movq	(%r12), %rbx
	movl	(%r14), %edi
	callq	_MVEBU_COMPHY_SERDES_CFG1
	addq	%rax, %rbx
	movq	%rbx, %rdi
	callq	_readl
	movq	_MVEBU_COMPHY_SERDES_CFG1_RX_INIT@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ebx
	notl	%ebx
	andl	%eax, %ebx
	movq	(%r12), %r15
	movl	(%r14), %edi
	callq	_MVEBU_COMPHY_SERDES_CFG1
	addq	%rax, %r15
	movl	%ebx, %edi
	movq	%r15, %rsi
	callq	_writel
	xorl	%eax, %eax
	jmp	LBB0_4
LBB0_1:
	movq	_ETIMEDOUT@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_4:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MVEBU_COMPHY_SERDES_CFG0_PU_PLL,4,2 ## @MVEBU_COMPHY_SERDES_CFG0_PU_PLL
	.comm	_MVEBU_COMPHY_SERDES_CFG0_PU_RX,4,2 ## @MVEBU_COMPHY_SERDES_CFG0_PU_RX
	.comm	_MVEBU_COMPHY_SERDES_CFG0_PU_TX,4,2 ## @MVEBU_COMPHY_SERDES_CFG0_PU_TX
	.comm	_MVEBU_COMPHY_SERDES_STATUS0_RX_PLL_RDY,4,2 ## @MVEBU_COMPHY_SERDES_STATUS0_RX_PLL_RDY
	.comm	_MVEBU_COMPHY_SERDES_STATUS0_TX_PLL_RDY,4,2 ## @MVEBU_COMPHY_SERDES_STATUS0_TX_PLL_RDY
	.comm	_ETIMEDOUT,4,2                  ## @ETIMEDOUT
	.comm	_MVEBU_COMPHY_SERDES_CFG1_RX_INIT,4,2 ## @MVEBU_COMPHY_SERDES_CFG1_RX_INIT
	.comm	_MVEBU_COMPHY_SERDES_STATUS0_RX_INIT,4,2 ## @MVEBU_COMPHY_SERDES_STATUS0_RX_INIT
	.no_dead_strip	_mvebu_comphy_init_plls
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mvebu_comphy_init_plls
_mvebu_comphy_init_plls:                ; @mvebu_comphy_init_plls
	.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
	ldr	x21, [x0, #8]
	ldr	x20, [x21]
	ldr	w0, [x0]
	bl	_MVEBU_COMPHY_SERDES_CFG0
	add	x0, x0, x20
	bl	_readl
Lloh0:
	adrp	x8, _MVEBU_COMPHY_SERDES_CFG0_PU_PLL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MVEBU_COMPHY_SERDES_CFG0_PU_PLL@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, _MVEBU_COMPHY_SERDES_CFG0_PU_RX@GOTPAGE
Lloh4:
	ldr	x9, [x9, _MVEBU_COMPHY_SERDES_CFG0_PU_RX@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
Lloh6:
	adrp	x10, _MVEBU_COMPHY_SERDES_CFG0_PU_TX@GOTPAGE
Lloh7:
	ldr	x10, [x10, _MVEBU_COMPHY_SERDES_CFG0_PU_TX@GOTPAGEOFF]
Lloh8:
	ldr	w10, [x10]
	orr	w8, w8, w0
	orr	w8, w8, w9
	orr	w20, w8, w10
	ldr	x22, [x21]
	ldr	w0, [x19]
	bl	_MVEBU_COMPHY_SERDES_CFG0
	add	x1, x0, x22
	mov	x0, x20
	bl	_writel
	ldr	x22, [x21]
	ldr	w0, [x19]
	bl	_MVEBU_COMPHY_SERDES_STATUS0
	add	x0, x0, x22
Lloh9:
	adrp	x22, _MVEBU_COMPHY_SERDES_STATUS0_RX_PLL_RDY@GOTPAGE
Lloh10:
	ldr	x22, [x22, _MVEBU_COMPHY_SERDES_STATUS0_RX_PLL_RDY@GOTPAGEOFF]
	ldr	w8, [x22]
Lloh11:
	adrp	x23, _MVEBU_COMPHY_SERDES_STATUS0_TX_PLL_RDY@GOTPAGE
Lloh12:
	ldr	x23, [x23, _MVEBU_COMPHY_SERDES_STATUS0_TX_PLL_RDY@GOTPAGEOFF]
	ldr	w9, [x23]
	orr	w8, w9, w8
	and	w2, w8, w20
	mov	x1, x20
	mov	w3, #1000
	mov	w4, #18928
	movk	w4, #2, lsl #16
	bl	_readl_poll_timeout
	ldr	w8, [x22]
	ldr	w9, [x23]
	orr	w8, w9, w8
	tst	w8, w20
	b.eq	LBB0_3
; %bb.1:
	ldr	x20, [x21]
	ldr	w0, [x19]
	bl	_MVEBU_COMPHY_SERDES_CFG1
	add	x0, x0, x20
	bl	_readl
Lloh13:
	adrp	x22, _MVEBU_COMPHY_SERDES_CFG1_RX_INIT@GOTPAGE
Lloh14:
	ldr	x22, [x22, _MVEBU_COMPHY_SERDES_CFG1_RX_INIT@GOTPAGEOFF]
	ldr	w8, [x22]
	orr	w20, w8, w0
	ldr	x23, [x21]
	ldr	w0, [x19]
	bl	_MVEBU_COMPHY_SERDES_CFG1
	add	x1, x0, x23
	mov	x0, x20
	bl	_writel
	ldr	x23, [x21]
	ldr	w0, [x19]
	bl	_MVEBU_COMPHY_SERDES_STATUS0
	add	x0, x0, x23
Lloh15:
	adrp	x23, _MVEBU_COMPHY_SERDES_STATUS0_RX_INIT@GOTPAGE
Lloh16:
	ldr	x23, [x23, _MVEBU_COMPHY_SERDES_STATUS0_RX_INIT@GOTPAGEOFF]
	ldr	w8, [x23]
	and	w2, w8, w20
	mov	x1, x20
	mov	w3, #1000
	mov	w4, #10000
	bl	_readl_poll_timeout
	ldr	w8, [x23]
	tst	w8, w20
	b.eq	LBB0_3
; %bb.2:
	ldr	x20, [x21]
	ldr	w0, [x19]
	bl	_MVEBU_COMPHY_SERDES_CFG1
	add	x0, x0, x20
	bl	_readl
	ldr	w8, [x22]
	bic	w20, w0, w8
	ldr	x21, [x21]
	ldr	w0, [x19]
	bl	_MVEBU_COMPHY_SERDES_CFG1
	add	x1, x0, x21
	mov	x0, x20
	bl	_writel
	mov	w0, #0
	b	LBB0_4
LBB0_3:
Lloh17:
	adrp	x8, _ETIMEDOUT@GOTPAGE
Lloh18:
	ldr	x8, [x8, _ETIMEDOUT@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_4:
	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 AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.comm	_MVEBU_COMPHY_SERDES_CFG0_PU_PLL,4,2 ; @MVEBU_COMPHY_SERDES_CFG0_PU_PLL
	.comm	_MVEBU_COMPHY_SERDES_CFG0_PU_RX,4,2 ; @MVEBU_COMPHY_SERDES_CFG0_PU_RX
	.comm	_MVEBU_COMPHY_SERDES_CFG0_PU_TX,4,2 ; @MVEBU_COMPHY_SERDES_CFG0_PU_TX
	.comm	_MVEBU_COMPHY_SERDES_STATUS0_RX_PLL_RDY,4,2 ; @MVEBU_COMPHY_SERDES_STATUS0_RX_PLL_RDY
	.comm	_MVEBU_COMPHY_SERDES_STATUS0_TX_PLL_RDY,4,2 ; @MVEBU_COMPHY_SERDES_STATUS0_TX_PLL_RDY
	.comm	_ETIMEDOUT,4,2                  ; @ETIMEDOUT
	.comm	_MVEBU_COMPHY_SERDES_CFG1_RX_INIT,4,2 ; @MVEBU_COMPHY_SERDES_CFG1_RX_INIT
	.comm	_MVEBU_COMPHY_SERDES_STATUS0_RX_INIT,4,2 ; @MVEBU_COMPHY_SERDES_STATUS0_RX_INIT
	.no_dead_strip	_mvebu_comphy_init_plls
.subsections_via_symbols
