	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_evergreen_hdmi_enable          ## -- Begin function evergreen_hdmi_enable
	.p2align	4, 0x90
_evergreen_hdmi_enable:                 ## @evergreen_hdmi_enable
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r14d
	movq	%rdi, %rbx
	callq	_to_radeon_encoder
	movq	8(%rax), %r12
	testq	%r12, %r12
	je	LBB0_6
## %bb.1:
	movq	%rax, %r15
	movq	(%r12), %rax
	testq	%rax, %rax
	je	LBB0_6
## %bb.2:
	testl	%r14d, %r14d
	je	LBB0_7
## %bb.3:
	movq	%rbx, %rdi
	callq	_radeon_get_connector_for_encoder
	testq	%rax, %rax
	je	LBB0_8
## %bb.4:
	movq	%rax, %rdi
	callq	_radeon_connector_edid
	movl	%eax, %edi
	callq	_drm_detect_monitor_audio
	testq	%rax, %rax
	je	LBB0_8
## %bb.5:
	movq	_HDMI_INFOFRAME_CONTROL0@GOTPCREL(%rip), %rax
	movq	(%r12), %rcx
	movq	8(%rcx), %rdi
	addq	(%rax), %rdi
	movq	_HDMI_AVI_INFO_SEND@GOTPCREL(%rip), %rax
	movq	_HDMI_AVI_INFO_CONT@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	orl	(%rax), %esi
	movq	_HDMI_AUDIO_INFO_SEND@GOTPCREL(%rip), %rax
	orl	(%rax), %esi
	movq	_HDMI_AUDIO_INFO_CONT@GOTPCREL(%rip), %rax
	orl	(%rax), %esi
	callq	_WREG32
	movq	_AFMT_AUDIO_PACKET_CONTROL@GOTPCREL(%rip), %rax
	movq	(%r12), %rcx
	movq	8(%rcx), %rdi
	addq	(%rax), %rdi
	movq	_AFMT_AUDIO_SAMPLE_SEND@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_WREG32_OR
	jmp	LBB0_9
LBB0_6:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	movq	_AFMT_AUDIO_PACKET_CONTROL@GOTPCREL(%rip), %rcx
	movq	8(%rax), %rdi
	addq	(%rcx), %rdi
	movq	_AFMT_AUDIO_SAMPLE_SEND@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	notl	%esi
	callq	_WREG32_AND
	movq	_HDMI_INFOFRAME_CONTROL0@GOTPCREL(%rip), %rax
	movq	(%r12), %rcx
	movq	8(%rcx), %rdi
	addq	(%rax), %rdi
	xorl	%esi, %esi
	callq	_WREG32
	leaq	L_.str.2(%rip), %rsi
	jmp	LBB0_10
LBB0_8:
	movq	_HDMI_INFOFRAME_CONTROL0@GOTPCREL(%rip), %rax
	movq	(%r12), %rcx
	movq	8(%rcx), %rdi
	addq	(%rax), %rdi
	movq	_HDMI_AVI_INFO_SEND@GOTPCREL(%rip), %rax
	movq	_HDMI_AVI_INFO_CONT@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	orl	(%rax), %esi
	callq	_WREG32
	movq	_AFMT_AUDIO_PACKET_CONTROL@GOTPCREL(%rip), %rax
	movq	(%r12), %rcx
	movq	8(%rcx), %rdi
	addq	(%rax), %rdi
	movq	_AFMT_AUDIO_SAMPLE_SEND@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	notl	%esi
	callq	_WREG32_AND
LBB0_9:
	leaq	L_.str.1(%rip), %rsi
LBB0_10:
	movq	(%r12), %rax
	movl	%r14d, (%rax)
	movq	8(%rax), %rdx
	movl	(%r15), %ecx
	leaq	L_.str(%rip), %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_DRM_DEBUG                      ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_HDMI_INFOFRAME_CONTROL0,8,3    ## @HDMI_INFOFRAME_CONTROL0
	.comm	_HDMI_AVI_INFO_SEND,4,2         ## @HDMI_AVI_INFO_SEND
	.comm	_HDMI_AVI_INFO_CONT,4,2         ## @HDMI_AVI_INFO_CONT
	.comm	_HDMI_AUDIO_INFO_SEND,4,2       ## @HDMI_AUDIO_INFO_SEND
	.comm	_HDMI_AUDIO_INFO_CONT,4,2       ## @HDMI_AUDIO_INFO_CONT
	.comm	_AFMT_AUDIO_PACKET_CONTROL,8,3  ## @AFMT_AUDIO_PACKET_CONTROL
	.comm	_AFMT_AUDIO_SAMPLE_SEND,4,2     ## @AFMT_AUDIO_SAMPLE_SEND
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%sabling HDMI interface @ 0x%04X for encoder 0x%x\n"

