	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function stm32_usbphyc_pll_init
_stm32_usbphyc_pll_init:                ## @stm32_usbphyc_pll_init
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movl	16(%rdi), %edi
	callq	_clk_get_rate
	movq	%rax, %r15
	movq	_PLL_INFF_MIN_RATE_HZ@GOTPCREL(%rip), %rax
	cmpq	(%rax), %r15
	jl	LBB0_2
## %bb.1:
	movq	_PLL_INFF_MAX_RATE_HZ@GOTPCREL(%rip), %rax
	cmpq	(%rax), %r15
	jg	LBB0_2
## %bb.3:
	leaq	-56(%rbp), %rsi
	movq	%r15, %rdi
	callq	_stm32_usbphyc_get_pll_params
	movq	_PLLNDIV@GOTPCREL(%rip), %r12
	movl	(%r12), %edi
	movq	-48(%rbp), %rsi
	callq	_FIELD_PREP
	movq	%rax, %rbx
	movq	_PLLFRACIN@GOTPCREL(%rip), %r13
	movl	(%r13), %edi
	movq	-56(%rbp), %rsi
	callq	_FIELD_PREP
	movq	_PLLDITHEN1@GOTPCREL(%rip), %rcx
	movq	_PLLDITHEN0@GOTPCREL(%rip), %rdx
	movq	_PLLFRACCTL@GOTPCREL(%rip), %rsi
	orq	(%rsi), %rax
	movq	-56(%rbp), %rsi
	testq	%rsi, %rsi
	cmovneq	%rax, %rsi
	orq	(%rcx), %rbx
	orq	(%rdx), %rbx
	movq	_PLLSTRBYP@GOTPCREL(%rip), %rax
	orq	(%rax), %rbx
	orq	%rsi, %rbx
	movq	_STM32_USBPHYC_PLL@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	8(%r14), %rsi
	movq	%rbx, %rdi
	callq	_writel_relaxed
	movl	(%r14), %r14d
	movl	(%r12), %edi
	movq	%rbx, %rsi
	callq	_FIELD_GET
	movl	%eax, %r12d
	movl	(%r13), %edi
	movq	%rbx, %rsi
	callq	_FIELD_GET
	leaq	L_.str.1(%rip), %rsi
	movl	%r14d, %edi
	movq	%r15, %rdx
	movl	%r12d, %ecx
	movl	%eax, %r8d
	callq	_dev_dbg
	xorl	%eax, %eax
	jmp	LBB0_4
LBB0_2:
	movl	(%r14), %edi
	leaq	L_.str(%rip), %rsi
	movq	%r15, %rdx
	callq	_dev_err
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_4:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PLL_INFF_MIN_RATE_HZ,8,3       ## @PLL_INFF_MIN_RATE_HZ
	.comm	_PLL_INFF_MAX_RATE_HZ,8,3       ## @PLL_INFF_MAX_RATE_HZ
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"input clk freq (%dHz) out of range\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_PLLNDIV,4,2                    ## @PLLNDIV
	.comm	_PLLFRACIN,4,2                  ## @PLLFRACIN
	.comm	_PLLDITHEN1,8,3                 ## @PLLDITHEN1
	.comm	_PLLDITHEN0,8,3                 ## @PLLDITHEN0
	.comm	_PLLSTRBYP,8,3                  ## @PLLSTRBYP
	.comm	_PLLFRACCTL,8,3                 ## @PLLFRACCTL
	.comm	_STM32_USBPHYC_PLL,8,3          ## @STM32_USBPHYC_PLL
