	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mei_txe_readiness_wait
_mei_txe_readiness_wait:                ## @mei_txe_readiness_wait
	.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	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	callq	_mei_txe_hw_is_ready
	xorl	%r14d, %r14d
	testq	%rax, %rax
	jne	LBB0_4
## %bb.1:
	leaq	8(%rbx), %r15
	movq	%r15, %rdi
	callq	_mutex_unlock
	movl	(%rbx), %r12d
	movl	12(%rbx), %r13d
	movq	_SEC_RESET_WAIT_TIMEOUT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_msecs_to_jiffies
	movl	%r13d, %edi
	movl	%r12d, %esi
	movl	%eax, %edx
	callq	_wait_event_timeout
	movq	%r15, %rdi
	callq	_mutex_lock
	cmpl	$0, (%rbx)
	je	LBB0_2
## %bb.3:
	movl	$0, (%rbx)
	jmp	LBB0_4
LBB0_2:
	movl	4(%rbx), %edi
	leaq	L_.str(%rip), %rsi
	callq	_dev_err
	movq	_ETIME@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
LBB0_4:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SEC_RESET_WAIT_TIMEOUT,4,2     ## @SEC_RESET_WAIT_TIMEOUT
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"wait for readiness failed\n"

	.comm	_ETIME,4,2                      ## @ETIME
	.no_dead_strip	_mei_txe_readiness_wait
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mei_txe_readiness_wait
_mei_txe_readiness_wait:                ; @mei_txe_readiness_wait
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x19, x0
	bl	_mei_txe_hw_is_ready
	cbz	x0, LBB0_2
; %bb.1:
	mov	w0, #0
	b	LBB0_5
LBB0_2:
	add	x20, x19, #8
	mov	x0, x20
	bl	_mutex_unlock
	ldr	w21, [x19, #12]
	ldr	w22, [x19]
Lloh0:
	adrp	x8, _SEC_RESET_WAIT_TIMEOUT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SEC_RESET_WAIT_TIMEOUT@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_msecs_to_jiffies
	mov	x2, x0
	mov	x0, x21
	mov	x1, x22
	bl	_wait_event_timeout
	mov	x0, x20
	bl	_mutex_lock
	ldr	w8, [x19]
	cbz	w8, LBB0_4
; %bb.3:
	mov	w0, #0
	str	wzr, [x19]
	b	LBB0_5
LBB0_4:
	ldr	w0, [x19, #4]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err
Lloh5:
	adrp	x8, _ETIME@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ETIME@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_5:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_SEC_RESET_WAIT_TIMEOUT,4,2     ; @SEC_RESET_WAIT_TIMEOUT
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"wait for readiness failed\n"

	.comm	_ETIME,4,2                      ; @ETIME
	.no_dead_strip	_mei_txe_readiness_wait
.subsections_via_symbols
