	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cx24113_set_frequency
_cx24113_set_frequency:                 ## @cx24113_set_frequency
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movl	%esi, %r14d
	movq	%rdi, %rbx
	movl	$6, -24(%rbp)
	movl	$0, -20(%rbp)
	movl	$20, %esi
	callq	_cx24113_readreg
	andl	$63, %eax
	movq	%rbx, %rdi
	movl	$20, %esi
	movl	%eax, %edx
	callq	_cx24113_writereg
	movq	%rbx, %rdi
	movl	$16, %esi
	callq	_cx24113_readreg
	andl	$191, %eax
	movq	%rbx, %rdi
	movl	$16, %esi
	movl	%eax, %edx
	callq	_cx24113_writereg
	movl	%r14d, 12(%rbx)
	leaq	L_.str(%rip), %rdi
	movl	%r14d, %esi
	callq	_dprintk
	leaq	-24(%rbp), %rsi
	leaq	-20(%rbp), %rdx
	movq	%rbx, %rdi
	callq	_cx24113_calc_pll_nf
	movl	-24(%rbp), %esi
	movl	-20(%rbp), %edx
	movl	8(%rbx), %ecx
	movq	%rbx, %rdi
	callq	_cx24113_set_nfr
	movq	%rbx, %rdi
	movl	$24, %esi
	callq	_cx24113_readreg
                                        ## kill: def $eax killed $eax def $rax
	andl	$191, %eax
	movq	(%rbx), %rcx
	movq	_VCODIV2@GOTPCREL(%rip), %rsi
	leal	64(%rax), %edx
	cmpq	(%rsi), %rcx
	cmovel	%eax, %edx
	movq	%rbx, %rdi
	movl	$24, %esi
	callq	_cx24113_writereg
	movl	$5, %edi
	callq	_msleep
	movq	%rbx, %rdi
	movl	$28, %esi
	callq	_cx24113_readreg
	orl	$16, %eax
	movzbl	%al, %edx
	movq	%rbx, %rdi
	movl	$28, %esi
	callq	_cx24113_writereg
	xorl	%eax, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"tuning to frequency: %d\n"

	.comm	_VCODIV2,8,3                    ## @VCODIV2
	.no_dead_strip	_cx24113_set_frequency
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cx24113_set_frequency
_cx24113_set_frequency:                 ; @cx24113_set_frequency
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x20, x1
	mov	x19, x0
	mov	w8, #6
	stp	wzr, w8, [sp, #8]
	mov	w1, #20
	bl	_cx24113_readreg
	and	w2, w0, #0x3f
	mov	x0, x19
	mov	w1, #20
	bl	_cx24113_writereg
	mov	x0, x19
	mov	w1, #16
	bl	_cx24113_readreg
	mov	w21, #191
	and	w2, w0, w21
	mov	x0, x19
	mov	w1, #16
	bl	_cx24113_writereg
	str	w20, [x19, #12]
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x20
	bl	_dprintk
	add	x1, sp, #12
	add	x2, sp, #8
	mov	x0, x19
	bl	_cx24113_calc_pll_nf
	ldp	w2, w1, [sp, #8]
	ldr	w3, [x19, #8]
	mov	x0, x19
	bl	_cx24113_set_nfr
	mov	x0, x19
	mov	w1, #24
	bl	_cx24113_readreg
	and	w8, w0, w21
	ldr	x9, [x19]
Lloh2:
	adrp	x10, _VCODIV2@GOTPAGE
Lloh3:
	ldr	x10, [x10, _VCODIV2@GOTPAGEOFF]
Lloh4:
	ldr	x10, [x10]
	orr	w11, w8, #0x40
	cmp	x9, x10
	csel	w2, w8, w11, eq
	mov	x0, x19
	mov	w1, #24
	bl	_cx24113_writereg
	mov	w0, #5
	bl	_msleep
	mov	x0, x19
	mov	w1, #28
	bl	_cx24113_readreg
	and	w8, w0, #0xff
	orr	w2, w8, #0x10
	mov	x0, x19
	mov	w1, #28
	bl	_cx24113_writereg
	mov	w0, #0
	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
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"tuning to frequency: %d\n"

	.comm	_VCODIV2,8,3                    ; @VCODIV2
	.no_dead_strip	_cx24113_set_frequency
.subsections_via_symbols
