	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_radeon_combios_get_tv_dac_info ## -- Begin function radeon_combios_get_tv_dac_info
	.p2align	4, 0x90
_radeon_combios_get_tv_dac_info:        ## @radeon_combios_get_tv_dac_info
	.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), %r15
	movq	(%r15), %r14
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$16, %edi
	callq	_kzalloc
	movq	%rax, %r12
	testq	%rax, %rax
	je	LBB0_15
## %bb.1:
	movq	_COMBIOS_TV_INFO_TABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_combios_get_table_offset
	testq	%rax, %rax
	je	LBB0_8
## %bb.2:
	movq	%rax, %r13
	leaq	3(%rax), %rdi
	callq	_RBIOS8
	cmpl	$5, %eax
	jl	LBB0_4
## %bb.3:
	leaq	12(%r13), %rdi
	callq	_RBIOS8
	movl	%eax, %ebx
	leaq	13(%r13), %rdi
	callq	_RBIOS8
	andl	$15, %ebx
	shll	$16, %ebx
	andl	$15, %eax
	shll	$20, %eax
	orl	%ebx, %eax
	movl	%eax, (%r12)
	leaq	14(%r13), %rdi
	callq	_RBIOS8
	movl	%eax, %ebx
	leaq	15(%r13), %rdi
	callq	_RBIOS8
	andl	$15, %ebx
	shll	$16, %ebx
	andl	$15, %eax
	shll	$20, %eax
	orl	%ebx, %eax
	movl	%eax, 4(%r12)
	leaq	16(%r13), %rdi
	callq	_RBIOS8
	movl	%eax, %ebx
	addq	$17, %r13
	movq	%r13, %rdi
	callq	_RBIOS8
	andl	$15, %ebx
	shll	$16, %ebx
	andl	$15, %eax
	shll	$20, %eax
	jmp	LBB0_6
LBB0_4:
	cmpl	$2, %eax
	jl	LBB0_7
## %bb.5:
	leaq	12(%r13), %rbx
	movq	%rbx, %rdi
	callq	_RBIOS8
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	movl	%eax, %r14d
	movq	%rbx, %rdi
	callq	_RBIOS8
	andl	$15, %r14d
	shll	$16, %r14d
	shll	$16, %eax
	andl	$15728640, %eax                 ## imm = 0xF00000
	orl	%r14d, %eax
	movl	%eax, (%r12)
	leaq	13(%r13), %r14
	movq	%r14, %rdi
	callq	_RBIOS8
	movl	%eax, %ebx
	movq	%r14, %rdi
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	callq	_RBIOS8
	andl	$15, %ebx
	shll	$16, %ebx
	shll	$16, %eax
	andl	$15728640, %eax                 ## imm = 0xF00000
	orl	%ebx, %eax
	movl	%eax, 4(%r12)
	addq	$14, %r13
	movq	%r13, %rdi
	callq	_RBIOS8
	movl	%eax, %ebx
	movq	%r13, %rdi
	callq	_RBIOS8
	andl	$15, %ebx
	shll	$16, %ebx
	shll	$16, %eax
	andl	$15728640, %eax                 ## imm = 0xF00000
LBB0_6:
	orl	%ebx, %eax
	movl	%eax, 8(%r12)
	cmpl	$0, (%r12)
	je	LBB0_7
## %bb.16:
	movq	%r14, %rdi
	callq	_radeon_combios_get_tv_info
	movl	%eax, 12(%r12)
	jmp	LBB0_15
LBB0_7:
	movq	%r14, %rdi
	callq	_radeon_combios_get_tv_info
	movl	%eax, 12(%r12)
LBB0_8:
	movq	_COMBIOS_CRT_INFO_TABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_combios_get_table_offset
	testq	%rax, %rax
	je	LBB0_11
## %bb.9:
	movq	%rax, %rbx
	movq	%r14, %r15
	movq	%rax, %rdi
	callq	_RBIOS8
	testb	$2, %al
	jne	LBB0_12
## %bb.10:
	addq	$3, %rbx
	movq	%rbx, %rdi
	callq	_RBIOS8
	movl	%eax, %r14d
	movq	%rbx, %rdi
	callq	_RBIOS8
	andl	$15, %r14d
	shll	$16, %r14d
	shll	$16, %eax
	andl	$15728640, %eax                 ## imm = 0xF00000
	jmp	LBB0_13
LBB0_11:
	leaq	L_.str(%rip), %rdi
	callq	_DRM_INFO
	jmp	LBB0_14
LBB0_12:
	leaq	4(%rbx), %rdi
	callq	_RBIOS8
	movl	%eax, %r14d
	addq	$5, %rbx
	movq	%rbx, %rdi
	callq	_RBIOS8
	andl	$15, %r14d
	shll	$16, %r14d
	andl	$15, %eax
	shll	$20, %eax
LBB0_13:
	orl	%r14d, %eax
	movl	%eax, (%r12)
	movl	%eax, 4(%r12)
	movl	%eax, 8(%r12)
	movq	%r15, %r14
	jne	LBB0_15
LBB0_14:
	movq	%r14, %rdi
	movq	%r12, %rsi
	callq	_radeon_legacy_get_tv_dac_info_from_table