L_.str.1:                               ## @.str.1
	.asciz	"En"

L_.str.2:                               ## @.str.2
	.asciz	"Dis"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_evergreen_hdmi_enable          ; -- Begin function evergreen_hdmi_enable
	.p2align	2
_evergreen_hdmi_enable:                 ; @evergreen_hdmi_enable
	.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, x1
	mov	x21, x0
	bl	_to_radeon_encoder
	ldr	x22, [x0, #8]
	cbz	x22, LBB0_6
; %bb.1:
	ldr	x8, [x22]
	cbz	x8, LBB0_6
; %bb.2:
	mov	x20, x0
	cbz	w19, LBB0_7
; %bb.3:
	mov	x0, x21
	bl	_radeon_get_connector_for_encoder
	cbz	x0, LBB0_8
; %bb.4:
	bl	_radeon_connector_edid
	bl	_drm_detect_monitor_audio
	cbz	x0, LBB0_8
; %bb.5:
Lloh0:
	adrp	x8, _HDMI_INFOFRAME_CONTROL0@GOTPAGE
Lloh1:
	ldr	x8, [x8, _HDMI_INFOFRAME_CONTROL0@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	ldr	x9, [x22]
	ldr	x9, [x9, #8]
	add	x0, x9, x8
Lloh3:
	adrp	x8, _HDMI_AVI_INFO_SEND@GOTPAGE
Lloh4:
	ldr	x8, [x8, _HDMI_AVI_INFO_SEND@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
Lloh6:
	adrp	x9, _HDMI_AVI_INFO_CONT@GOTPAGE
Lloh7:
	ldr	x9, [x9, _HDMI_AVI_INFO_CONT@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	orr	w8, w9, w8
Lloh9:
	adrp	x9, _HDMI_AUDIO_INFO_SEND@GOTPAGE
Lloh10:
	ldr	x9, [x9, _HDMI_AUDIO_INFO_SEND@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	orr	w8, w8, w9
Lloh12:
	adrp	x9, _HDMI_AUDIO_INFO_CONT@GOTPAGE
Lloh13:
	ldr	x9, [x9, _HDMI_AUDIO_INFO_CONT@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
	orr	w1, w8, w9
	bl	_WREG32
Lloh15:
	adrp	x8, _AFMT_AUDIO_PACKET_CONTROL@GOTPAGE
Lloh16:
	ldr	x8, [x8, _AFMT_AUDIO_PACKET_CONTROL@GOTPAGEOFF]
Lloh17:
	ldr	x8, [x8]
	ldr	x9, [x22]
	ldr	x9, [x9, #8]
	add	x0, x9, x8
Lloh18:
	adrp	x8, _AFMT_AUDIO_SAMPLE_SEND@GOTPAGE
Lloh19:
	ldr	x8, [x8, _AFMT_AUDIO_SAMPLE_SEND@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
	bl	_WREG32_OR
	b	LBB0_9
LBB0_6:
	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
LBB0_7:
Lloh21:
	adrp	x9, _AFMT_AUDIO_PACKET_CONTROL@GOTPAGE
Lloh22:
	ldr	x9, [x9, _AFMT_AUDIO_PACKET_CONTROL@GOTPAGEOFF]
Lloh23:
	ldr	x9, [x9]
	ldr	x8, [x8, #8]
	add	x0, x8, x9
Lloh24:
	adrp	x8, _AFMT_AUDIO_SAMPLE_SEND@GOTPAGE
Lloh25:
	ldr	x8, [x8, _AFMT_AUDIO_SAMPLE_SEND@GOTPAGEOFF]
Lloh26:
	ldr	w8, [x8]
	mvn	w1, w8
	bl	_WREG32_AND
Lloh27:
	adrp	x8, _HDMI_INFOFRAME_CONTROL0@GOTPAGE
Lloh28:
	ldr	x8, [x8, _HDMI_INFOFRAME_CONTROL0@GOTPAGEOFF]
Lloh29:
	ldr	x8, [x8]
	ldr	x9, [x22]
	ldr	x9, [x9, #8]
	add	x0, x9, x8
	mov	w1, #0
	bl	_WREG32
Lloh30:
	adrp	x1, l_.str.2@PAGE
Lloh31:
	add	x1, x1, l_.str.2@PAGEOFF
	b	LBB0_10
LBB0_8:
Lloh32:
	adrp	x8, _HDMI_INFOFRAME_CONTROL0@GOTPAGE
Lloh33:
	ldr	x8, [x8, _HDMI_INFOFRAME_CONTROL0@GOTPAGEOFF]
Lloh34:
	ldr	x8, [x8]
	ldr	x9, [x22]
	ldr	x9, [x9, #8]
Lloh35:
	adrp	x10, _HDMI_AVI_INFO_SEND@GOTPAGE
Lloh36:
	ldr	x10, [x10, _HDMI_AVI_INFO_SEND@GOTPAGEOFF]
	add	x0, x9, x8
Lloh37:
	ldr	w8, [x10]
Lloh38:
	adrp	x9, _HDMI_AVI_INFO_CONT@GOTPAGE
Lloh39:
	ldr	x9, [x9, _HDMI_AVI_INFO_CONT@GOTPAGEOFF]
Lloh40:
	ldr	w9, [x9]
	orr	w1, w9, w8
	bl	_WREG32
Lloh41:
	adrp	x8, _AFMT_AUDIO_PACKET_CONTROL@GOTPAGE
Lloh42:
	ldr	x8, [x8, _AFMT_AUDIO_PACKET_CONTROL@GOTPAGEOFF]
Lloh43:
	ldr	x8, [x8]
	ldr	x9, [x22]
	ldr	x9, [x9, #8]
	add	x0, x9, x8
Lloh44:
	adrp	x8, _AFMT_AUDIO_SAMPLE_SEND@GOTPAGE
Lloh45:
	ldr	x8, [x8, _AFMT_AUDIO_SAMPLE_SEND@GOTPAGEOFF]
Lloh46:
	ldr	w8, [x8]
	mvn	w1, w8
	bl	_WREG32_AND
LBB0_9:
Lloh47:
	adrp	x1, l_.str.1@PAGE
Lloh48:
	add	x1, x1, l_.str.1@PAGEOFF
LBB0_10:
	ldr	x8, [x22]
	str	w19, [x8]
	ldr	x2, [x8, #8]
	ldr	w3, [x20]
Lloh49:
	adrp	x0, l_.str@PAGE
Lloh50:
	add	x0, x0, l_.str@PAGEOFF
	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
	b	_DRM_DEBUG
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh44, Lloh45, Lloh46
	.loh AdrpLdrGotLdr	Lloh41, Lloh42, Lloh43
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpAdd	Lloh47, Lloh48
	.loh AdrpAdd	Lloh49, Lloh50
	.cfi_endproc
                                        ; -- End function
	.comm	_HDMI_INFOFRAME_CONTROL0,8,3    ; @HDMI_INFOFRAME_CONTROL0
	.comm	_HDMI_AVI_INFO_SEND,4,2         ; @HDMI_AVI_INFO_SEND
	.comm	_HDMI_AVI_INFO_CONT,4,2         ; @HDMI_AVI_INFO_CONT
	.comm	_HDMI_AUDIO_INFO_SEND,4,2       ; @HDMI_AUDIO_INFO_SEND
	.comm	_HDMI_AUDIO_INFO_CONT,4,2       ; @HDMI_AUDIO_INFO_CONT
	.comm	_AFMT_AUDIO_PACKET_CONTROL,8,3  ; @AFMT_AUDIO_PACKET_CONTROL
	.comm	_AFMT_AUDIO_SAMPLE_SEND,4,2     ; @AFMT_AUDIO_SAMPLE_SEND
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%sabling HDMI interface @ 0x%04X for encoder 0x%x\n"

l_.str.1:                               ; @.str.1
	.asciz	"En"

l_.str.2:                               ; @.str.2
	.asciz	"Dis"

.subsections_via_symbols