L_.str.1:                               ## @.str.1
	.asciz	"input clk freq=%dHz, ndiv=%lu, frac=%lu\n"

	.no_dead_strip	_stm32_usbphyc_pll_init
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function stm32_usbphyc_pll_init
_stm32_usbphyc_pll_init:                ; @stm32_usbphyc_pll_init
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.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
	mov	x20, x0
	ldr	w0, [x0, #16]
	bl	_clk_get_rate
	mov	x19, x0
Lloh0:
	adrp	x8, _PLL_INFF_MIN_RATE_HZ@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PLL_INFF_MIN_RATE_HZ@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
Lloh3:
	adrp	x9, _PLL_INFF_MAX_RATE_HZ@GOTPAGE
Lloh4:
	ldr	x9, [x9, _PLL_INFF_MAX_RATE_HZ@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x0, x8
	ccmp	x0, x9, #0, ge
	b.le	LBB0_2
; %bb.1:
	ldr	w0, [x20]
Lloh6:
	adrp	x1, l_.str@PAGE
Lloh7:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x19
	bl	_dev_err
Lloh8:
	adrp	x8, _EINVAL@GOTPAGE
Lloh9:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_3
LBB0_2:
	mov	x1, sp
	mov	x0, x19
	bl	_stm32_usbphyc_get_pll_params
Lloh11:
	adrp	x22, _PLLNDIV@GOTPAGE
Lloh12:
	ldr	x22, [x22, _PLLNDIV@GOTPAGEOFF]
	ldr	w0, [x22]
	ldr	x1, [sp, #8]
	bl	_FIELD_PREP
	mov	x21, x0
Lloh13:
	adrp	x23, _PLLFRACIN@GOTPAGE
Lloh14:
	ldr	x23, [x23, _PLLFRACIN@GOTPAGEOFF]
	ldr	w0, [x23]
	ldr	x1, [sp]
	bl	_FIELD_PREP
Lloh15:
	adrp	x8, _PLLDITHEN1@GOTPAGE
Lloh16:
	ldr	x8, [x8, _PLLDITHEN1@GOTPAGEOFF]
Lloh17:
	ldr	x8, [x8]
Lloh18:
	adrp	x9, _PLLDITHEN0@GOTPAGE
Lloh19:
	ldr	x9, [x9, _PLLDITHEN0@GOTPAGEOFF]
Lloh20:
	adrp	x10, _PLLSTRBYP@GOTPAGE
Lloh21:
	ldr	x10, [x10, _PLLSTRBYP@GOTPAGEOFF]
Lloh22:
	ldr	x9, [x9]
Lloh23:
	ldr	x10, [x10]
	ldr	x11, [sp]
Lloh24:
	adrp	x12, _PLLFRACCTL@GOTPAGE
Lloh25:
	ldr	x12, [x12, _PLLFRACCTL@GOTPAGEOFF]
Lloh26:
	ldr	x12, [x12]
	orr	x12, x12, x0
	cmp	x11, #0
	csel	x11, xzr, x12, eq
	orr	x8, x8, x21
	orr	x8, x8, x9
	orr	x8, x8, x10
	orr	x21, x8, x11
	ldr	x8, [x20, #8]
Lloh27:
	adrp	x9, _STM32_USBPHYC_PLL@GOTPAGE
Lloh28:
	ldr	x9, [x9, _STM32_USBPHYC_PLL@GOTPAGEOFF]
Lloh29:
	ldr	x9, [x9]
	add	x1, x9, x8
	mov	x0, x21
	bl	_writel_relaxed
	ldr	w20, [x20]
	ldr	w0, [x22]
	mov	x1, x21
	bl	_FIELD_GET
	mov	x22, x0
	ldr	w0, [x23]
	mov	x1, x21
	bl	_FIELD_GET
	mov	x4, x0
Lloh30:
	adrp	x1, l_.str.1@PAGE
Lloh31:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x20
	mov	x2, x19
	mov	x3, x22
	bl	_dev_dbg
	mov	w0, #0
LBB0_3:
	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
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh22
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_PLL_INFF_MIN_RATE_HZ,8,3       ; @PLL_INFF_MIN_RATE_HZ
	.comm	_PLL_INFF_MAX_RATE_HZ,8,3       ; @PLL_INFF_MAX_RATE_HZ
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"input clk freq (%dHz) out of range\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_PLLNDIV,4,2                    ; @PLLNDIV
	.comm	_PLLFRACIN,4,2                  ; @PLLFRACIN
	.comm	_PLLDITHEN1,8,3                 ; @PLLDITHEN1
	.comm	_PLLDITHEN0,8,3                 ; @PLLDITHEN0
	.comm	_PLLSTRBYP,8,3                  ; @PLLSTRBYP
	.comm	_PLLFRACCTL,8,3                 ; @PLLFRACCTL
	.comm	_STM32_USBPHYC_PLL,8,3          ; @STM32_USBPHYC_PLL
l_.str.1:                               ; @.str.1
	.asciz	"input clk freq=%dHz, ndiv=%lu, frac=%lu\n"

	.no_dead_strip	_stm32_usbphyc_pll_init
.subsections_via_symbols
