	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_prism2_ap_get_sta_qual         ## -- Begin function prism2_ap_get_sta_qual
	.p2align	4, 0x90
_prism2_ap_get_sta_qual:                ## @prism2_ap_get_sta_qual
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r8d, -48(%rbp)                 ## 4-byte Spill
	movl	%ecx, -44(%rbp)                 ## 4-byte Spill
	movq	%rdx, %r13
	movq	%rsi, %r14
	movq	(%rdi), %r15
	movq	%r15, %rdi
	callq	_spin_lock_bh
	movq	8(%r15), %r12
	xorl	%ebx, %ebx
	testq	%r12, %r12
	je	LBB0_12
## %bb.1:
	leaq	8(%r15), %rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	cmpq	%rax, %r12
	je	LBB0_12
## %bb.2:
	xorl	%ebx, %ebx
	movq	%r15, -56(%rbp)                 ## 8-byte Spill
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	cmpl	$0, -48(%rbp)                   ## 4-byte Folded Reload
	je	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	cmpl	$0, 16(%r12)
	je	LBB0_10
LBB0_5:                                 ##   in Loop: Header=BB0_3 Depth=1
	movq	_ARPHRD_ETHER@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movslq	%ebx, %rbx
	movl	%eax, 4(%r14,%rbx,8)
	movl	(%r14,%rbx,8), %edi
	movl	12(%r12), %esi
	movq	_ETH_ALEN@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_memcpy
	movl	(%r12), %ecx
	movl	4(%r12), %edi
	testl	%ecx, %ecx
	je	LBB0_6
## %bb.8:                               ##   in Loop: Header=BB0_3 Depth=1
	movl	%edi, %eax
	subl	%ecx, %eax
	addl	$-35, %eax
	jmp	LBB0_9
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_3 Depth=1
	xorl	%eax, %eax
	cmpl	$27, %edi
	jl	LBB0_9
## %bb.7:                               ##   in Loop: Header=BB0_3 Depth=1
	imull	$92, %edi, %eax
	movl	%eax, %ecx
	addl	$-2484, %ecx                    ## imm = 0xF64C
	movslq	%ecx, %rcx
	imulq	$-2130574327, %rcx, %rcx        ## imm = 0x81020409
	shrq	$32, %rcx
	addl	%ecx, %eax
	addl	$-2484, %eax                    ## imm = 0xF64C
	movl	%eax, %ecx
	shrl	$31, %ecx
	sarl	$6, %eax
	addl	%ecx, %eax
	.p2align	4, 0x90
LBB0_9:                                 ##   in Loop: Header=BB0_3 Depth=1
	leaq	(%rbx,%rbx,2), %r15
	movl	%eax, (%r13,%r15,8)
	callq	_HFA384X_LEVEL_TO_dBm
	movq	%rax, 16(%r13,%r15,8)
	movl	(%r12), %edi
	callq	_HFA384X_LEVEL_TO_dBm
	movq	%rax, 8(%r13,%r15,8)
	movl	8(%r12), %eax
	movl	%eax, 4(%r13,%r15,8)
	movq	_IW_QUAL_DBM@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 8(%r12)
	incl	%ebx
	cmpl	-44(%rbp), %ebx                 ## 4-byte Folded Reload
	movq	-56(%rbp), %r15                 ## 8-byte Reload
	jge	LBB0_12
LBB0_10:                                ##   in Loop: Header=BB0_3 Depth=1
	movq	(%r12), %r12
	testq	%r12, %r12
	je	LBB0_12
## %bb.11:                              ##   in Loop: Header=BB0_3 Depth=1
	cmpq	-64(%rbp), %r12                 ## 8-byte Folded Reload
	jne	LBB0_3
