	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_drm_add_display_info           ## -- Begin function drm_add_display_info
	.p2align	4, 0x90
_drm_add_display_info:                  ## @drm_add_display_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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	movq	%rdi, %r15
	movq	%rsi, %rdi
	callq	_edid_get_quirks
	movl	%eax, %r14d
	movq	%r15, %rdi
	callq	_drm_reset_display_info
	movl	(%rbx), %eax
	addl	%eax, %eax
	leal	(%rax,%rax,4), %eax
	movl	%eax, 4(%r15)
	movl	4(%rbx), %eax
	addl	%eax, %eax
	leal	(%rax,%rax,4), %eax
	movl	%eax, 8(%r15)
	movq	_EDID_QUIRK_NON_DESKTOP@GOTPCREL(%rip), %rax
	xorl	%esi, %esi
	movl	%r14d, %ecx
	andl	(%rax), %ecx
	setne	%sil
	movl	%esi, 12(%r15)
	leaq	L_.str(%rip), %rdi
	callq	_DRM_DEBUG_KMS
	cmpl	$3, 8(%rbx)
	jl	LBB0_14
## %bb.1:
	movq	_DRM_EDID_INPUT_DIGITAL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, 12(%rbx)
	je	LBB0_14
## %bb.2:
	movq	%r15, %rdi
	movq	%rbx, %rsi
	callq	_drm_parse_cea_ext
	cmpl	$0, 16(%r15)
	je	LBB0_3
LBB0_6:
	movl	8(%rbx), %eax
LBB0_7:
	cmpl	$4, %eax
	jl	LBB0_14
## %bb.8:
	movq	_DRM_EDID_DIGITAL_DEPTH_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	12(%rbx), %eax
	addl	$-129, %eax
	xorl	%edx, %edx
	cmpl	$5, %eax
	ja	LBB0_10
## %bb.9:
	cltq
	leaq	l_switch.table.drm_add_display_info(%rip), %rcx
	movl	(%rcx,%rax,4), %edx
LBB0_10:
	movl	%edx, 16(%r15)
	movl	(%r15), %esi
	leaq	L_.str.2(%rip), %rdi
	callq	_DRM_DEBUG
	movq	_DRM_COLOR_FORMAT_RGB444@GOTPCREL(%rip), %rcx
	movl	20(%r15), %eax
	orl	(%rcx), %eax
	movl	%eax, 20(%r15)
	movl	16(%rbx), %ecx
	movq	_DRM_EDID_FEATURE_RGB_YCRCB444@GOTPCREL(%rip), %rdx
	testl	%ecx, (%rdx)
	je	LBB0_12
## %bb.11:
	movq	_DRM_COLOR_FORMAT_YCRCB444@GOTPCREL(%rip), %rdx
	orl	(%rdx), %eax
	movl	%eax, 20(%r15)
LBB0_12:
	movq	_DRM_EDID_FEATURE_RGB_YCRCB422@GOTPCREL(%rip), %rdx
	testl	%ecx, (%rdx)
	je	LBB0_14
## %bb.13:
	movq	_DRM_COLOR_FORMAT_YCRCB422@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	%eax, 20(%r15)
LBB0_14:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movl	8(%rbx), %eax
	cmpl	$3, %eax
	jne	LBB0_7
## %bb.4:
	movq	_DRM_EDID_DIGITAL_DFP_1_X@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, 12(%rbx)
	je	LBB0_6
## %bb.5:
	movl	$8, 16(%r15)
	movl	(%r15), %esi
	leaq	L_.str.1(%rip), %rdi
	movl	$8, %edx
	callq	_DRM_DEBUG
	jmp	LBB0_6
	.cfi_endproc
                                        ## -- End function
	.comm	_EDID_QUIRK_NON_DESKTOP,4,2     ## @EDID_QUIRK_NON_DESKTOP
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"non_desktop set to %d\n"

	.comm	_DRM_EDID_INPUT_DIGITAL,4,2     ## @DRM_EDID_INPUT_DIGITAL
	.comm	_DRM_EDID_DIGITAL_DFP_1_X,4,2   ## @DRM_EDID_DIGITAL_DFP_1_X
L_.str.1:                               ## @.str.1
	.asciz	"%s: Assigning DFP sink color depth as %d bpc.\n"

	.comm	_DRM_EDID_DIGITAL_DEPTH_MASK,4,2 ## @DRM_EDID_DIGITAL_DEPTH_MASK
