	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function amdgpu_dm_update_connector_after_detect
_amdgpu_dm_update_connector_after_detect: ## @amdgpu_dm_update_connector_after_detect
	.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
	cmpl	$1, 64(%rdi)
	jne	LBB0_1
LBB0_16:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movq	%rdi, %rbx
	leaq	40(%rdi), %r12
	movq	48(%rdi), %r14
	movq	56(%rdi), %rax
	movq	(%rax), %r15
	testq	%r15, %r15
	je	LBB0_3
## %bb.2:
	movq	%r15, %rdi
	callq	_dc_sink_retain
LBB0_3:
	movq	(%r12), %rax
	movq	_DRM_FORCE_UNSPECIFIED@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_12
## %bb.4:
	cmpq	$0, 32(%rbx)
	je	LBB0_12
## %bb.5:
	movq	%r14, %rdi
	callq	_mutex_lock
	testq	%r15, %r15
	je	LBB0_9
## %bb.6:
	cmpq	$0, 8(%rbx)
	je	LBB0_8
## %bb.7:
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_amdgpu_dm_update_freesync_caps
	movq	8(%rbx), %rdi
	callq	_dc_sink_release
LBB0_8:
	movq	%r15, 8(%rbx)
	movq	%r15, %rdi
	callq	_dc_sink_retain
	jmp	LBB0_24
LBB0_12:
	testq	%r15, %r15
	je	LBB0_14
## %bb.13:
	movq	(%r15), %rax
	movq	_SIGNAL_TYPE_DISPLAY_PORT_MST@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_25
LBB0_14:
	movq	8(%rbx), %rdx
	movl	28(%rbx), %esi
	cmpq	%r15, %rdx
	je	LBB0_15
## %bb.17:
	leaq	L_.str.1(%rip), %rdi
	movq	%r15, %rcx
	xorl	%eax, %eax
	callq	_DRM_DEBUG_DRIVER
	movq	%r14, %rdi
	callq	_mutex_lock
	testq	%r15, %r15
	je	LBB0_22
## %bb.18:
	cmpq	$0, 8(%rbx)
	je	LBB0_20
## %bb.19:
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_amdgpu_dm_update_freesync_caps
LBB0_20:
	movq	%r15, 8(%rbx)
	movq	%r15, %rdi
	callq	_dc_sink_retain
	cmpq	$0, 8(%r15)
	je	LBB0_21
## %bb.23:
	movq	16(%r15), %rsi
	movq	%rsi, (%rbx)
	movq	%r12, %rdi
	callq	_drm_connector_update_edid_property
	leaq	24(%rbx), %rdi
	movq	(%rbx), %rsi
	callq	_drm_dp_cec_set_edid
	jmp	LBB0_24
LBB0_15:
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	callq	_DRM_DEBUG_DRIVER
	testq	%r15, %r15
	jne	LBB0_25
	jmp	LBB0_16
LBB0_9:
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_amdgpu_dm_update_freesync_caps
	cmpq	$0, 8(%rbx)
	jne	LBB0_11
## %bb.10:
	movq	32(%rbx), %rdi
	movq	%rdi, 8(%rbx)
	callq	_dc_sink_retain
	jmp	LBB0_11
LBB0_22:
	leaq	24(%rbx), %rdi
	callq	_drm_dp_cec_unset_edid
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_amdgpu_dm_update_freesync_caps
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_drm_connector_update_edid_property
	movq	$0, 16(%rbx)
	movq	8(%rbx), %rdi
	callq	_dc_sink_release
	xorps	%xmm0, %xmm0
	movups	%xmm0, (%rbx)
LBB0_11:
	movq	%r14, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_mutex_unlock                   ## TAILCALL
LBB0_21:
	movq	$0, (%rbx)
	leaq	24(%rbx), %rdi
	callq	_drm_dp_cec_unset_edid
LBB0_24:
	movq	(%rbx), %rsi
	movq	%r12, %rdi
	callq	_amdgpu_dm_update_freesync_caps
	movq	%r14, %rdi
	callq	_mutex_unlock
LBB0_25:
	movq	%r15, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_dc_sink_release                ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_DRM_FORCE_UNSPECIFIED,8,3      ## @DRM_FORCE_UNSPECIFIED
	.comm	_SIGNAL_TYPE_DISPLAY_PORT_MST,8,3 ## @SIGNAL_TYPE_DISPLAY_PORT_MST
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"DCHPD: connector_id=%d: dc_sink didn't change.\n"