LBB0_12:
	movq	%r15, %rdi
	callq	_spin_unlock_bh
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ARPHRD_ETHER,4,2               ## @ARPHRD_ETHER
	.comm	_ETH_ALEN,4,2                   ## @ETH_ALEN
	.comm	_IW_QUAL_DBM,4,2                ## @IW_QUAL_DBM
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_prism2_ap_get_sta_qual         ; -- Begin function prism2_ap_get_sta_qual
	.p2align	2
_prism2_ap_get_sta_qual:                ; @prism2_ap_get_sta_qual
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x20, x4
	mov	x21, x3
	mov	x22, x2
	mov	x23, x1
	ldr	x25, [x0]
	mov	x0, x25
	bl	_spin_lock_bh
	str	x25, [sp, #8]                   ; 8-byte Folded Spill
	ldr	x26, [x25, #8]!
	cmp	x26, #0
	mov	w24, #0
	ccmp	x26, x25, #4, ne
	b.ne	LBB0_2
LBB0_1:
	ldr	x0, [sp, #8]                    ; 8-byte Folded Reload
	bl	_spin_unlock_bh
	mov	x0, x24
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_2:
	mov	w19, #24
Lloh0:
	adrp	x27, _IW_QUAL_DBM@GOTPAGE
Lloh1:
	ldr	x27, [x27, _IW_QUAL_DBM@GOTPAGEOFF]
	b	LBB0_6
LBB0_3:                                 ;   in Loop: Header=BB0_6 Depth=1
	sub	w8, w0, w8
	sub	w8, w8, #35
LBB0_4:                                 ;   in Loop: Header=BB0_6 Depth=1
	sxtw	x9, w24
	madd	x28, x9, x19, x22
	str	w8, [x28]
	bl	_HFA384X_LEVEL_TO_dBm
	str	x0, [x28, #16]
	ldr	w0, [x26]
	bl	_HFA384X_LEVEL_TO_dBm
	str	x0, [x28, #8]
	ldr	w8, [x26, #8]
	str	w8, [x28, #4]
	ldr	w8, [x27]
	str	w8, [x26, #8]
	add	w24, w24, #1
	cmp	w24, w21
	b.ge	LBB0_1
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	ldr	x26, [x26]
	cmp	x26, #0
	ccmp	x26, x25, #4, ne
	b.eq	LBB0_1
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	cbz	w20, LBB0_8
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	w8, [x26, #16]
	cbz	w8, LBB0_5
LBB0_8:                                 ;   in Loop: Header=BB0_6 Depth=1
Lloh2:
	adrp	x8, _ARPHRD_ETHER@GOTPAGE
Lloh3:
	ldr	x8, [x8, _ARPHRD_ETHER@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	add	x9, x23, w24, sxtw #3
	str	w8, [x9, #4]
	ldr	w0, [x9]
	ldr	w1, [x26, #12]
Lloh5:
	adrp	x8, _ETH_ALEN@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ETH_ALEN@GOTPAGEOFF]
Lloh7:
	ldr	w2, [x8]
	bl	_memcpy
	ldp	w8, w0, [x26]
	cbnz	w8, LBB0_3
; %bb.9:                                ;   in Loop: Header=BB0_6 Depth=1
	cmp	w0, #27
	b.ge	LBB0_11
; %bb.10:                               ;   in Loop: Header=BB0_6 Depth=1
	mov	w8, #0
	b	LBB0_4
LBB0_11:                                ;   in Loop: Header=BB0_6 Depth=1
	mov	w8, #92
	mul	w8, w0, w8
	sub	w8, w8, #2484
	mov	w9, #1033
	movk	w9, #33026, lsl #16
	smull	x9, w8, w9
	lsr	x9, x9, #32
	add	w8, w9, w8
	asr	w9, w8, #6
	add	w8, w9, w8, lsr #31
	b	LBB0_4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_ARPHRD_ETHER,4,2               ; @ARPHRD_ETHER
	.comm	_ETH_ALEN,4,2                   ; @ETH_ALEN
	.comm	_IW_QUAL_DBM,4,2                ; @IW_QUAL_DBM
.subsections_via_symbols
