	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mt7531_phy_pll_setup
_mt7531_phy_pll_setup:                  ## @mt7531_phy_pll_setup
	.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, %r13
	movq	_HWSTRAP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_mt753x_reg_read
	movq	_XTAL_FSEL_M@GOTPCREL(%rip), %rcx
	andl	(%rcx), %eax
	movq	_XTAL_FSEL_S@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	sarl	%cl, %eax
	cmpl	$129, %eax
	je	LBB0_1
## %bb.2:
	cmpl	$128, %eax
	jne	LBB0_5
## %bb.3:
	movl	$55486, -48(%rbp)               ## 4-byte Folded Spill
                                        ## imm = 0xD8BE
	movl	$50806, -44(%rbp)               ## 4-byte Folded Spill
                                        ## imm = 0xC676
	movl	$4120, %r12d                    ## imm = 0x1018
	jmp	LBB0_4
LBB0_1:
	movl	$43198, -48(%rbp)               ## 4-byte Folded Spill
                                        ## imm = 0xA8BE
	movl	$1990, -44(%rbp)                ## 4-byte Folded Spill
                                        ## imm = 0x7C6
	movl	$4105, %r12d                    ## imm = 0x1009
LBB0_4:
	movq	_PHY_DEV1F@GOTPCREL(%rip), %r14
	movl	(%r14), %edx
	movq	_PHY_DEV1F_REG_104@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r13, %rdi
	xorl	%esi, %esi
	movl	$1544, %r8d                     ## imm = 0x608
	callq	*8(%r13)
	movl	(%r14), %edx
	movq	_PHY_DEV1F_REG_403@GOTPCREL(%rip), %r15
	movl	(%r15), %ecx
	movq	%r13, %rdi
	xorl	%esi, %esi
	callq	*(%r13)
	movq	_PHY_PLL_M@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ebx
	notl	%ebx
	andl	%eax, %ebx
	movl	$3, %edi
	callq	_PHY_PLL_SEL
	orl	%eax, %ebx
	movl	(%r14), %edx
	movl	(%r15), %ecx
	movq	%r13, %rdi
	xorl	%esi, %esi
	movl	%ebx, %r8d
	callq	*8(%r13)
	movl	(%r14), %edx
	movq	_PHY_DEV1F_REG_10A@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r13, %rdi
	xorl	%esi, %esi
	movl	%r12d, %r8d
	callq	*8(%r13)
	movl	(%r14), %edx
	movq	_PHY_DEV1F_REG_10B@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r13, %rdi
	xorl	%esi, %esi
	movl	-44(%rbp), %r8d                 ## 4-byte Reload
	callq	*8(%r13)
	movl	(%r14), %edx
	movq	_PHY_DEV1F_REG_10C@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r13, %rdi
	xorl	%esi, %esi
	movl	-48(%rbp), %r8d                 ## 4-byte Reload
	callq	*8(%r13)
LBB0_5:
	movq	_PHY_DEV1F@GOTPCREL(%rip), %r14
	movl	(%r14), %edx
	movq	_PHY_DEV1F_REG_10D@GOTPCREL(%rip), %rbx
	movl	(%rbx), %ecx
	movq	%r13, %rdi
	xorl	%esi, %esi
	movl	$16, %r8d
	callq	*8(%r13)
	movq	8(%r13), %rax
	movl	(%r14), %edx
	movl	(%rbx), %ecx
	movq	%r13, %rdi
	xorl	%esi, %esi
	movl	$20, %r8d
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmpq	*%rax                           ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_HWSTRAP,4,2                    ## @HWSTRAP
	.comm	_XTAL_FSEL_M,4,2                ## @XTAL_FSEL_M
	.comm	_XTAL_FSEL_S,4,2                ## @XTAL_FSEL_S
	.comm	_PHY_DEV1F,4,2                  ## @PHY_DEV1F
	.comm	_PHY_DEV1F_REG_104,4,2          ## @PHY_DEV1F_REG_104
	.comm	_PHY_DEV1F_REG_403,4,2          ## @PHY_DEV1F_REG_403
	.comm	_PHY_PLL_M,4,2                  ## @PHY_PLL_M
	.comm	_PHY_DEV1F_REG_10A,4,2          ## @PHY_DEV1F_REG_10A
	.comm	_PHY_DEV1F_REG_10B,4,2          ## @PHY_DEV1F_REG_10B
	.comm	_PHY_DEV1F_REG_10C,4,2          ## @PHY_DEV1F_REG_10C
	.comm	_PHY_DEV1F_REG_10D,4,2          ## @PHY_DEV1F_REG_10D
	.no_dead_strip	_mt7531_phy_pll_setup
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mt7531_phy_pll_setup
_mt7531_phy_pll_setup:                  ; @mt7531_phy_pll_setup
	.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	x19, x0
Lloh0:
	adrp	x8, _HWSTRAP@GOTPAGE
