	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cnl_modeset_calc_cdclk
_cnl_modeset_calc_cdclk:                ## @cnl_modeset_calc_cdclk
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movl	32(%rdi), %edi
	callq	_to_i915
	movq	%rax, %r14
	movq	%rbx, %rdi
	callq	_intel_compute_min_cdclk
	testl	%eax, %eax
	js	LBB0_5
## %bb.1:
	movl	%eax, %edi
	callq	_cnl_calc_cdclk
	movl	%eax, %r15d
	movq	%r14, %rdi
	movl	%eax, %esi
	callq	_cnl_cdclk_pll_vco
	movl	%eax, 4(%rbx)
	movl	%r15d, 8(%rbx)
	movl	%r15d, %edi
	callq	_cnl_calc_voltage_level
	movl	%eax, %r15d
	movq	%rbx, %rdi
	callq	_cnl_compute_min_voltage_level
	movl	%r15d, %edi
	movl	%eax, %esi
	callq	_max
	movl	%eax, 12(%rbx)
	cmpl	$0, 28(%rbx)
	je	LBB0_2
## %bb.3:
	leaq	4(%rbx), %rax
	movl	8(%rax), %ecx
	movl	%ecx, 24(%rbx)
	movq	(%rax), %rax
	movq	%rax, 16(%rbx)
	jmp	LBB0_4
LBB0_2:
	movl	(%rbx), %edi
	callq	_cnl_calc_cdclk
	movl	%eax, %r15d
	movq	%r14, %rdi
	movl	%eax, %esi
	callq	_cnl_cdclk_pll_vco
	movl	%eax, 16(%rbx)
	movl	%r15d, 20(%rbx)
	movl	%r15d, %edi
	callq	_cnl_calc_voltage_level
	movl	%eax, 24(%rbx)
LBB0_4:
	xorl	%eax, %eax
LBB0_5:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_cnl_modeset_calc_cdclk
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cnl_modeset_calc_cdclk
_cnl_modeset_calc_cdclk:                ; @cnl_modeset_calc_cdclk
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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	x19, x0
	ldr	w0, [x0, #32]
	bl	_to_i915
	mov	x20, x0
	mov	x0, x19
	bl	_intel_compute_min_cdclk
	tbnz	w0, #31, LBB0_5
; %bb.1:
	bl	_cnl_calc_cdclk
	mov	x21, x0
	mov	x0, x20
	mov	x1, x21
	bl	_cnl_cdclk_pll_vco
	mov	x22, x19
	str	w0, [x22, #4]!
	str	w21, [x19, #8]
	mov	x0, x21
	bl	_cnl_calc_voltage_level
	mov	x21, x0
	mov	x0, x19
	bl	_cnl_compute_min_voltage_level
	mov	x1, x0
	mov	x0, x21
	bl	_max
	str	w0, [x19, #12]
	ldr	w8, [x19, #28]
	cbz	w8, LBB0_3
; %bb.2:
	mov	w0, #0
	ldr	x8, [x22]
	str	x8, [x19, #16]
	ldr	w8, [x22, #8]
	b	LBB0_4
LBB0_3:
	ldr	w0, [x19]
	bl	_cnl_calc_cdclk
	mov	x21, x0
	mov	x0, x20
	mov	x1, x21
	bl	_cnl_cdclk_pll_vco
	stp	w0, w21, [x19, #16]
	mov	x0, x21
	bl	_cnl_calc_voltage_level
	mov	x8, x0
	mov	w0, #0
LBB0_4:
	str	w8, [x19, #24]
LBB0_5:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_cnl_modeset_calc_cdclk
.subsections_via_symbols
