	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function iwl_mvm_oldsn_workaround
_iwl_mvm_oldsn_workaround:              ## @iwl_mvm_oldsn_workaround
	.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	%r9, %r13
	movq	%r8, %r12
	movq	%rcx, %rbx
	movl	%edx, %r15d
	movq	%rsi, %r14
	movq	%rdi, -48(%rbp)                 ## 8-byte Spill
	movq	%rsi, %rdi
	callq	_iwl_mvm_sta_from_mac80211
	movl	8(%rbx), %ecx
	cmpq	%r13, (%rbx)
	jne	LBB0_1
## %bb.4:
	testl	%ecx, %ecx
	jne	LBB0_8
	jmp	LBB0_5
LBB0_1:
	testl	%ecx, %ecx
	jne	LBB0_3
## %bb.2:
	movq	$0, 16(%rbx)
LBB0_3:
	movq	%r13, (%rbx)
LBB0_5:
	movq	_IWL_RX_MPDU_REORDER_BA_OLD_SN@GOTPCREL(%rip), %rcx
	testq	%r12, (%rcx)
	je	LBB0_8
## %bb.6:
	movl	$1, 8(%rbx)
	movq	16(%rbx), %rdx
	incq	%rdx
	movq	%rdx, 16(%rbx)
	movq	_IWL_MVM_AMPDU_CONSEC_DROPS_DELBA@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rdx
	jne	LBB0_8
## %bb.7:
	movl	16(%rbp), %r8d
	movq	%rax, %r12
	movl	(%r14), %ecx
	leaq	L_.str(%rip), %rsi
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movl	%r15d, %r9d
	callq	_IWL_WARN
	movl	(%r12), %r12d
	movl	%r15d, %edi
	callq	_BIT
	movl	(%r14), %edx
	movl	%r12d, %edi
	movl	%eax, %esi
	callq	_ieee80211_stop_rx_ba_session
	movl	$0, 8(%rbx)
	movq	$0, 16(%rbx)
LBB0_8:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IWL_RX_MPDU_REORDER_BA_OLD_SN,8,3 ## @IWL_RX_MPDU_REORDER_BA_OLD_SN
	.comm	_IWL_MVM_AMPDU_CONSEC_DROPS_DELBA,8,3 ## @IWL_MVM_AMPDU_CONSEC_DROPS_DELBA
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"reached %d old SN frames from %pM on queue %d, stopping BA session on TID %d\n"

	.no_dead_strip	_iwl_mvm_oldsn_workaround
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function iwl_mvm_oldsn_workaround
_iwl_mvm_oldsn_workaround:              ; @iwl_mvm_oldsn_workaround
	.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	x22, x6
	mov	x26, x5
	mov	x25, x4
	mov	x19, x3
	mov	x21, x2
	mov	x20, x1
	mov	x24, x0
	mov	x0, x1
	bl	_iwl_mvm_sta_from_mac80211
	mov	x23, x0
	ldr	x9, [x19]
	ldr	w8, [x19, #8]
	cmp	x9, x26
	b.ne	LBB0_2
; %bb.1:
	cbnz	w8, LBB0_8
	b	LBB0_5
LBB0_2:
	cbnz	w8, LBB0_4
; %bb.3:
	str	xzr, [x19, #16]
LBB0_4:
	str	x26, [x19]
LBB0_5:
Lloh0:
	adrp	x8, _IWL_RX_MPDU_REORDER_BA_OLD_SN@GOTPAGE
Lloh1:
	ldr	x8, [x8, _IWL_RX_MPDU_REORDER_BA_OLD_SN@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	tst	x8, x25
	b.eq	LBB0_8
; %bb.6:
	mov	w8, #1
	str	w8, [x19, #8]
	ldr	x8, [x19, #16]
	add	x2, x8, #1
	str	x2, [x19, #16]
Lloh3:
	adrp	x8, _IWL_MVM_AMPDU_CONSEC_DROPS_DELBA@GOTPAGE
Lloh4:
	ldr	x8, [x8, _IWL_MVM_AMPDU_CONSEC_DROPS_DELBA@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	cmp	x2, x8
	b.ne	LBB0_8
; %bb.7:
	ldr	w3, [x20]
Lloh6:
	adrp	x1, l_.str@PAGE
Lloh7:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x24
	mov	x4, x22
	mov	x5, x21
	bl	_IWL_WARN
	ldr	w22, [x23]
	mov	x0, x21
	bl	_BIT
	mov	x1, x0
	ldr	w2, [x20]
	mov	x0, x22
	bl	_ieee80211_stop_rx_ba_session
	str	wzr, [x19, #8]
	str	xzr, [x19, #16]
LBB0_8:
	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
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_IWL_RX_MPDU_REORDER_BA_OLD_SN,8,3 ; @IWL_RX_MPDU_REORDER_BA_OLD_SN
	.comm	_IWL_MVM_AMPDU_CONSEC_DROPS_DELBA,8,3 ; @IWL_MVM_AMPDU_CONSEC_DROPS_DELBA
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"reached %d old SN frames from %pM on queue %d, stopping BA session on TID %d\n"

	.no_dead_strip	_iwl_mvm_oldsn_workaround
.subsections_via_symbols
