	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ath10k_scan_stop
_ath10k_scan_stop:                      ## @ath10k_scan_stop
	.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, %rbx
	movl	$1, -32(%rbp)
	movq	_ATH10K_SCAN_ID@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -28(%rbp)
	movq	_WMI_SCAN_STOP_ONE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -24(%rbp)
	addq	$24, %rdi
	callq	_lockdep_assert_held
	leaq	-32(%rbp), %rsi
	movq	%rbx, %rdi
	callq	_ath10k_wmi_stop_scan
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	movl	%eax, %r14d
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_ath10k_warn
	jmp	LBB0_5
LBB0_2:
	leaq	16(%rbx), %rdi
	movq	_HZ@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	leal	(%rax,%rax,2), %esi
	callq	_wait_for_completion_timeout
	testl	%eax, %eax
	je	LBB0_3
## %bb.4:
	movl	%eax, %r14d
	sarl	$31, %r14d
	andl	%eax, %r14d
	jmp	LBB0_5
LBB0_3:
	leaq	L_.str.1(%rip), %rsi
	xorl	%r14d, %r14d
	movq	%rbx, %rdi
	xorl	%eax, %eax
	callq	_ath10k_warn
	movq	_ETIMEDOUT@GOTPCREL(%rip), %rax
	subl	(%rax), %r14d
LBB0_5:
	movq	%rbx, %rdi
	callq	_spin_lock_bh
	movq	8(%rbx), %rax
	movq	_ATH10K_SCAN_IDLE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_7
## %bb.6:
	movq	%rbx, %rdi
	callq	___ath10k_scan_finish
LBB0_7:
	movq	%rbx, %rdi
	callq	_spin_unlock_bh
	movl	%r14d, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ATH10K_SCAN_ID,4,2             ## @ATH10K_SCAN_ID
	.comm	_WMI_SCAN_STOP_ONE,4,2          ## @WMI_SCAN_STOP_ONE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"failed to stop wmi scan: %d\n"

	.comm	_HZ,4,2                         ## @HZ
L_.str.1:                               ## @.str.1
	.asciz	"failed to receive scan abortion completion: timed out\n"

	.comm	_ETIMEDOUT,4,2                  ## @ETIMEDOUT
	.comm	_ATH10K_SCAN_IDLE,8,3           ## @ATH10K_SCAN_IDLE
	.no_dead_strip	_ath10k_scan_stop
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ath10k_scan_stop
_ath10k_scan_stop:                      ; @ath10k_scan_stop
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	mov	w8, #1
Lloh0:
	adrp	x9, _ATH10K_SCAN_ID@GOTPAGE
Lloh1:
	ldr	x9, [x9, _ATH10K_SCAN_ID@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	stp	w8, w9, [sp, #16]
Lloh3:
	adrp	x8, _WMI_SCAN_STOP_ONE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _WMI_SCAN_STOP_ONE@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	str	w8, [sp, #24]
	add	x0, x0, #24
	bl	_lockdep_assert_held
	add	x1, sp, #16
	mov	x0, x19
	bl	_ath10k_wmi_stop_scan
	cbz	w0, LBB0_2
; %bb.1:
	mov	x20, x0
	str	x20, [sp]
Lloh6:
	adrp	x1, l_.str@PAGE
Lloh7:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_ath10k_warn
	b	LBB0_5
LBB0_2:
	add	x0, x19, #16
Lloh8:
	adrp	x8, _HZ@GOTPAGE
Lloh9:
	ldr	x8, [x8, _HZ@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	add	w1, w8, w8, lsl #1
	bl	_wait_for_completion_timeout
	cbz	w0, LBB0_4
; %bb.3:
	cmp	w0, #0
	csel	w20, w0, wzr, lt
	b	LBB0_5
LBB0_4:
Lloh11:
	adrp	x1, l_.str.1@PAGE
Lloh12:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_ath10k_warn
Lloh13:
	adrp	x8, _ETIMEDOUT@GOTPAGE
Lloh14:
	ldr	x8, [x8, _ETIMEDOUT@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	neg	w20, w8
LBB0_5:
	mov	x0, x19
	bl	_spin_lock_bh
	ldr	x8, [x19, #8]
Lloh16:
	adrp	x9, _ATH10K_SCAN_IDLE@GOTPAGE
Lloh17:
	ldr	x9, [x9, _ATH10K_SCAN_IDLE@GOTPAGEOFF]
Lloh18:
	ldr	x9, [x9]
	cmp	x8, x9
	b.eq	LBB0_7
; %bb.6:
	mov	x0, x19
	bl	___ath10k_scan_finish
LBB0_7:
	mov	x0, x19
	bl	_spin_unlock_bh
	mov	x0, x20
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_ATH10K_SCAN_ID,4,2             ; @ATH10K_SCAN_ID
	.comm	_WMI_SCAN_STOP_ONE,4,2          ; @WMI_SCAN_STOP_ONE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"failed to stop wmi scan: %d\n"

	.comm	_HZ,4,2                         ; @HZ
l_.str.1:                               ; @.str.1
	.asciz	"failed to receive scan abortion completion: timed out\n"

	.comm	_ETIMEDOUT,4,2                  ; @ETIMEDOUT
	.comm	_ATH10K_SCAN_IDLE,8,3           ; @ATH10K_SCAN_IDLE
	.no_dead_strip	_ath10k_scan_stop
.subsections_via_symbols
