	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ar9002_hw_load_ani_reg         ## -- Begin function ar9002_hw_load_ani_reg
	.p2align	4, 0x90
_ar9002_hw_load_ani_reg:                ## @ar9002_hw_load_ani_reg
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	movq	%rdi, %r15
	movq	%rsi, %rdi
	callq	_IS_CHAN_5GHZ
	movq	%rax, %r12
	movq	%rbx, %rdi
	callq	_IS_CHAN_HT40
	xorl	%r14d, %r14d
	testq	%rax, %rax
	sete	%r14b
	movl	$2, %eax
	subq	%r14, %rax
	addq	$3, %r14
	testq	%r12, %r12
	cmovneq	%rax, %r14
	movq	%r15, %rdi
	callq	_ENABLE_REGWRITE_BUFFER
	cmpl	$0, (%r15)
	jle	LBB0_5
## %bb.1:
	xorl	%ebx, %ebx
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_4:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	%r15, %rdi
	movq	%r12, %rsi
	movq	%r13, %rdx
	callq	_REG_WRITE
	incl	%ebx
	cmpl	(%r15), %ebx
	jge	LBB0_5
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r15, %rdi
	movl	%ebx, %esi
	xorl	%edx, %edx
	callq	_INI_RA
	movq	%rax, %r12
	movq	%r15, %rdi
	movl	%ebx, %esi
	movq	%r14, %rdx
	callq	_INI_RA
	movq	%rax, %r13
	movq	_AR_PHY_CCK_DETECT@GOTPCREL(%rip), %rax
	cmpq	(%rax), %r12
	jne	LBB0_4
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_REG_READ
	xorq	%rax, %r13
	movq	_AR_PHY_CCK_DETECT_WEAK_SIG_THR_CCK@GOTPCREL(%rip), %rcx
	andq	(%rcx), %r13
	xorq	%rax, %r13
	jmp	LBB0_4
LBB0_5:
	movq	%r15, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_REGWRITE_BUFFER_FLUSH          ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_AR_PHY_CCK_DETECT,8,3          ## @AR_PHY_CCK_DETECT
	.comm	_AR_PHY_CCK_DETECT_WEAK_SIG_THR_CCK,8,3 ## @AR_PHY_CCK_DETECT_WEAK_SIG_THR_CCK
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ar9002_hw_load_ani_reg         ; -- Begin function ar9002_hw_load_ani_reg
	.p2align	2
_ar9002_hw_load_ani_reg:                ; @ar9002_hw_load_ani_reg
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x20, x1
	mov	x19, x0
	mov	x0, x1
	bl	_IS_CHAN_5GHZ
	mov	x21, x0
	mov	x0, x20
	bl	_IS_CHAN_HT40
	cmp	x0, #0
	mov	w8, #1
	cinc	x8, x8, ne
	mov	w9, #3
	cinc	x9, x9, eq
	cmp	x21, #0
	csel	x20, x9, x8, eq
	mov	x0, x19
	bl	_ENABLE_REGWRITE_BUFFER
	ldr	w8, [x19]
	cmp	w8, #1
	b.lt	LBB0_5
; %bb.1:
	mov	w21, #0
Lloh0:
	adrp	x24, _AR_PHY_CCK_DETECT@GOTPAGE
Lloh1:
	ldr	x24, [x24, _AR_PHY_CCK_DETECT@GOTPAGEOFF]
Lloh2:
	adrp	x25, _AR_PHY_CCK_DETECT_WEAK_SIG_THR_CCK@GOTPAGE
Lloh3:
	ldr	x25, [x25, _AR_PHY_CCK_DETECT_WEAK_SIG_THR_CCK@GOTPAGEOFF]
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	mov	x0, x19
	mov	x1, x22
	mov	x2, x23
	bl	_REG_WRITE
	add	w21, w21, #1
	ldr	w8, [x19]
	cmp	w21, w8
	b.ge	LBB0_5
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	mov	x1, x21
	mov	x2, #0
	bl	_INI_RA
	mov	x22, x0
	mov	x0, x19
	mov	x1, x21
	mov	x2, x20
	bl	_INI_RA
	mov	x23, x0
	ldr	x8, [x24]
	cmp	x22, x8
	b.ne	LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x0, x19
	mov	x1, x22
	bl	_REG_READ
	ldr	x8, [x25]
	and	x9, x8, x23
	bic	x8, x0, x8
	orr	x23, x9, x8
	b	LBB0_2
LBB0_5:
	mov	x0, x19
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_REGWRITE_BUFFER_FLUSH
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_AR_PHY_CCK_DETECT,8,3          ; @AR_PHY_CCK_DETECT
	.comm	_AR_PHY_CCK_DETECT_WEAK_SIG_THR_CCK,8,3 ; @AR_PHY_CCK_DETECT_WEAK_SIG_THR_CCK
.subsections_via_symbols
