	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cec_pin_to_idle
_cec_pin_to_idle:                       ## @cec_pin_to_idle
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	%rdi, %rbx
	xorps	%xmm0, %xmm0
	movups	%xmm0, 40(%rdi)
	movq	$0, 56(%rdi)
	movl	32(%rdi), %edi
	xorl	%esi, %esi
	movl	$4, %edx
	callq	_memset
	xorl	%edi, %edi
	callq	_ns_to_ktime
	movl	%eax, 24(%rbx)
	movq	$0, (%rbx)
	movq	8(%rbx), %rax
	movq	_CEC_ST_TX_WAIT@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jl	LBB0_3
## %bb.1:
	movq	_CEC_ST_TX_LOW_DRIVE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jg	LBB0_3
## %bb.2:
	xorb	$1, 16(%rbx)
LBB0_3:
	movq	_CEC_ST_RX_START_BIT_LOW@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jl	LBB0_6
## %bb.4:
	movq	_CEC_ST_RX_LOW_DRIVE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jg	LBB0_6
## %bb.5:
	xorb	$1, 20(%rbx)
LBB0_6:
	movq	_CEC_ST_IDLE@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 8(%rbx)
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_CEC_ST_TX_WAIT,8,3             ## @CEC_ST_TX_WAIT
	.comm	_CEC_ST_TX_LOW_DRIVE,8,3        ## @CEC_ST_TX_LOW_DRIVE
	.comm	_CEC_ST_RX_START_BIT_LOW,8,3    ## @CEC_ST_RX_START_BIT_LOW
	.comm	_CEC_ST_RX_LOW_DRIVE,8,3        ## @CEC_ST_RX_LOW_DRIVE
	.comm	_CEC_ST_IDLE,8,3                ## @CEC_ST_IDLE
	.no_dead_strip	_cec_pin_to_idle
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cec_pin_to_idle
_cec_pin_to_idle:                       ; @cec_pin_to_idle
	.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	x19, x0
	stp	xzr, xzr, [x0, #40]
	str	xzr, [x0, #56]
	ldr	w0, [x0, #32]
	mov	w1, #0
	mov	w2, #4
	bl	_memset
	mov	w0, #0
	bl	_ns_to_ktime
	str	w0, [x19, #24]
	str	xzr, [x19]
	ldr	x8, [x19, #8]
Lloh0:
	adrp	x9, _CEC_ST_TX_WAIT@GOTPAGE
Lloh1:
	ldr	x9, [x9, _CEC_ST_TX_WAIT@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
Lloh3:
	adrp	x10, _CEC_ST_TX_LOW_DRIVE@GOTPAGE
Lloh4:
	ldr	x10, [x10, _CEC_ST_TX_LOW_DRIVE@GOTPAGEOFF]
Lloh5:
	ldr	x10, [x10]
	cmp	x8, x9
	ccmp	x8, x10, #0, ge
	b.gt	LBB0_2
; %bb.1:
	ldr	w9, [x19, #16]
	eor	w9, w9, #0x1
	str	w9, [x19, #16]
LBB0_2:
Lloh6:
	adrp	x9, _CEC_ST_RX_START_BIT_LOW@GOTPAGE
Lloh7:
	ldr	x9, [x9, _CEC_ST_RX_START_BIT_LOW@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
Lloh9:
	adrp	x10, _CEC_ST_RX_LOW_DRIVE@GOTPAGE
Lloh10:
	ldr	x10, [x10, _CEC_ST_RX_LOW_DRIVE@GOTPAGEOFF]
Lloh11:
	ldr	x10, [x10]
	cmp	x8, x9
	ccmp	x8, x10, #0, ge
	b.gt	LBB0_4
; %bb.3:
	ldr	w8, [x19, #20]
	eor	w8, w8, #0x1
	str	w8, [x19, #20]
LBB0_4:
Lloh12:
	adrp	x8, _CEC_ST_IDLE@GOTPAGE
Lloh13:
	ldr	x8, [x8, _CEC_ST_IDLE@GOTPAGEOFF]
Lloh14:
	ldr	x8, [x8]
	str	x8, [x19, #8]
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_CEC_ST_TX_WAIT,8,3             ; @CEC_ST_TX_WAIT
	.comm	_CEC_ST_TX_LOW_DRIVE,8,3        ; @CEC_ST_TX_LOW_DRIVE
	.comm	_CEC_ST_RX_START_BIT_LOW,8,3    ; @CEC_ST_RX_START_BIT_LOW
	.comm	_CEC_ST_RX_LOW_DRIVE,8,3        ; @CEC_ST_RX_LOW_DRIVE
	.comm	_CEC_ST_IDLE,8,3                ; @CEC_ST_IDLE
	.no_dead_strip	_cec_pin_to_idle
.subsections_via_symbols
