	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function rs_tpc_perform
_rs_tpc_perform:                        ## @rs_tpc_perform
	.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	%rcx, %rbx
	movq	%rdx, %r13
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	movq	%rsi, %rdi
	callq	_iwl_mvm_sta_from_mac80211
	movq	(%rax), %r12
	movq	%rbx, -88(%rbp)                 ## 8-byte Spill
	leaq	8(%rbx), %r14
	movq	(%r13), %rax
	movq	%rax, -80(%rbp)                 ## 8-byte Spill
	movq	_IWL_INVALID_VALUE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	xorl	%eax, %eax
	callq	_rcu_read_lock
	movl	(%r12), %edi
	callq	_rcu_dereference
	movq	%rax, %r15
	xorl	%edi, %edi
	testq	%rax, %rax
	sete	%dil
	callq	_WARN_ON
	testq	%rax, %rax
	movq	%r13, -64(%rbp)                 ## 8-byte Spill
	je	LBB0_2
## %bb.1:
	movq	_NUM_NL80211_BANDS@GOTPCREL(%rip), %rax
	jmp	LBB0_3
LBB0_2:
	movq	(%r15), %rax
LBB0_3:
	movq	-56(%rbp), %r15                 ## 8-byte Reload
	movl	(%rax), %ebx
	xorl	%eax, %eax
	callq	_rcu_read_unlock
	movq	%r15, %rdi
	movq	%r12, %rsi
	movq	%r14, %rdx
	movl	%ebx, %ecx
	callq	_rs_tpc_allowed
	testl	%eax, %eax
	je	LBB0_4
