	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function amdgpu_dm_initialize_drm_device
_amdgpu_dm_initialize_drm_device:       ## @amdgpu_dm_initialize_drm_device
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r13
	movq	_dc_connection_none@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -60(%rbp)
	movq	24(%rdi), %rax
	movl	8(%rax), %ebx
	movl	32(%rdi), %edi
	callq	_amdgpu_dm_mode_config_init
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rdi
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_DRM_ERROR
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_56
LBB0_2:
	movl	%ebx, -44(%rbp)                 ## 4-byte Spill
	leaq	16(%r13), %r14
	leaq	8(%r13), %r12
	movq	24(%r13), %rax
	movl	12(%rax), %ebx
	movq	_AMDGPU_MAX_PLANES@GOTPCREL(%rip), %rax
	xorl	%edi, %edi
	cmpl	(%rax), %ebx
	setle	%dil
	callq	_ASSERT
	movq	_DRM_PLANE_TYPE_PRIMARY@GOTPCREL(%rip), %r15
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	testl	%ebx, %ebx
	jle	LBB0_4
## %bb.6:                               ##   in Loop: Header=BB0_3 Depth=1
	decq	%rbx
	movq	24(%r13), %rax
	movl	%ebx, %ecx
	leaq	(%rcx,%rcx,2), %r8
	shlq	$3, %r8
	addq	24(%rax), %r8
	movl	(%r15), %ecx
	movq	%r14, %rdi
	movq	%r12, %rsi
	movl	%ebx, %edx
	callq	_initialize_plane
	testq	%rax, %rax
	je	LBB0_3
## %bb.7:
	leaq	L_.str.1(%rip), %rdi
	jmp	LBB0_8
LBB0_4:
	movq	24(%r13), %rax
	movl	16(%rax), %ecx
	testl	%ecx, %ecx
	jle	LBB0_5
## %bb.9:
	movq	24(%rax), %r8
	movq	_DC_PLANE_TYPE_DCN_UNIVERSAL@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rsi
	negq	%rcx
	xorl	%edi, %edi
	movl	-44(%rbp), %r15d                ## 4-byte Reload
	jmp	LBB0_10
	.p2align	4, 0x90
LBB0_17:                                ##   in Loop: Header=BB0_10 Depth=1
	decq	%rdi
	addq	$24, %r8
	cmpq	%rdi, %rcx
	je	LBB0_18
LBB0_10:                                ## =>This Inner Loop Header: Depth=1
	cmpq	%rsi, (%r8)
	jne	LBB0_17
## %bb.11:                              ##   in Loop: Header=BB0_10 Depth=1
	cmpl	$0, 16(%r8)
	je	LBB0_17
## %bb.12:                              ##   in Loop: Header=BB0_10 Depth=1
	cmpl	$0, 12(%r8)
	je	LBB0_17
## %bb.13:                              ##   in Loop: Header=BB0_10 Depth=1
	cmpl	$0, 8(%r8)
	je	LBB0_17
## %bb.14:
	movq	-56(%rbp), %rdx                 ## 8-byte Reload
	subl	%edi, %edx
	movq	_DRM_PLANE_TYPE_OVERLAY@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r14, %rdi
	xorl	%esi, %esi
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_initialize_plane
	testq	%rax, %rax
	je	LBB0_15
## %bb.16:
	leaq	L_.str.2(%rip), %rdi
	jmp	LBB0_8
LBB0_5:
	movl	-44(%rbp), %r15d                ## 4-byte Reload
LBB0_18:
	movl	12(%rax), %eax
	testl	%eax, %eax
	jle	LBB0_23
## %bb.19:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_21:                                ## =>This Inner Loop Header: Depth=1
	movq	(%r12), %rax
	movl	(%rax,%rbx,4), %esi
	movq	%r14, %rdi
	movl	%ebx, %edx
	callq	_amdgpu_dm_crtc_init
	testq	%rax, %rax
	jne	LBB0_22
