	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function intel_tc_port_get_current_mode
_intel_tc_port_get_current_mode:        ## @intel_tc_port_get_current_mode
	.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
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	callq	_tc_port_live_status_mask
	movq	%rax, %r14
	movq	%rbx, %rdi
	callq	_icl_tc_phy_is_in_safe_mode
	testl	%eax, %eax
	jne	LBB0_2
## %bb.1:
	movq	%rbx, %rdi
	callq	_icl_tc_phy_status_complete
	xorl	%edi, %edi
	testl	%eax, %eax
	sete	%dil
	callq	_WARN_ON
	testq	%rax, %rax
	je	LBB0_3
LBB0_2:
	movq	_TC_PORT_TBT_ALT@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
LBB0_8:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_3:
	cmpq	$0, (%rbx)
	jne	LBB0_4
## %bb.5:
	movq	_TC_PORT_DP_ALT@GOTPCREL(%rip), %rax
	jmp	LBB0_6
LBB0_4:
	movq	_TC_PORT_LEGACY@GOTPCREL(%rip), %rax
LBB0_6:
	movl	(%rax), %ebx
	testq	%r14, %r14
	je	LBB0_8
## %bb.7:
	movq	%r14, %rdi
	callq	_fls
	movl	%eax, %r14d
	decl	%r14d
	movq	_TC_PORT_TBT_ALT@GOTPCREL(%rip), %rax
	xorl	%edi, %edi
	cmpl	(%rax), %r14d
	sete	%dil
	callq	_WARN_ON
	testq	%rax, %rax
	cmovel	%r14d, %ebx
	jmp	LBB0_8
	.cfi_endproc
                                        ## -- End function
	.comm	_TC_PORT_TBT_ALT,4,2            ## @TC_PORT_TBT_ALT
	.comm	_TC_PORT_LEGACY,4,2             ## @TC_PORT_LEGACY
	.comm	_TC_PORT_DP_ALT,4,2             ## @TC_PORT_DP_ALT
	.no_dead_strip	_intel_tc_port_get_current_mode
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function intel_tc_port_get_current_mode
_intel_tc_port_get_current_mode:        ; @intel_tc_port_get_current_mode
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x20, x0
	bl	_tc_port_live_status_mask
	mov	x19, x0
	mov	x0, x20
	bl	_icl_tc_phy_is_in_safe_mode
	cbnz	w0, LBB0_2
; %bb.1:
	mov	x0, x20
	bl	_icl_tc_phy_status_complete
	cmp	w0, #0
	cset	w0, eq
	bl	_WARN_ON
	cbz	x0, LBB0_4
LBB0_2:
Lloh0:
	adrp	x8, _TC_PORT_TBT_ALT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _TC_PORT_TBT_ALT@GOTPAGEOFF]
Lloh2:
	ldr	w20, [x8]
LBB0_3:
	mov	x0, x20
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
LBB0_4:
Lloh3:
	adrp	x8, _TC_PORT_LEGACY@GOTPAGE
Lloh4:
	ldr	x8, [x8, _TC_PORT_LEGACY@GOTPAGEOFF]
	ldr	x9, [x20]
Lloh5:
	adrp	x10, _TC_PORT_DP_ALT@GOTPAGE
Lloh6:
	ldr	x10, [x10, _TC_PORT_DP_ALT@GOTPAGEOFF]
	cmp	x9, #0
	csel	x8, x10, x8, eq
	ldr	w20, [x8]
	cbz	x19, LBB0_3
; %bb.5:
	mov	x0, x19
	bl	_fls
	sub	w19, w0, #1
Lloh7:
	adrp	x8, _TC_PORT_TBT_ALT@GOTPAGE
Lloh8:
	ldr	x8, [x8, _TC_PORT_TBT_ALT@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
	cmp	w19, w8
	cset	w0, eq
	bl	_WARN_ON
	cmp	x0, #0
	csel	w20, w19, w20, eq
	b	LBB0_3
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_TC_PORT_TBT_ALT,4,2            ; @TC_PORT_TBT_ALT
	.comm	_TC_PORT_LEGACY,4,2             ; @TC_PORT_LEGACY
	.comm	_TC_PORT_DP_ALT,4,2             ; @TC_PORT_DP_ALT
	.no_dead_strip	_intel_tc_port_get_current_mode
.subsections_via_symbols