LBB0_15:
	movq	%r12, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_COMBIOS_TV_INFO_TABLE,4,2      ## @COMBIOS_TV_INFO_TABLE
	.comm	_COMBIOS_CRT_INFO_TABLE,4,2     ## @COMBIOS_CRT_INFO_TABLE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"No TV DAC info found in BIOS\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_radeon_combios_get_tv_dac_info ; -- Begin function radeon_combios_get_tv_dac_info
	.p2align	2
_radeon_combios_get_tv_dac_info:        ; @radeon_combios_get_tv_dac_info
	.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
	ldr	x21, [x0]
	ldr	x20, [x21]
Lloh0:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	w0, #16
	bl	_kzalloc
	mov	x19, x0
	cbz	x0, LBB0_16
; %bb.1:
Lloh3:
	adrp	x8, _COMBIOS_TV_INFO_TABLE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _COMBIOS_TV_INFO_TABLE@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	x0, x21
	bl	_combios_get_table_offset
	cbz	x0, LBB0_9
; %bb.2:
	mov	x22, x0
	add	x0, x0, #3
	bl	_RBIOS8
	cmp	w0, #5
	b.lt	LBB0_4
; %bb.3:
	add	x0, x22, #12
	bl	_RBIOS8
	mov	x23, x0
	add	x0, x22, #13
	bl	_RBIOS8
	ubfiz	w8, w23, #16, #4
	bfi	w8, w0, #20, #4
	str	w8, [x19]
	add	x0, x22, #14
	bl	_RBIOS8
	mov	x23, x0
	add	x0, x22, #15
	bl	_RBIOS8
	ubfiz	w8, w23, #16, #4
	bfi	w8, w0, #20, #4
	str	w8, [x19, #4]
	add	x0, x22, #16
	bl	_RBIOS8
	mov	x23, x0
	add	x0, x22, #17
	bl	_RBIOS8
	ubfiz	w8, w23, #16, #4
	bfi	w8, w0, #20, #4
	b	LBB0_6
LBB0_4:
	cmp	w0, #2
	b.lt	LBB0_8
; %bb.5:
	add	x23, x22, #12
	mov	x0, x23
	bl	_RBIOS8
	mov	x24, x0
	mov	x0, x23
	bl	_RBIOS8
	lsl	w8, w0, #16
	and	w8, w8, #0xf00000
	bfi	w8, w24, #16, #4
	str	w8, [x19]
	add	x23, x22, #13
	mov	x0, x23
	bl	_RBIOS8
	mov	x24, x0
	mov	x0, x23
	bl	_RBIOS8
	lsl	w8, w0, #16
	and	w8, w8, #0xf00000
	bfi	w8, w24, #16, #4
	str	w8, [x19, #4]
	add	x22, x22, #14
	mov	x0, x22
	bl	_RBIOS8
	mov	x23, x0
	mov	x0, x22
	bl	_RBIOS8
	lsl	w8, w0, #16
	and	w8, w8, #0xf00000
	bfi	w8, w23, #16, #4
LBB0_6:
	str	w8, [x19, #8]
	ldr	w8, [x19]
	cbz	w8, LBB0_8
; %bb.7:
	mov	x0, x20
	bl	_radeon_combios_get_tv_info
	str	w0, [x19, #12]
	b	LBB0_16
LBB0_8:
	mov	x0, x20
	bl	_radeon_combios_get_tv_info
	str	w0, [x19, #12]
LBB0_9:
Lloh6:
	adrp	x8, _COMBIOS_CRT_INFO_TABLE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _COMBIOS_CRT_INFO_TABLE@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	x0, x21
	bl	_combios_get_table_offset
	cbz	x0, LBB0_12
; %bb.10:
	mov	x21, x0
	bl	_RBIOS8
	tbnz	w0, #1, LBB0_13
; %bb.11:
	add	x21, x21, #3
	mov	x0, x21
	bl	_RBIOS8
	mov	x22, x0
	mov	x0, x21
	bl	_RBIOS8
	lsl	w8, w0, #16
	and	w8, w8, #0xf00000
	bfi	w8, w22, #16, #4
	b	LBB0_14
LBB0_12:
Lloh9:
	adrp	x0, l_.str@PAGE
Lloh10:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_INFO
	b	LBB0_15
LBB0_13:
	add	x0, x21, #4
	bl	_RBIOS8
	mov	x22, x0
	add	x0, x21, #5
	bl	_RBIOS8
	ubfiz	w8, w22, #16, #4
	bfi	w8, w0, #20, #4
LBB0_14:
	stp	w8, w8, [x19]
	str	w8, [x19, #8]
	cbnz	w8, LBB0_16
LBB0_15:
	mov	x0, x20
	mov	x1, x19
	bl	_radeon_legacy_get_tv_dac_info_from_table
LBB0_16:
	mov	x0, x19
	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 AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_COMBIOS_TV_INFO_TABLE,4,2      ; @COMBIOS_TV_INFO_TABLE
	.comm	_COMBIOS_CRT_INFO_TABLE,4,2     ; @COMBIOS_CRT_INFO_TABLE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"No TV DAC info found in BIOS\n"

.subsections_via_symbols