## %bb.20:                              ##   in Loop: Header=BB0_21 Depth=1
	incq	%rbx
	movq	24(%r13), %rax
	movslq	12(%rax), %rax
	cmpq	%rax, %rbx
	jl	LBB0_21
LBB0_23:
	movl	%eax, (%r14)
	testl	%r15d, %r15d
	jle	LBB0_24
## %bb.25:
	xorl	%ebx, %ebx
	xorl	%r12d, %r12d
	xorl	%eax, %eax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	jmp	LBB0_26
	.p2align	4, 0x90
LBB0_27:                                ##   in Loop: Header=BB0_26 Depth=1
	leaq	L_.str.4(%rip), %rdi
	xorl	%eax, %eax
	callq	_DRM_ERROR
LBB0_45:                                ##   in Loop: Header=BB0_26 Depth=1
	incl	%ebx
	cmpl	%ebx, %r15d
	je	LBB0_46
LBB0_26:                                ## =>This Inner Loop Header: Depth=1
	movq	_AMDGPU_DM_MAX_DISPLAY_INDEX@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	cmpl	%esi, %ebx
	jg	LBB0_27
## %bb.28:                              ##   in Loop: Header=BB0_26 Depth=1
	movq	_GFP_KERNEL@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	movl	$8, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_29
## %bb.30:                              ##   in Loop: Header=BB0_26 Depth=1
	movq	%rax, %r12
	movl	(%r15), %esi
	movl	$8, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_31
## %bb.32:                              ##   in Loop: Header=BB0_26 Depth=1
	movq	%rax, %r15
	movl	36(%r13), %edi
	movq	%rax, %rsi
	movl	%ebx, %edx
	callq	_amdgpu_dm_encoder_init
	testq	%rax, %rax
	jne	LBB0_33
## %bb.35:                              ##   in Loop: Header=BB0_26 Depth=1
	movq	%r14, %rdi
	movq	%r12, %rsi
	movl	%ebx, %edx
	movq	%r15, %rcx
	callq	_amdgpu_dm_connector_init
	testq	%rax, %rax
	jne	LBB0_36
## %bb.37:                              ##   in Loop: Header=BB0_26 Depth=1
	movq	%r15, -56(%rbp)                 ## 8-byte Spill
	movq	24(%r13), %rdi
	movl	%ebx, %esi
	callq	_dc_get_link_at_index
	movq	%rax, %r15
	movq	%rax, %rdi
	leaq	-60(%rbp), %rsi
	callq	_dc_link_detect_sink
	testl	%eax, %eax
	je	LBB0_38
## %bb.39:                              ##   in Loop: Header=BB0_26 Depth=1
	cmpq	$0, (%r12)
	jne	LBB0_40
	jmp	LBB0_42
LBB0_38:                                ##   in Loop: Header=BB0_26 Depth=1
	leaq	L_.str.7(%rip), %rdi
	xorl	%eax, %eax
	callq	_DRM_ERROR
	cmpq	$0, (%r12)
	je	LBB0_42
LBB0_40:                                ##   in Loop: Header=BB0_26 Depth=1
	movl	-60(%rbp), %eax
	movq	_dc_connection_none@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_42
## %bb.41:                              ##   in Loop: Header=BB0_26 Depth=1
	movq	%r15, %rdi
	callq	_emulated_link_detect
	movq	%r12, %rdi
	callq	_amdgpu_dm_update_connector_after_detect
	jmp	LBB0_44
	.p2align	4, 0x90
LBB0_42:                                ##   in Loop: Header=BB0_26 Depth=1
	movq	_DETECT_REASON_BOOT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_dc_link_detect
	testq	%rax, %rax
	je	LBB0_44
