	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ath9k_rx_prepare
_ath9k_rx_prepare:                      ## @ath9k_rx_prepare
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r14
	movq	%rdi, %r15
	movq	16(%rdi), %rbx
	movq	(%rsi), %r12
	movl	8(%rdi), %edi
	callq	_ath9k_hw_common
	movq	%rax, %r13
	movq	(%rax), %rax
	movl	$0, -60(%rbp)
	movq	(%r12), %rdx
	movq	_HTC_RX_FRAME_HEADER_SIZE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rdx
	jge	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r13, %rdi
	xorl	%eax, %eax
	callq	_ath_err
	jmp	LBB0_10
LBB0_2:
	movq	%rax, -88(%rbp)                 ## 8-byte Spill
	movq	%rbx, -96(%rbp)                 ## 8-byte Spill
	movq	%r14, -72(%rbp)                 ## 8-byte Spill
	movq	8(%r12), %r14
	movl	4(%r14), %edi
	movq	%rcx, %rbx
	callq	_be16_to_cpu
	movq	(%r12), %rcx
	movq	(%rbx), %rdx
	subq	%rcx, %rdx
	addq	%rax, %rdx
	jne	LBB0_3
## %bb.4:
	movq	-72(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	xorl	%esi, %esi
	movl	$20, %edx
	callq	_memset
	leaq	-56(%rbp), %rdi
	movq	%r14, %rsi
	callq	_rx_status_htc_to_ath
	movq	%r15, %rdi
	leaq	-56(%rbp), %rsi
	callq	_ath9k_htc_err_stat_rx
	movl	(%r14), %edi
	movq	%rbx, %r14
	callq	_be64_to_cpu
	movl	%eax, 16(%rbx)
	movq	_HTC_RX_FRAME_HEADER_SIZE@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	movq	%r12, %rdi
	callq	_skb_pull
	movq	8(%r12), %rbx
	movq	_ATH9K_RXERR_PHY@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, -56(%rbp)
	je	LBB0_6
## %bb.5:
	addq	$4, %r15
	movl	16(%r14), %ecx
	leaq	-56(%rbp), %rdx
	movq	%r15, %rdi
	movq	%rbx, %rsi
	callq	_ath_cmn_process_fft
	xorl	%ebx, %ebx
	jmp	LBB0_10
LBB0_3:
	movslq	4(%r14), %rdx
	leaq	L_.str.1(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r13, %rdi
	xorl	%eax, %eax
	callq	_ath_err
LBB0_10:
	movl	%ebx, %eax
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movl	(%r15), %r9d
	leaq	-56(%rbp), %rcx
	leaq	-60(%rbp), %r8
	movq	%r13, %rdi
	movq	%rbx, %rsi
	movq	%r14, %rdx
	callq	_ath9k_cmn_rx_accept
	testl	%eax, %eax
	je	LBB0_7
## %bb.8:
	movq	%rbx, -80(%rbp)                 ## 8-byte Spill
	movl	-60(%rbp), %r8d
	leaq	-56(%rbp), %r14
	movq	%r13, %rdi
	movq	%r12, %rsi
	movq	%r14, %rdx
	movq	-72(%rbp), %rcx                 ## 8-byte Reload
	callq	_ath9k_cmn_rx_skb_postprocess
	movq	%r13, %rdi
	movq	-96(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rsi
	movq	%r14, %rdx
	movq	-72(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rcx
	callq	_ath9k_cmn_process_rate
	testq	%rax, %rax
	movl	$0, %ebx
	jne	LBB0_10
## %bb.9:
	movq	%r13, %rdi
	movq	-80(%rbp), %rsi                 ## 8-byte Reload
	callq	_ath_is_mybeacon
	movl	%eax, -48(%rbp)
	leaq	-56(%rbp), %rdx
	movq	%r13, %rdi
	movq	%r15, %rsi
	movq	%r14, %rcx
	callq	_ath9k_cmn_process_rssi
	movq	-88(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rax
	movq	(%rax), %rax
	movl	4(%rax), %ecx
	movl	%ecx, 12(%r14)
	movl	(%rax), %eax
	movl	%eax, 8(%r14)
	movl	-52(%rbp), %eax
	movl	%eax, 4(%r14)
	movq	_RX_FLAG_MACTIME_END@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, (%r14)
	movl	$1, %ebx
	jmp	LBB0_10
LBB0_7:
	xorl	%ebx, %ebx
	jmp	LBB0_10
	.cfi_endproc
                                        ## -- End function
	.comm	_HTC_RX_FRAME_HEADER_SIZE,8,3   ## @HTC_RX_FRAME_HEADER_SIZE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Corrupted RX frame, dropping (len: %d)\n"

L_.str.1:                               ## @.str.1
	.asciz	"Corrupted RX data len, dropping (dlen: %d, skblen: %d)\n"

	.comm	_ATH9K_RXERR_PHY,4,2            ## @ATH9K_RXERR_PHY
	.comm	_RX_FLAG_MACTIME_END,4,2        ## @RX_FLAG_MACTIME_END
	.no_dead_strip	_ath9k_rx_prepare
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ath9k_rx_prepare
_ath9k_rx_prepare:                      ; @ath9k_rx_prepare
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	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
	mov	x19, x2
	mov	x23, x0
	ldr	x21, [x0, #16]
	ldr	x22, [x1]
	ldr	w0, [x0, #8]
	bl	_ath9k_hw_common
	mov	x20, x0
	ldr	x25, [x0]
	str	wzr, [sp, #12]
	ldr	x2, [x22]
Lloh0:
	adrp	x26, _HTC_RX_FRAME_HEADER_SIZE@GOTPAGE
Lloh1:
	ldr	x26, [x26, _HTC_RX_FRAME_HEADER_SIZE@GOTPAGEOFF]
	ldr	x8, [x26]
	cmp	x2, x8
	b.ge	LBB0_2
; %bb.1:
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	b	LBB0_6
LBB0_2:
	ldr	x24, [x22, #8]
	ldr	w0, [x24, #4]
	bl	_be16_to_cpu
	ldr	x8, [x22]
	ldr	x9, [x26]
	sub	x9, x9, x8
	cmn	x9, x0
	b.ne	LBB0_5
; %bb.3:
	mov	x0, x19
	mov	w1, #0
	mov	w2, #20
	bl	_memset
	add	x0, sp, #16
	mov	x1, x24
	bl	_rx_status_htc_to_ath
	add	x1, sp, #16
	mov	x0, x23
	bl	_ath9k_htc_err_stat_rx
	ldr	w0, [x24]
	bl	_be64_to_cpu
	str	w0, [x19, #16]
	ldr	x1, [x26]
	mov	x0, x22
	bl	_skb_pull
	ldr	x24, [x22, #8]
	ldr	w8, [sp, #16]
Lloh4:
	adrp	x9, _ATH9K_RXERR_PHY@GOTPAGE
Lloh5:
	ldr	x9, [x9, _ATH9K_RXERR_PHY@GOTPAGEOFF]
Lloh6:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_9
; %bb.4:
	add	x0, x23, #4
	ldr	w3, [x19, #16]
	add	x2, sp, #16
	mov	x1, x24
	bl	_ath_cmn_process_fft
	b	LBB0_7
LBB0_5:
	ldrsw	x2, [x24, #4]
	str	x8, [sp]
Lloh7:
	adrp	x1, l_.str.1@PAGE
Lloh8:
	add	x1, x1, l_.str.1@PAGEOFF
LBB0_6:
	mov	x0, x20
	bl	_ath_err
LBB0_7:
	mov	w0, #0
LBB0_8:
	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
	add	sp, sp, #112
	ret
LBB0_9:
	ldr	w5, [x23]
	add	x3, sp, #16
	add	x4, sp, #12
	mov	x0, x20
	mov	x1, x24
	mov	x2, x19
	bl	_ath9k_cmn_rx_accept
	cbz	w0, LBB0_8
; %bb.10:
	ldr	w4, [sp, #12]
	add	x2, sp, #16
	mov	x0, x20
	mov	x1, x22
	mov	x3, x19
	bl	_ath9k_cmn_rx_skb_postprocess
	add	x2, sp, #16
	mov	x0, x20
	mov	x1, x21
	mov	x3, x19
	bl	_ath9k_cmn_process_rate
	cbnz	x0, LBB0_7
; %bb.11:
	mov	x0, x20
	mov	x1, x24
	bl	_ath_is_mybeacon
	str	w0, [sp, #24]
	add	x2, sp, #16
	mov	x0, x20
	mov	x1, x21
	mov	x3, x19
	bl	_ath9k_cmn_process_rssi
	ldr	x8, [x25]
	ldr	x8, [x8]
	ldr	d0, [x8]
	str	d0, [x19, #8]
	ldr	w8, [sp, #20]
Lloh9:
	adrp	x9, _RX_FLAG_MACTIME_END@GOTPAGE
Lloh10:
	ldr	x9, [x9, _RX_FLAG_MACTIME_END@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	ldr	w10, [x19]
	orr	w9, w10, w9
	stp	w9, w8, [x19]
	mov	w0, #1
	b	LBB0_8
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_HTC_RX_FRAME_HEADER_SIZE,8,3   ; @HTC_RX_FRAME_HEADER_SIZE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Corrupted RX frame, dropping (len: %d)\n"

l_.str.1:                               ; @.str.1
	.asciz	"Corrupted RX data len, dropping (dlen: %d, skblen: %d)\n"

	.comm	_ATH9K_RXERR_PHY,4,2            ; @ATH9K_RXERR_PHY
	.comm	_RX_FLAG_MACTIME_END,4,2        ; @RX_FLAG_MACTIME_END
	.no_dead_strip	_ath9k_rx_prepare
.subsections_via_symbols
