	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_il_mac_hw_scan                 ## -- Begin function il_mac_hw_scan
	.p2align	4, 0x90
_il_mac_hw_scan:                        ## @il_mac_hw_scan
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	cmpq	$0, (%rdx)
	je	LBB0_1
## %bb.2:
	movq	%rdx, %r12
	movq	%rsi, %r15
	movq	(%rdi), %r14
	movq	%r14, %rdi
	callq	_mutex_lock
	leaq	L_.str.1(%rip), %rdi
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_D_MAC80211
	movq	_S_SCANNING@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	24(%r14), %rsi
	callq	_test_bit
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	leaq	L_.str.2(%rip), %rdi
	callq	_D_SCAN
	movq	_EAGAIN@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
	jmp	LBB0_5
LBB0_1:
	leaq	L_.str(%rip), %rdi
	callq	_IL_ERR
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_6
LBB0_4:
	movq	%r12, 16(%r14)
	movq	%r15, 8(%r14)
	movq	8(%r12), %rax
	movq	(%rax), %rax
	movl	(%rax), %eax
	movl	%eax, 4(%r14)
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_il_scan_initiate
	movl	%eax, %ebx
LBB0_5:
	leaq	L_.str.3(%rip), %rdi
	movl	%ebx, %esi
	xorl	%eax, %eax
	callq	_D_MAC80211
	movq	%r14, %rdi
	callq	_mutex_unlock
LBB0_6:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Can not scan on no channels.\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
L_.str.1:                               ## @.str.1
	.asciz	"enter\n"

	.comm	_S_SCANNING,4,2                 ## @S_SCANNING
L_.str.2:                               ## @.str.2
	.asciz	"Scan already in progress.\n"

	.comm	_EAGAIN,4,2                     ## @EAGAIN
L_.str.3:                               ## @.str.3
	.asciz	"leave ret %d\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_il_mac_hw_scan                 ; -- Begin function il_mac_hw_scan
	.p2align	2
_il_mac_hw_scan:                        ; @il_mac_hw_scan
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	ldr	x8, [x2]
	cbz	x8, LBB0_3
; %bb.1:
	mov	x21, x2
	mov	x20, x1
	ldr	x19, [x0]
	mov	x0, x19
	bl	_mutex_lock
Lloh0:
	adrp	x0, l_.str.1@PAGE
Lloh1:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_D_MAC80211
Lloh2:
	adrp	x8, _S_SCANNING@GOTPAGE
Lloh3:
	ldr	x8, [x8, _S_SCANNING@GOTPAGEOFF]
Lloh4:
	ldr	w0, [x8]
	add	x1, x19, #24
	bl	_test_bit
	cbz	x0, LBB0_4
; %bb.2:
Lloh5:
	adrp	x0, l_.str.2@PAGE
Lloh6:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_D_SCAN
Lloh7:
	adrp	x8, _EAGAIN@GOTPAGE
Lloh8:
	ldr	x8, [x8, _EAGAIN@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
	neg	w20, w8
	b	LBB0_5
LBB0_3:
Lloh10:
	adrp	x0, l_.str@PAGE
Lloh11:
	add	x0, x0, l_.str@PAGEOFF
	bl	_IL_ERR
Lloh12:
	adrp	x8, _EINVAL@GOTPAGE
Lloh13:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	neg	w20, w8
	b	LBB0_6
LBB0_4:
	stp	x20, x21, [x19, #8]
	ldr	x8, [x21, #8]
	ldr	x8, [x8]
	ldr	w8, [x8]
	str	w8, [x19, #4]
	mov	x0, x19
	mov	x1, x20
	bl	_il_scan_initiate
	mov	x20, x0
LBB0_5:
	str	x20, [sp]
Lloh15:
	adrp	x0, l_.str.3@PAGE
Lloh16:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_D_MAC80211
	mov	x0, x19
	bl	_mutex_unlock
LBB0_6:
	mov	x0, x20
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Can not scan on no channels.\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
l_.str.1:                               ; @.str.1
	.asciz	"enter\n"

	.comm	_S_SCANNING,4,2                 ; @S_SCANNING
l_.str.2:                               ; @.str.2
	.asciz	"Scan already in progress.\n"

	.comm	_EAGAIN,4,2                     ; @EAGAIN
l_.str.3:                               ; @.str.3
	.asciz	"leave ret %d\n"

.subsections_via_symbols