## %bb.43:                              ##   in Loop: Header=BB0_26 Depth=1
	movq	%r12, %rdi
	callq	_amdgpu_dm_update_connector_after_detect
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_register_backlight_device
LBB0_44:                                ##   in Loop: Header=BB0_26 Depth=1
	movl	-44(%rbp), %r15d                ## 4-byte Reload
	jmp	LBB0_45
LBB0_22:
	leaq	L_.str.3(%rip), %rdi
LBB0_8:
	xorl	%r15d, %r15d
	xorl	%eax, %eax
	callq	_DRM_ERROR
	xorl	%r12d, %r12d
	jmp	LBB0_55
LBB0_24:
	xorl	%eax, %eax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	xorl	%r12d, %r12d
LBB0_46:
	movl	(%r13), %esi
	leal	-128(%rsi), %eax
	cmpl	$20, %eax
	ja	LBB0_53
## %bb.47:
	movl	$2082623, %ecx                  ## imm = 0x1FC73F
	btl	%eax, %ecx
	jae	LBB0_53
## %bb.48:
	movl	32(%r13), %edi
	callq	_dce110_register_irq_handlers
	testl	%eax, %eax
	movq	-56(%rbp), %r15                 ## 8-byte Reload
	je	LBB0_50
## %bb.49:
	leaq	L_.str.8(%rip), %rdi
	jmp	LBB0_34
LBB0_50:
	movl	(%r13), %eax
	xorl	%ebx, %ebx
	cmpl	$133, %eax
	je	LBB0_57
## %bb.51:
	cmpl	$147, %eax
	je	LBB0_57
## %bb.52:
	movq	_amdgpu_pp_feature_mask@GOTPCREL(%rip), %rax
	movq	_PP_STUTTER_MODE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	xorl	%edx, %edx
	andl	(%rax), %ecx
	sete	%dl
	movq	24(%r13), %rax
	movl	%edx, (%rax)
	jmp	LBB0_57
LBB0_29:
	xorl	%r12d, %r12d
	jmp	LBB0_54
LBB0_31:
	xorl	%r15d, %r15d
	jmp	LBB0_55
LBB0_33:
	leaq	L_.str.5(%rip), %rdi
	jmp	LBB0_34
LBB0_36:
	leaq	L_.str.6(%rip), %rdi
LBB0_34:
	xorl	%eax, %eax
	callq	_DRM_ERROR
	jmp	LBB0_55
LBB0_15:
	movq	24(%r13), %rax
	jmp	LBB0_18
LBB0_53:
	leaq	L_.str.9(%rip), %rdi
                                        ## kill: def $esi killed $esi killed $rsi
	xorl	%eax, %eax
	callq	_DRM_ERROR
LBB0_54:
	movq	-56(%rbp), %r15                 ## 8-byte Reload
LBB0_55:
	movq	%r15, %rdi
	callq	_kfree
	movq	%r12, %rdi
	callq	_kfree
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
LBB0_56:
	subl	(%rax), %ebx
LBB0_57:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_dc_connection_none,4,2         ## @dc_connection_none
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"DM: Failed to initialize mode config\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_AMDGPU_MAX_PLANES,4,2          ## @AMDGPU_MAX_PLANES
	.comm	_DRM_PLANE_TYPE_PRIMARY,4,2     ## @DRM_PLANE_TYPE_PRIMARY
L_.str.1:                               ## @.str.1
	.asciz	"KMS: Failed to initialize primary plane\n"

	.comm	_DC_PLANE_TYPE_DCN_UNIVERSAL,8,3 ## @DC_PLANE_TYPE_DCN_UNIVERSAL
	.comm	_DRM_PLANE_TYPE_OVERLAY,4,2     ## @DRM_PLANE_TYPE_OVERLAY
L_.str.2:                               ## @.str.2
	.asciz	"KMS: Failed to initialize overlay plane\n"

L_.str.3:                               ## @.str.3
	.asciz	"KMS: Failed to initialize crtc\n"

	.comm	_AMDGPU_DM_MAX_DISPLAY_INDEX,4,2 ## @AMDGPU_DM_MAX_DISPLAY_INDEX
