	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_dc_link_dp_perform_link_training ## -- Begin function dc_link_dp_perform_link_training
	.p2align	4, 0x90
_dc_link_dp_perform_link_training:      ## @dc_link_dp_perform_link_training
	.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
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r15d
	movq	%rdi, %r14
	leaq	8(%rdi), %rdx
	leaq	-40(%rbp), %rbx
	movq	%rbx, %rcx
	callq	_initialize_training_settings
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_dpcd_set_link_settings
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_perform_clock_recovery_sequence
	movl	%eax, %ebx
	movq	_LINK_TRAINING_SUCCESS@GOTPCREL(%rip), %r12
	movl	(%r12), %eax
	cmpl	%eax, %ebx
	jne	LBB0_2
## %bb.1:
	leaq	-40(%rbp), %rsi
	movq	%r14, %rdi
	callq	_perform_channel_equalization_sequence
	movl	%eax, %ebx
	movl	(%r12), %eax
LBB0_2:
	testl	%r15d, %r15d
	je	LBB0_4
## %bb.3:
	cmpl	%eax, %ebx
	jne	LBB0_5
LBB0_4:
	leaq	-40(%rbp), %rsi
	movq	%r14, %rdi
	movl	%ebx, %edx
	callq	_perform_link_training_int
	movl	%eax, %ebx
LBB0_5:
	leaq	-40(%rbp), %rsi
	movq	%r14, %rdi
	movl	%ebx, %edx
	callq	_print_status_message
	cmpl	(%r12), %ebx
	je	LBB0_7
## %bb.6:
	movq	(%r14), %rax
	movq	(%rax), %rax
	incl	(%rax)
LBB0_7:
	movl	%ebx, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_LINK_TRAINING_SUCCESS,4,2      ## @LINK_TRAINING_SUCCESS
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_dc_link_dp_perform_link_training ; -- Begin function dc_link_dp_perform_link_training
	.p2align	2
_dc_link_dp_perform_link_training:      ; @dc_link_dp_perform_link_training
	.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
	mov	x21, x2
	mov	x19, x0
	add	x2, x0, #8
	add	x3, sp, #8
	bl	_initialize_training_settings
	add	x1, sp, #8
	mov	x0, x19
	bl	_dpcd_set_link_settings
	add	x1, sp, #8
	mov	x0, x19
	bl	_perform_clock_recovery_sequence
Lloh0:
	adrp	x22, _LINK_TRAINING_SUCCESS@GOTPAGE
Lloh1:
	ldr	x22, [x22, _LINK_TRAINING_SUCCESS@GOTPAGEOFF]
	ldr	w8, [x22]
	cmp	w0, w8
	b.ne	LBB0_2
; %bb.1:
	add	x1, sp, #8
	mov	x0, x19
	bl	_perform_channel_equalization_sequence
	mov	x20, x0
	ldr	w8, [x22]
	cbnz	w21, LBB0_3
	b	LBB0_4
LBB0_2:
	mov	x20, x0
	cbz	w21, LBB0_4
LBB0_3:
	cmp	w20, w8
	b.ne	LBB0_5
LBB0_4:
	add	x1, sp, #8
	mov	x0, x19
	mov	x2, x20
	bl	_perform_link_training_int
	mov	x20, x0
LBB0_5:
	add	x1, sp, #8
	mov	x0, x19
	mov	x2, x20
	bl	_print_status_message
	ldr	w8, [x22]
	cmp	w20, w8
	b.eq	LBB0_7
; %bb.6:
	ldr	x8, [x19]
	ldr	x8, [x8]
	ldr	w9, [x8]
	add	w9, w9, #1
	str	w9, [x8]
LBB0_7:
	mov	x0, x20
	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
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_LINK_TRAINING_SUCCESS,4,2      ; @LINK_TRAINING_SUCCESS
.subsections_via_symbols
