	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bgscan_learn_get_probe_freq
_bgscan_learn_get_probe_freq:           ## @bgscan_learn_get_probe_freq
	.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
	movq	%rsi, %r15
	movq	(%rdi), %rax
	testq	%rax, %rax
	je	LBB0_6
## %bb.1:
	movq	%rdx, %r14
	movq	%rdi, %r12
	movl	8(%rdi), %ecx
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movslq	%ecx, %rbx
	movl	(%rax,%rbx,4), %esi
	movq	%r15, %rdi
	callq	_in_array
	testl	%eax, %eax
	je	LBB0_3
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	leal	1(%rbx), %ecx
	movq	(%r12), %rax
	movl	4(%rax,%rbx,4), %edx
	testl	%edx, %edx
	cmovel	%edx, %ecx
	cmpl	8(%r12), %ecx
	jne	LBB0_2
	jmp	LBB0_6
LBB0_3:
	movq	_MSG_DEBUG@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	(%r12), %rax
	movl	(%rax,%rbx,4), %edx
	leaq	L_.str(%rip), %rsi
	callq	_wpa_printf
	leal	1(%rbx), %eax
	movl	%eax, 8(%r12)
	movq	(%r12), %rcx
	movl	4(%rcx,%rbx,4), %ecx
	testl	%ecx, %ecx
	cmovel	%ecx, %eax
	movl	%eax, 8(%r12)
	leaq	2(%r14), %rsi
	movq	%r15, %rdi
	movl	$4, %edx
	callq	_os_realloc_array
	testq	%rax, %rax
	je	LBB0_6
## %bb.4:
	movq	(%r12), %rcx
	movl	(%rcx,%rbx,4), %ecx
	movl	%ecx, (%rax,%r14,4)
	movl	$0, 4(%rax,%r14,4)
	movq	%rax, %r15
LBB0_6:
	movq	%r15, %rax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MSG_DEBUG,4,2                  ## @MSG_DEBUG
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"bgscan learn: Probe new freq %u"

	.no_dead_strip	_bgscan_learn_get_probe_freq
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bgscan_learn_get_probe_freq
_bgscan_learn_get_probe_freq:           ; @bgscan_learn_get_probe_freq
	.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, x1
	ldr	x8, [x0]
	cbz	x8, LBB0_6
; %bb.1:
	mov	x20, x2
	mov	x21, x0
	ldr	w9, [x0, #8]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	sxtw	x22, w9
	ldr	w1, [x8, w9, sxtw #2]
	mov	x0, x19
	bl	_in_array
	cbz	w0, LBB0_4
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	add	x9, x22, #1
	ldr	x8, [x21]
	ldr	w10, [x8, x9, lsl #2]
	cmp	w10, #0
	csel	w9, wzr, w9, eq
	ldr	w10, [x21, #8]
	cmp	w9, w10
	b.ne	LBB0_2
	b	LBB0_6
LBB0_4:
Lloh0:
	adrp	x8, _MSG_DEBUG@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MSG_DEBUG@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	ldr	x8, [x21]
	ldr	w2, [x8, x22, lsl #2]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	bl	_wpa_printf
	add	w8, w22, #1
	str	w8, [x21, #8]
	ldr	x9, [x21]
	ldr	w8, [x9, w8, sxtw #2]
	cmp	w8, #0
	csinc	w8, wzr, w22, eq
	str	w8, [x21, #8]
	add	x1, x20, #2
	mov	x0, x19
	mov	w2, #4
	bl	_os_realloc_array
	cbz	x0, LBB0_6
; %bb.5:
	ldr	x8, [x21]
	ldr	w8, [x8, x22, lsl #2]
	add	x9, x0, x20, lsl #2
	stp	w8, wzr, [x9]
	mov	x19, x0
LBB0_6:
	mov	x0, x19
	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 AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_MSG_DEBUG,4,2                  ; @MSG_DEBUG
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"bgscan learn: Probe new freq %u"

	.no_dead_strip	_bgscan_learn_get_probe_freq
.subsections_via_symbols