L_.str.4:                               ## @.str.4
	.asciz	"KMS: Cannot support more than %d display indexes\n"

	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
L_.str.5:                               ## @.str.5
	.asciz	"KMS: Failed to initialize encoder\n"

L_.str.6:                               ## @.str.6
	.asciz	"KMS: Failed to initialize connector\n"

L_.str.7:                               ## @.str.7
	.asciz	"KMS: Failed to detect connector\n"

	.comm	_DETECT_REASON_BOOT,4,2         ## @DETECT_REASON_BOOT
L_.str.8:                               ## @.str.8
	.asciz	"DM: Failed to initialize IRQ\n"

L_.str.9:                               ## @.str.9
	.asciz	"Unsupported ASIC type: 0x%X\n"

	.comm	_amdgpu_pp_feature_mask,4,2     ## @amdgpu_pp_feature_mask
	.comm	_PP_STUTTER_MODE,4,2            ## @PP_STUTTER_MODE
	.no_dead_strip	_amdgpu_dm_initialize_drm_device
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function amdgpu_dm_initialize_drm_device
_amdgpu_dm_initialize_drm_device:       ; @amdgpu_dm_initialize_drm_device
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x0
Lloh0:
	adrp	x27, _dc_connection_none@GOTPAGE
Lloh1:
	ldr	x27, [x27, _dc_connection_none@GOTPAGEOFF]
	ldr	w8, [x27]
	str	w8, [sp, #12]
	ldr	x8, [x0, #24]
	ldr	w28, [x8, #8]
	ldr	w0, [x0, #32]
	bl	_amdgpu_dm_mode_config_init
	cbz	x0, LBB0_2
; %bb.1:
Lloh2:
	adrp	x0, l_.str@PAGE
Lloh3:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_ERROR
	b	LBB0_50
LBB0_2:
	add	x20, x19, #16
	add	x21, x19, #8
	ldr	x8, [x19, #24]
	ldr	w22, [x8, #12]
Lloh4:
	adrp	x8, _AMDGPU_MAX_PLANES@GOTPAGE
Lloh5:
	ldr	x8, [x8, _AMDGPU_MAX_PLANES@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	cmp	w22, w8
	cset	w0, le
	bl	_ASSERT
	mov	w24, #24
Lloh7:
	adrp	x25, _DRM_PLANE_TYPE_PRIMARY@GOTPAGE
Lloh8:
	ldr	x25, [x25, _DRM_PLANE_TYPE_PRIMARY@GOTPAGEOFF]
	mov	x23, x22
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	cmp	w23, #0
	b.le	LBB0_6
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	sub	x23, x23, #1
	ldr	x8, [x19, #24]
	ldr	x8, [x8, #24]
	and	x9, x23, #0xffffffff
	madd	x4, x9, x24, x8
	ldr	w3, [x25]
	mov	x0, x20
	mov	x1, x21
	mov	x2, x23
	bl	_initialize_plane
	cbz	x0, LBB0_3
; %bb.5:
Lloh9:
	adrp	x0, l_.str.1@PAGE
Lloh10:
	add	x0, x0, l_.str.1@PAGEOFF
	b	LBB0_37
LBB0_6:
	ldr	x8, [x19, #24]
	ldr	w9, [x8, #16]
	cmp	w9, #1
	b.lt	LBB0_16
; %bb.7:
	ldr	x4, [x8, #24]
Lloh11:
	adrp	x10, _DC_PLANE_TYPE_DCN_UNIVERSAL@GOTPAGE
Lloh12:
	ldr	x10, [x10, _DC_PLANE_TYPE_DCN_UNIVERSAL@GOTPAGEOFF]
Lloh13:
	ldr	x10, [x10]
	b	LBB0_9
LBB0_8:                                 ;   in Loop: Header=BB0_9 Depth=1
	add	w22, w22, #1
	add	x4, x4, #24
	subs	x9, x9, #1
	b.eq	LBB0_16
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x11, [x4]
	cmp	x11, x10
	b.ne	LBB0_8
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	ldr	w11, [x4, #16]
	cbz	w11, LBB0_8
; %bb.11:                               ;   in Loop: Header=BB0_9 Depth=1
	ldr	w11, [x4, #12]
	cbz	w11, LBB0_8
; %bb.12:                               ;   in Loop: Header=BB0_9 Depth=1
	ldr	w11, [x4, #8]
	cbz	w11, LBB0_8
; %bb.13:
Lloh14:
	adrp	x8, _DRM_PLANE_TYPE_OVERLAY@GOTPAGE
Lloh15:
	ldr	x8, [x8, _DRM_PLANE_TYPE_OVERLAY@GOTPAGEOFF]
Lloh16:
	ldr	w3, [x8]
	mov	x0, x20
	mov	x1, #0
	mov	x2, x22
	bl	_initialize_plane
	cbz	x0, LBB0_15
; %bb.14:
Lloh17:
	adrp	x0, l_.str.2@PAGE
Lloh18:
	add	x0, x0, l_.str.2@PAGEOFF
	b	LBB0_37
LBB0_15:
	ldr	x8, [x19, #24]
LBB0_16:
	ldr	w8, [x8, #12]
	cmp	w8, #1
	b.lt	LBB0_20
; %bb.17:
	mov	x22, #0
LBB0_18:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x21]
	ldr	w1, [x8, x22, lsl #2]
	mov	x0, x20
	mov	x2, x22
	bl	_amdgpu_dm_crtc_init
	cbnz	x0, LBB0_36
; %bb.19:                               ;   in Loop: Header=BB0_18 Depth=1
	add	x22, x22, #1
	ldr	x8, [x19, #24]
	ldrsw	x8, [x8, #12]
	cmp	x22, x8
	b.lt	LBB0_18
LBB0_20:
	str	w8, [x20]
	cmp	w28, #1
	b.lt	LBB0_38
; %bb.21:
	mov	w23, #0
	mov	x21, #0
	mov	x22, #0
Lloh19:
	adrp	x25, _AMDGPU_DM_MAX_DISPLAY_INDEX@GOTPAGE
Lloh20:
	ldr	x25, [x25, _AMDGPU_DM_MAX_DISPLAY_INDEX@GOTPAGEOFF]
Lloh21:
	adrp	x24, _GFP_KERNEL@GOTPAGE
Lloh22:
	ldr	x24, [x24, _GFP_KERNEL@GOTPAGEOFF]
	b	LBB0_24
LBB0_22:                                ;   in Loop: Header=BB0_24 Depth=1
	str	x8, [sp]
Lloh23:
	adrp	x0, l_.str.4@PAGE
Lloh24:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	_DRM_ERROR
LBB0_23:                                ;   in Loop: Header=BB0_24 Depth=1
	add	w23, w23, #1
	cmp	w28, w23
	b.eq	LBB0_39
LBB0_24:                                ; =>This Inner Loop Header: Depth=1
	ldr	w8, [x25]
	cmp	w23, w8
	b.gt	LBB0_22
; %bb.25:                               ;   in Loop: Header=BB0_24 Depth=1
	ldr	w1, [x24]
	mov	w0, #8
	bl	_kzalloc
	mov	x21, x0
	cbz	x0, LBB0_49
; %bb.26:                               ;   in Loop: Header=BB0_24 Depth=1
	ldr	w1, [x24]
	mov	w0, #8
	bl	_kzalloc
	mov	x22, x0
	cbz	x0, LBB0_49
; %bb.27:                               ;   in Loop: Header=BB0_24 Depth=1
	ldr	w0, [x19, #36]
	mov	x1, x22
	mov	x2, x23
	bl	_amdgpu_dm_encoder_init
	cbnz	x0, LBB0_45
; %bb.28:                               ;   in Loop: Header=BB0_24 Depth=1
	mov	x0, x20
	mov	x1, x21
	mov	x2, x23
	mov	x3, x22
	bl	_amdgpu_dm_connector_init
	cbnz	x0, LBB0_46
; %bb.29:                               ;   in Loop: Header=BB0_24 Depth=1
	ldr	x0, [x19, #24]
	mov	x1, x23
	bl	_dc_get_link_at_index
	mov	x26, x0
	add	x1, sp, #12
	bl	_dc_link_detect_sink
	cbz	w0, LBB0_31
; %bb.30:                               ;   in Loop: Header=BB0_24 Depth=1
	ldr	x8, [x21]
	cbnz	x8, LBB0_32
	b	LBB0_34
LBB0_31:                                ;   in Loop: Header=BB0_24 Depth=1
Lloh25:
	adrp	x0, l_.str.7@PAGE
Lloh26:
	add	x0, x0, l_.str.7@PAGEOFF
	bl	_DRM_ERROR
	ldr	x8, [x21]
	cbz	x8, LBB0_34
LBB0_32:                                ;   in Loop: Header=BB0_24 Depth=1
	ldr	w8, [sp, #12]
	ldr	w9, [x27]
	cmp	w8, w9
	b.ne	LBB0_34
; %bb.33:                               ;   in Loop: Header=BB0_24 Depth=1
	mov	x0, x26
	bl	_emulated_link_detect
	mov	x0, x21
	bl	_amdgpu_dm_update_connector_after_detect
	b	LBB0_23
LBB0_34:                                ;   in Loop: Header=BB0_24 Depth=1
Lloh27:
	adrp	x8, _DETECT_REASON_BOOT@GOTPAGE
Lloh28:
	ldr	x8, [x8, _DETECT_REASON_BOOT@GOTPAGEOFF]
Lloh29:
	ldr	w1, [x8]
	mov	x0, x26
	bl	_dc_link_detect
	cbz	x0, LBB0_23
; %bb.35:                               ;   in Loop: Header=BB0_24 Depth=1
	mov	x0, x21
	bl	_amdgpu_dm_update_connector_after_detect
	mov	x0, x20
	mov	x1, x26
	bl	_register_backlight_device
	b	LBB0_23
LBB0_36:
Lloh30:
	adrp	x0, l_.str.3@PAGE
Lloh31:
	add	x0, x0, l_.str.3@PAGEOFF
LBB0_37:
	bl	_DRM_ERROR
	mov	x22, #0
	mov	x21, #0
	b	LBB0_49
LBB0_38:
	mov	x22, #0
	mov	x21, #0
LBB0_39:
	ldr	w8, [x19]
	sub	w9, w8, #128
	cmp	w9, #20
	mov	w10, #1
	lsl	w9, w10, w9
	mov	w10, #51007
	movk	w10, #31, lsl #16
	and	w9, w9, w10
	ccmp	w9, #0, #4, ls
	b.eq	LBB0_47
; %bb.40:
	ldr	w0, [x19, #32]
	bl	_dce110_register_irq_handlers
	cbz	w0, LBB0_42
; %bb.41:
Lloh32:
	adrp	x0, l_.str.8@PAGE
Lloh33:
	add	x0, x0, l_.str.8@PAGEOFF
	b	LBB0_48
LBB0_42:
	ldr	w8, [x19]
	cmp	w8, #133
	b.eq	LBB0_51
; %bb.43:
	cmp	w8, #147
	b.eq	LBB0_51
; %bb.44:
	mov	w0, #0
Lloh34:
	adrp	x8, _amdgpu_pp_feature_mask@GOTPAGE
Lloh35:
	ldr	x8, [x8, _amdgpu_pp_feature_mask@GOTPAGEOFF]
Lloh36:
	adrp	x9, _PP_STUTTER_MODE@GOTPAGE
Lloh37:
	ldr	x9, [x9, _PP_STUTTER_MODE@GOTPAGEOFF]
Lloh38:
	ldr	w8, [x8]
Lloh39:
	ldr	w9, [x9]
	tst	w9, w8
	cset	w8, eq
	ldr	x9, [x19, #24]
	str	w8, [x9]
	b	LBB0_51
LBB0_45:
Lloh40:
	adrp	x0, l_.str.5@PAGE
Lloh41:
	add	x0, x0, l_.str.5@PAGEOFF
	b	LBB0_48
LBB0_46:
Lloh42:
	adrp	x0, l_.str.6@PAGE
Lloh43:
	add	x0, x0, l_.str.6@PAGEOFF
	b	LBB0_48
LBB0_47:
	str	x8, [sp]
Lloh44:
	adrp	x0, l_.str.9@PAGE
Lloh45:
	add	x0, x0, l_.str.9@PAGEOFF
LBB0_48:
	bl	_DRM_ERROR
LBB0_49:
	mov	x0, x22
	bl	_kfree
	mov	x0, x21
	bl	_kfree
LBB0_50:
Lloh46:
	adrp	x8, _EINVAL@GOTPAGE
Lloh47:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh48:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_51:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpAdd	Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh39
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh38
	.loh AdrpAdd	Lloh40, Lloh41
	.loh AdrpAdd	Lloh42, Lloh43
	.loh AdrpAdd	Lloh44, Lloh45
	.loh AdrpLdrGotLdr	Lloh46, Lloh47, Lloh48
	.cfi_endproc
                                        ; -- End function
	.comm	_dc_connection_none,4,2         ; @dc_connection_none
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"DM: Failed to initialize mode config\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_AMDGPU_MAX_PLANES,4,2          ; @AMDGPU_MAX_PLANES
	.comm	_DRM_PLANE_TYPE_PRIMARY,4,2     ; @DRM_PLANE_TYPE_PRIMARY
l_.str.1:                               ; @.str.1
	.asciz	"KMS: Failed to initialize primary plane\n"

	.comm	_DC_PLANE_TYPE_DCN_UNIVERSAL,8,3 ; @DC_PLANE_TYPE_DCN_UNIVERSAL
	.comm	_DRM_PLANE_TYPE_OVERLAY,4,2     ; @DRM_PLANE_TYPE_OVERLAY
l_.str.2:                               ; @.str.2
	.asciz	"KMS: Failed to initialize overlay plane\n"

l_.str.3:                               ; @.str.3
	.asciz	"KMS: Failed to initialize crtc\n"

	.comm	_AMDGPU_DM_MAX_DISPLAY_INDEX,4,2 ; @AMDGPU_DM_MAX_DISPLAY_INDEX
l_.str.4:                               ; @.str.4
	.asciz	"KMS: Cannot support more than %d display indexes\n"

	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
l_.str.5:                               ; @.str.5
	.asciz	"KMS: Failed to initialize encoder\n"

l_.str.6:                               ; @.str.6
	.asciz	"KMS: Failed to initialize connector\n"

l_.str.7:                               ; @.str.7
	.asciz	"KMS: Failed to detect connector\n"

	.comm	_DETECT_REASON_BOOT,4,2         ; @DETECT_REASON_BOOT
l_.str.8:                               ; @.str.8
	.asciz	"DM: Failed to initialize IRQ\n"

l_.str.9:                               ; @.str.9
	.asciz	"Unsupported ASIC type: 0x%X\n"

	.comm	_amdgpu_pp_feature_mask,4,2     ; @amdgpu_pp_feature_mask
	.comm	_PP_STUTTER_MODE,4,2            ; @PP_STUTTER_MODE
	.no_dead_strip	_amdgpu_dm_initialize_drm_device
.subsections_via_symbols
