	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function analogix_dp_fast_link_train_detection
_analogix_dp_fast_link_train_detection: ## @analogix_dp_fast_link_train_detection
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %r14
	addq	$8, %rdi
	movq	_DP_MAX_DOWNSPREAD@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-20(%rbp), %rdx
	callq	_drm_dp_dpcd_readb
	cmpl	$1, %eax
	jne	LBB0_1
## %bb.2:
	movq	_DP_NO_AUX_HANDSHAKE_LINK_TRAINING@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	xorl	%ecx, %ecx
	andl	-20(%rbp), %eax
	setne	%cl
	movl	%ecx, (%r14)
	movl	4(%r14), %edi
	leaq	L_.str.2(%rip), %rax
	leaq	L_.str.3(%rip), %rdx
	cmovneq	%rax, %rdx
	leaq	L_.str.1(%rip), %rsi
	callq	_dev_dbg
	xorl	%ebx, %ebx
	jmp	LBB0_3
LBB0_1:
	movl	%eax, %ebx
	movl	4(%r14), %edi
	leaq	L_.str(%rip), %rsi
	movl	%eax, %edx
	callq	_dev_err
LBB0_3:
	movl	%ebx, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_DP_MAX_DOWNSPREAD,4,2          ## @DP_MAX_DOWNSPREAD
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"failed to read downspread %d\n"

	.comm	_DP_NO_AUX_HANDSHAKE_LINK_TRAINING,4,2 ## @DP_NO_AUX_HANDSHAKE_LINK_TRAINING
L_.str.1:                               ## @.str.1
	.asciz	"fast link training %s\n"

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

L_.str.3:                               ## @.str.3
	.asciz	"unsupported"

	.no_dead_strip	_analogix_dp_fast_link_train_detection
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function analogix_dp_fast_link_train_detection
_analogix_dp_fast_link_train_detection: ; @analogix_dp_fast_link_train_detection
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	mov	x19, x0
	add	x0, x0, #8
Lloh0:
	adrp	x8, _DP_MAX_DOWNSPREAD@GOTPAGE
Lloh1:
	ldr	x8, [x8, _DP_MAX_DOWNSPREAD@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	add	x2, sp, #12
	bl	_drm_dp_dpcd_readb
	cmp	w0, #1
	b.ne	LBB0_2
; %bb.1:
	ldr	w8, [sp, #12]
Lloh3:
	adrp	x9, _DP_NO_AUX_HANDSHAKE_LINK_TRAINING@GOTPAGE
Lloh4:
	ldr	x9, [x9, _DP_NO_AUX_HANDSHAKE_LINK_TRAINING@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	tst	w9, w8
	cset	w8, ne
	str	w8, [x19]
	ldr	w0, [x19, #4]
Lloh6:
	adrp	x8, l_.str.3@PAGE
Lloh7:
	add	x8, x8, l_.str.3@PAGEOFF
Lloh8:
	adrp	x9, l_.str.2@PAGE
Lloh9:
	add	x9, x9, l_.str.2@PAGEOFF
	csel	x2, x9, x8, ne
Lloh10:
	adrp	x1, l_.str.1@PAGE
Lloh11:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_dev_dbg
	mov	w20, #0
	b	LBB0_3
LBB0_2:
	mov	x20, x0
	ldr	w0, [x19, #4]
Lloh12:
	adrp	x1, l_.str@PAGE
Lloh13:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x20
	bl	_dev_err
LBB0_3:
	mov	x0, x20
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_DP_MAX_DOWNSPREAD,4,2          ; @DP_MAX_DOWNSPREAD
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"failed to read downspread %d\n"

	.comm	_DP_NO_AUX_HANDSHAKE_LINK_TRAINING,4,2 ; @DP_NO_AUX_HANDSHAKE_LINK_TRAINING
l_.str.1:                               ; @.str.1
	.asciz	"fast link training %s\n"

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

l_.str.3:                               ; @.str.3
	.asciz	"unsupported"

	.no_dead_strip	_analogix_dp_fast_link_train_detection
.subsections_via_symbols
