	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mt76x0_phy_tssi_calibrate
_mt76x0_phy_tssi_calibrate:             ## @mt76x0_phy_tssi_calibrate
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$32, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %r14
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -24(%rbp)
	leaq	-40(%rbp), %rsi
	leaq	-36(%rbp), %rdx
	callq	_mt76x0_phy_tssi_adc_calibrate
	testq	%rax, %rax
	js	LBB0_3
## %bb.1:
	movl	-36(%rbp), %ebx
	andl	$7, %ebx
	leaq	-36(%rbp), %rdx
	leaq	-48(%rbp), %rcx
	leaq	-44(%rbp), %r8
	movq	%r14, %rdi
	movl	%ebx, %esi
	callq	_mt76x0_phy_get_target_power
	testq	%rax, %rax
	js	LBB0_3
## %bb.2:
	movl	-48(%rbp), %edx
	movl	-44(%rbp), %ecx
	movl	-40(%rbp), %r8d
	movq	%r14, %rdi
	movl	%ebx, %esi
	callq	_mt76x0_phy_get_delta_power
	movq	_MT_TX_ALC_CFG_1@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movq	_MT_TX_ALC_CFG_1_TEMP_COMP@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movq	%r14, %rdi
	movl	%eax, %ecx
	callq	_mt76_rmw_field
LBB0_3:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-24(%rbp), %rax
	jne	LBB0_5
## %bb.4:
	addq	$32, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_5:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_MT_TX_ALC_CFG_1,4,2            ## @MT_TX_ALC_CFG_1
	.comm	_MT_TX_ALC_CFG_1_TEMP_COMP,4,2  ## @MT_TX_ALC_CFG_1_TEMP_COMP
	.no_dead_strip	_mt76x0_phy_tssi_calibrate
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mt76x0_phy_tssi_calibrate
_mt76x0_phy_tssi_calibrate:             ; @mt76x0_phy_tssi_calibrate
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #24]
	mov	x1, sp
	add	x2, sp, #12
	bl	_mt76x0_phy_tssi_adc_calibrate
	tbnz	x0, #63, LBB0_3
; %bb.1:
	ldr	w8, [sp, #12]
	and	w20, w8, #0x7
	add	x2, sp, #12
	add	x3, sp, #8
	add	x4, sp, #4
	mov	x0, x19
	mov	x1, x20
	bl	_mt76x0_phy_get_target_power
	tbnz	x0, #63, LBB0_3
; %bb.2:
	ldp	w3, w2, [sp, #4]
	ldr	w4, [sp]
	mov	x0, x19
	mov	x1, x20
	bl	_mt76x0_phy_get_delta_power
	mov	x3, x0
Lloh3:
	adrp	x8, _MT_TX_ALC_CFG_1@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MT_TX_ALC_CFG_1@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
Lloh6:
	adrp	x8, _MT_TX_ALC_CFG_1_TEMP_COMP@GOTPAGE
Lloh7:
	ldr	x8, [x8, _MT_TX_ALC_CFG_1_TEMP_COMP@GOTPAGEOFF]
Lloh8:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_mt76_rmw_field
LBB0_3:
	ldr	x8, [sp, #24]
Lloh9:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh10:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh11:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_5
; %bb.4:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
LBB0_5:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_MT_TX_ALC_CFG_1,4,2            ; @MT_TX_ALC_CFG_1
	.comm	_MT_TX_ALC_CFG_1_TEMP_COMP,4,2  ; @MT_TX_ALC_CFG_1_TEMP_COMP
	.no_dead_strip	_mt76x0_phy_tssi_calibrate
.subsections_via_symbols
