	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ar9002_hw_rf_claim             ## -- Begin function ar9002_hw_rf_claim
	.p2align	4, 0x90
_ar9002_hw_rf_claim:                    ## @ar9002_hw_rf_claim
	.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	%rdi, %rbx
	xorl	%r14d, %r14d
	xorl	%edi, %edi
	callq	_AR_PHY
	movq	%rbx, %rdi
	movl	%eax, %esi
	movl	$7, %edx
	callq	_REG_WRITE
	movq	%rbx, %rdi
	callq	_ar9002_hw_get_radiorev
	movl	%eax, %r15d
	movq	_AR_RADIO_SREV_MAJOR@GOTPCREL(%rip), %r12
	andl	(%r12), %eax
	leal	-128(%rax), %ecx
	cmpl	$4, %ecx
	jb	LBB0_3
## %bb.1:
	testl	%eax, %eax
	jne	LBB0_5
## %bb.2:
	movl	$128, %r15d
LBB0_3:
	movl	%r15d, (%rbx)
LBB0_4:
	movl	%r14d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	movq	%rbx, %rdi
	callq	_ath9k_hw_common
	movl	(%r12), %edx
	andl	%r15d, %edx
	leaq	L_.str(%rip), %rsi
	movl	%eax, %edi
	callq	_ath_err
	movq	_EOPNOTSUPP@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
	jmp	LBB0_4
	.cfi_endproc
                                        ## -- End function
	.comm	_AR_RADIO_SREV_MAJOR,4,2        ## @AR_RADIO_SREV_MAJOR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Radio Chip Rev 0x%02X not supported\n"

	.comm	_EOPNOTSUPP,4,2                 ## @EOPNOTSUPP
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ar9002_hw_rf_claim             ; -- Begin function ar9002_hw_rf_claim
	.p2align	2
_ar9002_hw_rf_claim:                    ; @ar9002_hw_rf_claim
	.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, x0
	mov	w0, #0
	bl	_AR_PHY
	mov	x1, x0
	mov	x0, x19
	mov	w2, #7
	bl	_REG_WRITE
	mov	x0, x19
	bl	_ar9002_hw_get_radiorev
	mov	x20, x0
Lloh0:
	adrp	x21, _AR_RADIO_SREV_MAJOR@GOTPAGE
Lloh1:
	ldr	x21, [x21, _AR_RADIO_SREV_MAJOR@GOTPAGEOFF]
	ldr	w8, [x21]
	and	w8, w8, w0
	sub	w9, w8, #128
	cmp	w9, #4
	b.lo	LBB0_3
; %bb.1:
	cbnz	w8, LBB0_5
; %bb.2:
	mov	w20, #128
LBB0_3:
	mov	w0, #0
	str	w20, [x19]
LBB0_4:
	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
LBB0_5:
	mov	x0, x19
	bl	_ath9k_hw_common
	ldr	w8, [x21]
	and	w2, w8, w20
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	bl	_ath_err
Lloh4:
	adrp	x8, _EOPNOTSUPP@GOTPAGE
Lloh5:
	ldr	x8, [x8, _EOPNOTSUPP@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh2, Lloh3
	.cfi_endproc
                                        ; -- End function
	.comm	_AR_RADIO_SREV_MAJOR,4,2        ; @AR_RADIO_SREV_MAJOR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Radio Chip Rev 0x%02X not supported\n"

	.comm	_EOPNOTSUPP,4,2                 ; @EOPNOTSUPP
.subsections_via_symbols