L_.str.2:                               ## @.str.2
	.asciz	"%s: Assigning EDID-1.4 digital sink color depth as %d bpc.\n"

	.comm	_DRM_COLOR_FORMAT_RGB444,4,2    ## @DRM_COLOR_FORMAT_RGB444
	.comm	_DRM_EDID_FEATURE_RGB_YCRCB444,4,2 ## @DRM_EDID_FEATURE_RGB_YCRCB444
	.comm	_DRM_COLOR_FORMAT_YCRCB444,4,2  ## @DRM_COLOR_FORMAT_YCRCB444
	.comm	_DRM_EDID_FEATURE_RGB_YCRCB422,4,2 ## @DRM_EDID_FEATURE_RGB_YCRCB422
	.comm	_DRM_COLOR_FORMAT_YCRCB422,4,2  ## @DRM_COLOR_FORMAT_YCRCB422
	.section	__TEXT,__const
	.p2align	2                               ## @switch.table.drm_add_display_info
l_switch.table.drm_add_display_info:
	.long	8                               ## 0x8
	.long	6                               ## 0x6
	.long	16                              ## 0x10
	.long	14                              ## 0xe
	.long	12                              ## 0xc
	.long	10                              ## 0xa

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_drm_add_display_info           ; -- Begin function drm_add_display_info
	.p2align	2
