	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mt7615_mac_set_scs             ## -- Begin function mt7615_mac_set_scs
	.p2align	4, 0x90
_mt7615_mac_set_scs:                    ## @mt7615_mac_set_scs
	.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
	movl	%esi, %r14d
	movq	%rdi, %rbx
	leaq	4(%rdi), %r15
	movq	%r15, %rdi
	callq	_mutex_lock
	cmpl	%r14d, (%rbx)
	je	LBB0_6
## %bb.1:
	movq	_MT_WF_PHY_B0_MIN_PRI_PWR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_MT_WF_PHY_B0_PD_BLK@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	testl	%r14d, %r14d
	je	LBB0_4
## %bb.2:
	callq	_mt76_set
	movq	%r15, %rdi
	callq	_is_mt7622
	testq	%rax, %rax
	je	LBB0_5
## %bb.3:
	movq	_MT_MIB_M0_MISC_CR@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movq	%rbx, %rdi
	movl	$1792, %edx                     ## imm = 0x700
	callq	_mt76_set
	movl	(%r12), %esi
	movq	%rbx, %rdi
	movl	$7, %edx
	callq	_mt76_set
	jmp	LBB0_5
LBB0_4:
	callq	_mt76_clear
	movq	_MT_WF_PHY_B1_MIN_PRI_PWR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_MT_WF_PHY_B1_PD_BLK@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_mt76_clear
LBB0_5:
	movq	%rbx, %rdi
	callq	_mt7615_mac_set_default_sensitivity
	movl	%r14d, (%rbx)
LBB0_6:
	movq	%r15, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_mutex_unlock                   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_MT_WF_PHY_B0_MIN_PRI_PWR,4,2   ## @MT_WF_PHY_B0_MIN_PRI_PWR
	.comm	_MT_WF_PHY_B0_PD_BLK,4,2        ## @MT_WF_PHY_B0_PD_BLK
	.comm	_MT_MIB_M0_MISC_CR,4,2          ## @MT_MIB_M0_MISC_CR
	.comm	_MT_WF_PHY_B1_MIN_PRI_PWR,4,2   ## @MT_WF_PHY_B1_MIN_PRI_PWR
	.comm	_MT_WF_PHY_B1_PD_BLK,4,2        ## @MT_WF_PHY_B1_PD_BLK
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mt7615_mac_set_scs             ; -- Begin function mt7615_mac_set_scs
	.p2align	2
_mt7615_mac_set_scs:                    ; @mt7615_mac_set_scs
	.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	x20, x1
	mov	x21, x0
	add	x19, x0, #4
	mov	x0, x19
	bl	_mutex_lock
	ldr	w8, [x21]
	cmp	w8, w20
	b.eq	LBB0_6
; %bb.1:
Lloh0:
	adrp	x8, _MT_WF_PHY_B0_MIN_PRI_PWR@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MT_WF_PHY_B0_MIN_PRI_PWR@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x8, _MT_WF_PHY_B0_PD_BLK@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MT_WF_PHY_B0_PD_BLK@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	mov	x0, x21
	cbz	w20, LBB0_4
; %bb.2:
	bl	_mt76_set
	mov	x0, x19
	bl	_is_mt7622
	cbz	x0, LBB0_5
; %bb.3:
Lloh6:
	adrp	x22, _MT_MIB_M0_MISC_CR@GOTPAGE
Lloh7:
	ldr	x22, [x22, _MT_MIB_M0_MISC_CR@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x21
	mov	w2, #1792
	bl	_mt76_set
	ldr	w1, [x22]
	mov	x0, x21
	mov	w2, #7
	bl	_mt76_set
	b	LBB0_5
LBB0_4:
	bl	_mt76_clear
Lloh8:
	adrp	x8, _MT_WF_PHY_B1_MIN_PRI_PWR@GOTPAGE
Lloh9:
	ldr	x8, [x8, _MT_WF_PHY_B1_MIN_PRI_PWR@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
Lloh11:
	adrp	x8, _MT_WF_PHY_B1_PD_BLK@GOTPAGE
Lloh12:
	ldr	x8, [x8, _MT_WF_PHY_B1_PD_BLK@GOTPAGEOFF]
Lloh13:
	ldr	w2, [x8]
	mov	x0, x21
	bl	_mt76_clear
LBB0_5:
	mov	x0, x21
	bl	_mt7615_mac_set_default_sensitivity
	str	w20, [x21]
LBB0_6:
	mov	x0, x19
	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
	b	_mutex_unlock
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_MT_WF_PHY_B0_MIN_PRI_PWR,4,2   ; @MT_WF_PHY_B0_MIN_PRI_PWR
	.comm	_MT_WF_PHY_B0_PD_BLK,4,2        ; @MT_WF_PHY_B0_PD_BLK
	.comm	_MT_MIB_M0_MISC_CR,4,2          ; @MT_MIB_M0_MISC_CR
	.comm	_MT_WF_PHY_B1_MIN_PRI_PWR,4,2   ; @MT_WF_PHY_B1_MIN_PRI_PWR
	.comm	_MT_WF_PHY_B1_PD_BLK,4,2        ; @MT_WF_PHY_B1_PD_BLK
.subsections_via_symbols