L_.str.1:                               ## @.str.1
	.asciz	"DCHPD: connector_id=%d: Old sink=%p New sink=%p\n"

	.no_dead_strip	_amdgpu_dm_update_connector_after_detect
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function amdgpu_dm_update_connector_after_detect
_amdgpu_dm_update_connector_after_detect: ; @amdgpu_dm_update_connector_after_detect
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	ldr	w8, [x0, #64]
	cmp	w8, #1
	b.ne	LBB0_2
LBB0_1:
	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
	add	sp, sp, #64
	ret
LBB0_2:
	mov	x20, x0
	add	x22, x0, #40
	ldp	x19, x8, [x0, #48]
	ldr	x21, [x8]
	cbz	x21, LBB0_4
; %bb.3:
	mov	x0, x21
	bl	_dc_sink_retain
LBB0_4:
	ldr	x8, [x22]
Lloh0:
	adrp	x9, _DRM_FORCE_UNSPECIFIED@GOTPAGE
Lloh1:
	ldr	x9, [x9, _DRM_FORCE_UNSPECIFIED@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.eq	LBB0_10
; %bb.5:
	ldr	x8, [x20, #32]
	cbz	x8, LBB0_10
; %bb.6:
	mov	x0, x19
	bl	_mutex_lock
	cbz	x21, LBB0_19
; %bb.7:
	ldr	x8, [x20, #8]
	cbz	x8, LBB0_9
; %bb.8:
	mov	x0, x22
	mov	x1, #0
	bl	_amdgpu_dm_update_freesync_caps
	ldr	x0, [x20, #8]
	bl	_dc_sink_release
LBB0_9:
	str	x21, [x20, #8]
	mov	x0, x21
	bl	_dc_sink_retain
	b	LBB0_24
LBB0_10:
	cbz	x21, LBB0_12
; %bb.11:
	ldr	x8, [x21]
Lloh3:
	adrp	x9, _SIGNAL_TYPE_DISPLAY_PORT_MST@GOTPAGE
Lloh4:
	ldr	x9, [x9, _SIGNAL_TYPE_DISPLAY_PORT_MST@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x8, x9
	b.eq	LBB0_25
LBB0_12:
	ldr	x8, [x20, #8]
	ldr	w1, [x20, #28]
	cmp	x8, x21
	b.eq	LBB0_18
; %bb.13:
	stp	x8, x21, [sp]
Lloh6:
	adrp	x0, l_.str.1@PAGE
Lloh7:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_DRM_DEBUG_DRIVER
	mov	x0, x19
	bl	_mutex_lock
	cbz	x21, LBB0_21
; %bb.14:
	ldr	x8, [x20, #8]
	cbz	x8, LBB0_16
; %bb.15:
	mov	x0, x22
	mov	x1, #0
	bl	_amdgpu_dm_update_freesync_caps
LBB0_16:
	str	x21, [x20, #8]
	mov	x0, x21
	bl	_dc_sink_retain
	ldr	x8, [x21, #8]
	cbz	x8, LBB0_23
; %bb.17:
	ldr	x1, [x21, #16]
	str	x1, [x20]
	mov	x0, x22
	bl	_drm_connector_update_edid_property
	mov	x0, x20
	ldr	x1, [x0], #24
	bl	_drm_dp_cec_set_edid
	b	LBB0_24
LBB0_18:
Lloh8:
	adrp	x0, l_.str@PAGE
Lloh9:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_DEBUG_DRIVER
	cbnz	x21, LBB0_25
	b	LBB0_1
LBB0_19:
	mov	x0, x22
	mov	x1, #0
	bl	_amdgpu_dm_update_freesync_caps
	ldr	x8, [x20, #8]
	cbnz	x8, LBB0_22
; %bb.20:
	ldr	x0, [x20, #32]
	str	x0, [x20, #8]
	bl	_dc_sink_retain
	b	LBB0_22
LBB0_21:
	add	x0, x20, #24
	bl	_drm_dp_cec_unset_edid
	mov	x0, x22
	mov	x1, #0
	bl	_amdgpu_dm_update_freesync_caps
	mov	x0, x22
	mov	x1, #0
	bl	_drm_connector_update_edid_property
	str	xzr, [x20, #16]
	ldr	x0, [x20, #8]
	bl	_dc_sink_release
	stp	xzr, xzr, [x20]
LBB0_22:
	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
	add	sp, sp, #64
	b	_mutex_unlock
LBB0_23:
	mov	x0, x20
	str	xzr, [x0], #24
	bl	_drm_dp_cec_unset_edid
LBB0_24:
	ldr	x1, [x20]
	mov	x0, x22
	bl	_amdgpu_dm_update_freesync_caps
	mov	x0, x19
	bl	_mutex_unlock
LBB0_25:
	mov	x0, x21
	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
	add	sp, sp, #64
	b	_dc_sink_release
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_DRM_FORCE_UNSPECIFIED,8,3      ; @DRM_FORCE_UNSPECIFIED
	.comm	_SIGNAL_TYPE_DISPLAY_PORT_MST,8,3 ; @SIGNAL_TYPE_DISPLAY_PORT_MST
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"DCHPD: connector_id=%d: dc_sink didn't change.\n"

l_.str.1:                               ; @.str.1
	.asciz	"DCHPD: connector_id=%d: Old sink=%p New sink=%p\n"

	.no_dead_strip	_amdgpu_dm_update_connector_after_detect
.subsections_via_symbols