_drm_add_display_info:                  ; @drm_add_display_info
	.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	x21, x1
	mov	x19, x0
	mov	x0, x1
	bl	_edid_get_quirks
	mov	x20, x0
	mov	x0, x19
	bl	_drm_reset_display_info
	ldr	d0, [x21]
	movi.2s	v1, #10
	mul.2s	v0, v0, v1
	stur	d0, [x19, #4]
Lloh0:
	adrp	x8, _EDID_QUIRK_NON_DESKTOP@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EDID_QUIRK_NON_DESKTOP@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	tst	w8, w20
	cset	w1, ne
	str	w1, [x19, #12]
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_DEBUG_KMS
	ldr	w8, [x21, #8]
	cmp	w8, #3
	b.lt	LBB0_15
; %bb.1:
	ldr	w8, [x21, #12]
Lloh5:
	adrp	x9, _DRM_EDID_INPUT_DIGITAL@GOTPAGE
Lloh6:
	ldr	x9, [x9, _DRM_EDID_INPUT_DIGITAL@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_15
; %bb.2:
	mov	x0, x19
	mov	x1, x21
	bl	_drm_parse_cea_ext
	ldr	w8, [x19, #16]
	cbz	w8, LBB0_7
LBB0_3:
	ldr	w8, [x21, #8]
LBB0_4:
	cmp	w8, #4
	b.lt	LBB0_15
; %bb.5:
	ldr	w8, [x21, #12]
Lloh8:
	adrp	x9, _DRM_EDID_DIGITAL_DEPTH_MASK@GOTPAGE
Lloh9:
	ldr	x9, [x9, _DRM_EDID_DIGITAL_DEPTH_MASK@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
	and	w8, w9, w8
	sub	w8, w8, #129
	cmp	w8, #5
	b.hi	LBB0_10
; %bb.6:
Lloh11:
	adrp	x9, l_switch.table.drm_add_display_info@PAGE
Lloh12:
	add	x9, x9, l_switch.table.drm_add_display_info@PAGEOFF
	ldr	w2, [x9, w8, sxtw #2]
	b	LBB0_11
LBB0_7:
	ldr	w8, [x21, #8]
	cmp	w8, #3
	b.ne	LBB0_4
; %bb.8:
	ldr	w8, [x21, #12]
Lloh13:
	adrp	x9, _DRM_EDID_DIGITAL_DFP_1_X@GOTPAGE
Lloh14:
	ldr	x9, [x9, _DRM_EDID_DIGITAL_DFP_1_X@GOTPAGEOFF]
Lloh15:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_3
; %bb.9:
	mov	w8, #8
	str	w8, [x19, #16]
	ldr	w1, [x19]
Lloh16:
	adrp	x0, l_.str.1@PAGE
Lloh17:
	add	x0, x0, l_.str.1@PAGEOFF
	mov	w2, #8
	bl	_DRM_DEBUG
	b	LBB0_3
LBB0_10:
	mov	w2, #0
LBB0_11:
	str	w2, [x19, #16]
	ldr	w1, [x19]
Lloh18:
	adrp	x0, l_.str.2@PAGE
Lloh19:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_DRM_DEBUG
Lloh20:
	adrp	x8, _DRM_COLOR_FORMAT_RGB444@GOTPAGE
Lloh21:
	ldr	x8, [x8, _DRM_COLOR_FORMAT_RGB444@GOTPAGEOFF]
Lloh22:
	ldr	w8, [x8]
	ldr	w9, [x19, #20]
	orr	w8, w9, w8
	str	w8, [x19, #20]
	ldr	w9, [x21, #16]
Lloh23:
	adrp	x10, _DRM_EDID_FEATURE_RGB_YCRCB444@GOTPAGE
Lloh24:
	ldr	x10, [x10, _DRM_EDID_FEATURE_RGB_YCRCB444@GOTPAGEOFF]
Lloh25:
	ldr	w10, [x10]
	tst	w10, w9
	b.eq	LBB0_13
; %bb.12:
Lloh26:
	adrp	x10, _DRM_COLOR_FORMAT_YCRCB444@GOTPAGE
Lloh27:
	ldr	x10, [x10, _DRM_COLOR_FORMAT_YCRCB444@GOTPAGEOFF]
Lloh28:
	ldr	w10, [x10]
	orr	w8, w10, w8
	str	w8, [x19, #20]
LBB0_13:
Lloh29:
	adrp	x10, _DRM_EDID_FEATURE_RGB_YCRCB422@GOTPAGE
Lloh30:
	ldr	x10, [x10, _DRM_EDID_FEATURE_RGB_YCRCB422@GOTPAGEOFF]
Lloh31:
	ldr	w10, [x10]
	tst	w10, w9
	b.eq	LBB0_15
; %bb.14:
Lloh32:
	adrp	x9, _DRM_COLOR_FORMAT_YCRCB422@GOTPAGE
Lloh33:
	ldr	x9, [x9, _DRM_COLOR_FORMAT_YCRCB422@GOTPAGEOFF]
Lloh34:
	ldr	w9, [x9]
	orr	w8, w8, w9
	str	w8, [x19, #20]
LBB0_15:
	mov	x0, x20
	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
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.cfi_endproc
                                        ; -- End function
	.comm	_EDID_QUIRK_NON_DESKTOP,4,2     ; @EDID_QUIRK_NON_DESKTOP
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"non_desktop set to %d\n"

	.comm	_DRM_EDID_INPUT_DIGITAL,4,2     ; @DRM_EDID_INPUT_DIGITAL
	.comm	_DRM_EDID_DIGITAL_DFP_1_X,4,2   ; @DRM_EDID_DIGITAL_DFP_1_X
l_.str.1:                               ; @.str.1
	.asciz	"%s: Assigning DFP sink color depth as %d bpc.\n"

	.comm	_DRM_EDID_DIGITAL_DEPTH_MASK,4,2 ; @DRM_EDID_DIGITAL_DEPTH_MASK
l_.str.2:                               ; @.str.2
	.asciz	"%s: Assigning EDID-1.4 digital sink color depth as %d bpc.\n"

	.comm	_DRM_COLOR_FORMAT_RGB444,4,2    ; @DRM_COLOR_FORMAT_RGB444
	.comm	_DRM_EDID_FEATURE_RGB_YCRCB444,4,2 ; @DRM_EDID_FEATURE_RGB_YCRCB444
	.comm	_DRM_COLOR_FORMAT_YCRCB444,4,2  ; @DRM_COLOR_FORMAT_YCRCB444
	.comm	_DRM_EDID_FEATURE_RGB_YCRCB422,4,2 ; @DRM_EDID_FEATURE_RGB_YCRCB422
	.comm	_DRM_COLOR_FORMAT_YCRCB422,4,2  ; @DRM_COLOR_FORMAT_YCRCB422
	.section	__TEXT,__const
	.p2align	2                               ; @switch.table.drm_add_display_info
l_switch.table.drm_add_display_info:
	.long	8                               ; 0x8
	.long	6                               ; 0x6
	.long	16                              ; 0x10
	.long	14                              ; 0xe
	.long	12                              ; 0xc
	.long	10                              ; 0xa

.subsections_via_symbols