## %bb.5:
	leaq	-48(%rbp), %rdx
	leaq	-44(%rbp), %rcx
	movq	%r15, %rdi
	movq	-80(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rsi
	callq	_rs_get_adjacent_txp
	movq	-88(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rax
	movslq	-48(%rbp), %r9
	movq	_TPC_INVALID@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movq	-72(%rbp), %r12                 ## 8-byte Reload
                                        ## kill: def $r12d killed $r12d killed $r12 def $r12
	cmpl	%edx, %r9d
	je	LBB0_7
## %bb.6:
	movl	(%rax,%r9,8), %r12d
LBB0_7:
	movl	(%rax,%rbx,8), %ecx
	movl	4(%rax,%rbx,8), %r15d
	movslq	-44(%rbp), %r10
	cmpl	%edx, %r10d
	je	LBB0_9
## %bb.8:
	movl	(%rax,%r10,8), %eax
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
LBB0_9:
	subq	$8, %rsp
	leaq	L_.str.1(%rip), %rsi
	movq	-72(%rbp), %r14                 ## 8-byte Reload
	movq	-56(%rbp), %r13                 ## 8-byte Reload
	movq	%r13, %rdi
	movq	%rbx, %rdx
	movl	%ecx, %ebx
	movl	%r15d, %r8d
                                        ## kill: def $r9d killed $r9d killed $r9
	xorl	%eax, %eax
	pushq	%r14
	pushq	%r12
	pushq	%r10
	callq	_IWL_DEBUG_RATE
	addq	$32, %rsp
	movl	-48(%rbp), %edx
	movl	-44(%rbp), %ecx
	subq	$8, %rsp
	movq	%r13, %rdi
	movl	%r15d, %esi
	movl	%ebx, %r8d
	movl	%r12d, %r9d
	pushq	%r14
	callq	_rs_get_tpc_action
	addq	$16, %rsp
                                        ## kill: def $eax killed $eax def $rax
	movslq	-48(%rbp), %rcx
	movq	_TPC_INVALID@GOTPCREL(%rip), %rdx
	movl	(%rdx), %esi
	cmpl	%esi, %ecx
	jne	LBB0_13
## %bb.10:
	cmpl	$131, %eax
	jne	LBB0_13
## %bb.11:
	leaq	L_.str.2(%rip), %rsi
	jmp	LBB0_12
LBB0_4:
	leaq	L_.str(%rip), %rsi
	movq	%r15, %rdi
	xorl	%eax, %eax
	callq	_IWL_DEBUG_RATE
	movq	_TPC_NO_REDUCTION@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	movq	-64(%rbp), %rdx                 ## 8-byte Reload
	movq	%rcx, (%rdx)
	xorl	%ebx, %ebx
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	cmpq	(%rax), %rcx
	setne	%bl
	jmp	LBB0_23
LBB0_13:
	movslq	-44(%rbp), %rdx
	cmpl	%esi, %edx
	jne	LBB0_16
## %bb.14:
	leal	-129(%rax), %esi
	cmpl	$1, %esi
	ja	LBB0_16
## %bb.15:
	leaq	L_.str.3(%rip), %rsi
LBB0_12:
	xorl	%ebx, %ebx
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	xorl	%eax, %eax
	callq	_IWL_DEBUG_RATE
	jmp	LBB0_23
LBB0_16:
	cmpl	$129, %eax
	je	LBB0_21
## %bb.17:
	cmpl	$130, %eax
	je	LBB0_20
## %bb.18:
	xorl	%ebx, %ebx
	cmpl	$131, %eax
	jne	LBB0_23
## %bb.19:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movq	%rcx, (%rax)
	jmp	LBB0_22
LBB0_21:
	movq	_TPC_NO_REDUCTION@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	movq	%rax, (%rcx)
	jmp	LBB0_22
LBB0_20:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movq	%rdx, (%rax)
LBB0_22:
	movl	$1, %ebx
LBB0_23:
	movl	%ebx, %eax
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IWL_INVALID_VALUE,4,2          ## @IWL_INVALID_VALUE
	.comm	_NUM_NL80211_BANDS,4,2          ## @NUM_NL80211_BANDS
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"tpc is not allowed. remove txp restrictions\n"

	.comm	_TPC_NO_REDUCTION,8,3           ## @TPC_NO_REDUCTION
	.comm	_TPC_INVALID,4,2                ## @TPC_INVALID
L_.str.1:                               ## @.str.1
	.asciz	"(TPC: %d): cur_tpt %d SR %d weak %d strong %d weak_tpt %d strong_tpt %d\n"

L_.str.2:                               ## @.str.2
	.asciz	"already in lowest txp, stay\n"

L_.str.3:                               ## @.str.3
	.asciz	"already in highest txp, stay\n"

	.comm	_TPC_MAX_REDUCTION,8,3          ## @TPC_MAX_REDUCTION
	.no_dead_strip	_rs_tpc_perform
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function rs_tpc_perform
_rs_tpc_perform:                        ; @rs_tpc_perform
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	stp	x26, x25, [sp, #64]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #80]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #96]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #112]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #128]            ; 16-byte Folded Spill
	add	x29, sp, #128
	.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	x23, x3
	mov	x19, x2
	mov	x20, x0
	mov	x0, x1
	bl	_iwl_mvm_sta_from_mac80211
	ldr	x24, [x0]
	add	x25, x23, #8
	ldr	x21, [x19]
Lloh0:
	adrp	x8, _IWL_INVALID_VALUE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _IWL_INVALID_VALUE@GOTPAGEOFF]
Lloh2:
	ldr	w22, [x8]
	bl	_rcu_read_lock
	ldr	w0, [x24]
	bl	_rcu_dereference
	mov	x26, x0
	cmp	x0, #0
	cset	w0, eq
	bl	_WARN_ON
	cbz	x0, LBB0_2
; %bb.1:
Lloh3:
	adrp	x8, _NUM_NL80211_BANDS@GOTPAGE
Lloh4:
	ldr	x8, [x8, _NUM_NL80211_BANDS@GOTPAGEOFF]
	b	LBB0_3
LBB0_2:
	ldr	x8, [x26]
LBB0_3:
	ldr	w26, [x8]
	bl	_rcu_read_unlock
	mov	x0, x20
	mov	x1, x24
	mov	x2, x25
	mov	x3, x26
	bl	_rs_tpc_allowed
	cbz	w0, LBB0_11
; %bb.4:
	add	x2, sp, #60
	add	x3, sp, #56
	mov	x0, x20
	mov	x1, x21
	bl	_rs_get_adjacent_txp
	ldr	x9, [x23]
	add	x8, x9, x21, lsl #3
	ldp	w23, w24, [x8]
	ldrsw	x8, [sp, #60]
Lloh5:
	adrp	x26, _TPC_INVALID@GOTPAGE
Lloh6:
	ldr	x26, [x26, _TPC_INVALID@GOTPAGEOFF]
	ldr	w11, [x26]
	mov	x25, x22
	cmp	w8, w11
	b.eq	LBB0_6
; %bb.5:
	lsl	x10, x8, #3
	ldr	w25, [x9, x10]
LBB0_6:
	ldrsw	x10, [sp, #56]
	cmp	w10, w11
	b.eq	LBB0_8
; %bb.7:
	lsl	x11, x10, #3
	ldr	w22, [x9, x11]
LBB0_8:
	stp	x25, x22, [sp, #40]
	stp	x8, x10, [sp, #24]
	stp	x23, x24, [sp, #8]
Lloh7:
	adrp	x1, l_.str.1@PAGE
Lloh8:
	add	x1, x1, l_.str.1@PAGEOFF
	str	x21, [sp]
	mov	x0, x20
	bl	_IWL_DEBUG_RATE
	ldp	w3, w2, [sp, #56]
	mov	x0, x20
	mov	x1, x24
	mov	x4, x23
	mov	x5, x25
	mov	x6, x22
	bl	_rs_get_tpc_action
	ldrsw	x8, [sp, #60]
	ldr	w10, [x26]
	cmp	w8, w10
	b.ne	LBB0_12
; %bb.9:
	cmp	w0, #131
	b.ne	LBB0_12
; %bb.10:
Lloh9:
	adrp	x1, l_.str.2@PAGE
Lloh10:
	add	x1, x1, l_.str.2@PAGEOFF
	b	LBB0_15
LBB0_11:
Lloh11:
	adrp	x1, l_.str@PAGE
Lloh12:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_IWL_DEBUG_RATE
Lloh13:
	adrp	x8, _TPC_NO_REDUCTION@GOTPAGE
Lloh14:
	ldr	x8, [x8, _TPC_NO_REDUCTION@GOTPAGEOFF]
	ldr	x9, [x8]
	str	x9, [x19]
	ldr	x8, [x8]
	cmp	x21, x8
	cset	w0, ne
	b	LBB0_24
LBB0_12:
	ldrsw	x9, [sp, #56]
	cmp	w9, w10
	b.ne	LBB0_16
; %bb.13:
	sub	w10, w0, #129
	cmp	w10, #1
	b.hi	LBB0_16
; %bb.14:
Lloh15:
	adrp	x1, l_.str.3@PAGE
Lloh16:
	add	x1, x1, l_.str.3@PAGEOFF
LBB0_15:
	mov	x0, x20
	bl	_IWL_DEBUG_RATE
	mov	w0, #0
	b	LBB0_24
LBB0_16:
	cmp	w0, #129
	b.eq	LBB0_20
; %bb.17:
	cmp	w0, #130
	b.eq	LBB0_22
; %bb.18:
	cmp	w0, #131
	b.eq	LBB0_21
; %bb.19:
	mov	w0, #0
	b	LBB0_24
LBB0_20:
Lloh17:
	adrp	x8, _TPC_NO_REDUCTION@GOTPAGE
Lloh18:
	ldr	x8, [x8, _TPC_NO_REDUCTION@GOTPAGEOFF]
Lloh19:
	ldr	x8, [x8]
LBB0_21:
	str	x8, [x19]
	b	LBB0_23
LBB0_22:
	str	x9, [x19]
LBB0_23:
	mov	w0, #1
LBB0_24:
	ldp	x29, x30, [sp, #128]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #112]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #96]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #80]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #144
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.comm	_IWL_INVALID_VALUE,4,2          ; @IWL_INVALID_VALUE
	.comm	_NUM_NL80211_BANDS,4,2          ; @NUM_NL80211_BANDS
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"tpc is not allowed. remove txp restrictions\n"

	.comm	_TPC_NO_REDUCTION,8,3           ; @TPC_NO_REDUCTION
	.comm	_TPC_INVALID,4,2                ; @TPC_INVALID
l_.str.1:                               ; @.str.1
	.asciz	"(TPC: %d): cur_tpt %d SR %d weak %d strong %d weak_tpt %d strong_tpt %d\n"

l_.str.2:                               ; @.str.2
	.asciz	"already in lowest txp, stay\n"

l_.str.3:                               ; @.str.3
	.asciz	"already in highest txp, stay\n"

	.comm	_TPC_MAX_REDUCTION,8,3          ; @TPC_MAX_REDUCTION
	.no_dead_strip	_rs_tpc_perform
.subsections_via_symbols