Lloh1:
	ldr	x8, [x8, _HWSTRAP@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_mt753x_reg_read
Lloh3:
	adrp	x8, _XTAL_FSEL_M@GOTPAGE
Lloh4:
	ldr	x8, [x8, _XTAL_FSEL_M@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
Lloh6:
	adrp	x9, _XTAL_FSEL_S@GOTPAGE
Lloh7:
	ldr	x9, [x9, _XTAL_FSEL_S@GOTPAGEOFF]
	and	w8, w8, w0
Lloh8:
	ldr	w9, [x9]
	asr	w8, w8, w9
Lloh9:
	adrp	x23, _PHY_DEV1F@GOTPAGE
Lloh10:
	ldr	x23, [x23, _PHY_DEV1F@GOTPAGEOFF]
	cmp	w8, #129
	b.eq	LBB0_3
; %bb.1:
	cmp	w8, #128
	b.ne	LBB0_5
; %bb.2:
	mov	w20, #55486
	mov	w21, #50806
	mov	w22, #4120
	b	LBB0_4
LBB0_3:
	mov	w20, #43198
	mov	w21, #1990
	mov	w22, #4105
LBB0_4:
	ldr	x8, [x19, #8]
	ldr	w2, [x23]
Lloh11:
	adrp	x9, _PHY_DEV1F_REG_104@GOTPAGE
Lloh12:
	ldr	x9, [x9, _PHY_DEV1F_REG_104@GOTPAGEOFF]
Lloh13:
	ldr	w3, [x9]
	mov	x0, x19
	mov	w1, #0
	mov	w4, #1544
	blr	x8
	ldr	x8, [x19]
	ldr	w2, [x23]
Lloh14:
	adrp	x24, _PHY_DEV1F_REG_403@GOTPAGE
Lloh15:
	ldr	x24, [x24, _PHY_DEV1F_REG_403@GOTPAGEOFF]
	ldr	w3, [x24]
	mov	x0, x19
	mov	w1, #0
	blr	x8
Lloh16:
	adrp	x8, _PHY_PLL_M@GOTPAGE
Lloh17:
	ldr	x8, [x8, _PHY_PLL_M@GOTPAGEOFF]
Lloh18:
	ldr	w8, [x8]
	bic	w25, w0, w8
	mov	w0, #3
	bl	_PHY_PLL_SEL
	orr	w4, w25, w0
	ldr	x8, [x19, #8]
	ldr	w2, [x23]
	ldr	w3, [x24]
	mov	x0, x19
	mov	w1, #0
	blr	x8
	ldr	x8, [x19, #8]
	ldr	w2, [x23]
Lloh19:
	adrp	x9, _PHY_DEV1F_REG_10A@GOTPAGE
Lloh20:
	ldr	x9, [x9, _PHY_DEV1F_REG_10A@GOTPAGEOFF]
Lloh21:
	ldr	w3, [x9]
	mov	x0, x19
	mov	w1, #0
	mov	x4, x22
	blr	x8
	ldr	x8, [x19, #8]
	ldr	w2, [x23]
Lloh22:
	adrp	x9, _PHY_DEV1F_REG_10B@GOTPAGE
Lloh23:
	ldr	x9, [x9, _PHY_DEV1F_REG_10B@GOTPAGEOFF]
Lloh24:
	ldr	w3, [x9]
	mov	x0, x19
	mov	w1, #0
	mov	x4, x21
	blr	x8
	ldr	x8, [x19, #8]
	ldr	w2, [x23]
Lloh25:
	adrp	x9, _PHY_DEV1F_REG_10C@GOTPAGE
Lloh26:
	ldr	x9, [x9, _PHY_DEV1F_REG_10C@GOTPAGEOFF]
Lloh27:
	ldr	w3, [x9]
	mov	x0, x19
	mov	w1, #0
	mov	x4, x20
	blr	x8
LBB0_5:
	ldr	x8, [x19, #8]
	ldr	w2, [x23]
Lloh28:
	adrp	x20, _PHY_DEV1F_REG_10D@GOTPAGE
Lloh29:
	ldr	x20, [x20, _PHY_DEV1F_REG_10D@GOTPAGEOFF]
	ldr	w3, [x20]
	mov	x0, x19
	mov	w1, #0
	mov	w4, #16
	blr	x8
	ldr	x5, [x19, #8]
	ldr	w2, [x23]
	ldr	w3, [x20]
	mov	x0, x19
	mov	w1, #0
	mov	w4, #20
	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
	br	x5
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh28, Lloh29
	.cfi_endproc
                                        ; -- End function
	.comm	_HWSTRAP,4,2                    ; @HWSTRAP
	.comm	_XTAL_FSEL_M,4,2                ; @XTAL_FSEL_M
	.comm	_XTAL_FSEL_S,4,2                ; @XTAL_FSEL_S
	.comm	_PHY_DEV1F,4,2                  ; @PHY_DEV1F
	.comm	_PHY_DEV1F_REG_104,4,2          ; @PHY_DEV1F_REG_104
	.comm	_PHY_DEV1F_REG_403,4,2          ; @PHY_DEV1F_REG_403
	.comm	_PHY_PLL_M,4,2                  ; @PHY_PLL_M
	.comm	_PHY_DEV1F_REG_10A,4,2          ; @PHY_DEV1F_REG_10A
	.comm	_PHY_DEV1F_REG_10B,4,2          ; @PHY_DEV1F_REG_10B
	.comm	_PHY_DEV1F_REG_10C,4,2          ; @PHY_DEV1F_REG_10C
	.comm	_PHY_DEV1F_REG_10D,4,2          ; @PHY_DEV1F_REG_10D
	.no_dead_strip	_mt7531_phy_pll_setup
.subsections_via_symbols
