	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ath10k_wmi_barrier             ## -- Begin function ath10k_wmi_barrier
	.p2align	4, 0x90
_ath10k_wmi_barrier:                    ## @ath10k_wmi_barrier
	.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, %r14
	leaq	4(%rdi), %rbx
	movq	%rbx, %rdi
	callq	_spin_lock_bh
	movq	%r14, %rdi
	callq	_reinit_completion
	movq	%rbx, %rdi
	callq	_spin_unlock_bh
	movq	_ATH10K_WMI_BARRIER_ECHO_ID@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_ath10k_wmi_echo
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	movl	%eax, %ebx
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	movl	%eax, %edx
	callq	_ath10k_warn
	jmp	LBB0_4
LBB0_2:
	movq	_ATH10K_WMI_BARRIER_TIMEOUT_HZ@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_wait_for_completion_timeout
	xorl	%ebx, %ebx
	testl	%eax, %eax
	jne	LBB0_4
## %bb.3:
	movq	_ETIMEDOUT@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_4:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ATH10K_WMI_BARRIER_ECHO_ID,4,2 ## @ATH10K_WMI_BARRIER_ECHO_ID
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"failed to submit wmi echo: %d\n"

	.comm	_ATH10K_WMI_BARRIER_TIMEOUT_HZ,4,2 ## @ATH10K_WMI_BARRIER_TIMEOUT_HZ
	.comm	_ETIMEDOUT,4,2                  ## @ETIMEDOUT
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ath10k_wmi_barrier             ; -- Begin function ath10k_wmi_barrier
	.p2align	2
_ath10k_wmi_barrier:                    ; @ath10k_wmi_barrier
	.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
	add	x20, x0, #4
	mov	x0, x20
	bl	_spin_lock_bh
	mov	x0, x19
	bl	_reinit_completion
	mov	x0, x20
	bl	_spin_unlock_bh
Lloh0:
	adrp	x8, _ATH10K_WMI_BARRIER_ECHO_ID@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ATH10K_WMI_BARRIER_ECHO_ID@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_ath10k_wmi_echo
	cbz	w0, LBB0_2
; %bb.1:
	mov	x20, x0
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	mov	x2, x20
	bl	_ath10k_warn
	b	LBB0_5
LBB0_2:
Lloh5:
	adrp	x8, _ATH10K_WMI_BARRIER_TIMEOUT_HZ@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ATH10K_WMI_BARRIER_TIMEOUT_HZ@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_wait_for_completion_timeout
	cbz	w0, LBB0_4
; %bb.3:
	mov	w20, #0
	b	LBB0_5
LBB0_4:
Lloh8:
	adrp	x8, _ETIMEDOUT@GOTPAGE
Lloh9:
	ldr	x8, [x8, _ETIMEDOUT@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	neg	w20, w8
LBB0_5:
	mov	x0, x20
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_ATH10K_WMI_BARRIER_ECHO_ID,4,2 ; @ATH10K_WMI_BARRIER_ECHO_ID
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"failed to submit wmi echo: %d\n"

	.comm	_ATH10K_WMI_BARRIER_TIMEOUT_HZ,4,2 ; @ATH10K_WMI_BARRIER_TIMEOUT_HZ
	.comm	_ETIMEDOUT,4,2                  ; @ETIMEDOUT
.subsections_via_symbols
