	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function wlc_phy_internal_cal_txgain_nphy
_wlc_phy_internal_cal_txgain_nphy:      ## @wlc_phy_internal_cal_txgain_nphy
	.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	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -32(%rbp)
	movq	8(%rdi), %rax
	movq	16(%rdi), %rcx
	movl	(%rax), %edx
	movl	%edx, (%rcx)
	movl	(%rax), %edx
	movl	%edx, 4(%rcx)
	movl	(%rax), %edx
	movl	$1, %esi
	movl	$1, %ecx
	callq	_wlc_phy_txpwr_index_nphy
	movq	8(%rbx), %rax
	movl	4(%rax), %edx
	movq	%rbx, %rdi
	movl	$2, %esi
	movl	$1, %ecx
	callq	_wlc_phy_txpwr_index_nphy
	movq	_NPHY_TBL_ID_RFSEQ@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	leaq	-40(%rbp), %r14
	movq	%rbx, %rdi
	movl	$2, %edx
	movl	$272, %ecx                      ## imm = 0x110
	movl	$16, %r8d
	movq	%r14, %r9
	callq	_wlc_phy_table_read_nphy
	movl	(%rbx), %edi
	callq	_CHSPEC_IS2G
	xorl	%ecx, %ecx
	testq	%rax, %rax
	sete	%cl
	movl	$61440, %eax                    ## imm = 0xF000
	movl	-40(%rbp), %edx
	andl	%eax, %edx
	shll	$5, %ecx
	addl	%ecx, %edx
	addl	$3904, %edx                     ## imm = 0xF40
	movl	%edx, -40(%rbp)
	andl	-36(%rbp), %eax
	addl	%ecx, %eax
	addl	$3904, %eax                     ## imm = 0xF40
	movl	%eax, -36(%rbp)
	movl	(%r15), %esi
	movq	%rbx, %rdi
	movl	$2, %edx
	movl	$272, %ecx                      ## imm = 0x110
	movl	$16, %r8d
	movq	%r14, %r9
	callq	_wlc_phy_table_write_nphy
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-32(%rbp), %rax
	jne	LBB0_2
## %bb.1:
	addq	$24, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_2:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_NPHY_TBL_ID_RFSEQ,4,2          ## @NPHY_TBL_ID_RFSEQ
	.no_dead_strip	_wlc_phy_internal_cal_txgain_nphy
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function wlc_phy_internal_cal_txgain_nphy
_wlc_phy_internal_cal_txgain_nphy:      ; @wlc_phy_internal_cal_txgain_nphy
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	mov	x19, x0
	ldp	x8, x9, [x0, #8]
	ldr	w10, [x8]
	str	w10, [x9]
	ldr	w10, [x8]
	str	w10, [x9, #4]
	ldr	w2, [x8]
	mov	w1, #1
	mov	w3, #1
	bl	_wlc_phy_txpwr_index_nphy
	ldr	x8, [x19, #8]
	ldr	w2, [x8, #4]
	mov	x0, x19
	mov	w1, #2
	mov	w3, #1
	bl	_wlc_phy_txpwr_index_nphy
Lloh0:
	adrp	x20, _NPHY_TBL_ID_RFSEQ@GOTPAGE
Lloh1:
	ldr	x20, [x20, _NPHY_TBL_ID_RFSEQ@GOTPAGEOFF]
	ldr	w1, [x20]
	add	x5, sp, #8
	mov	x0, x19
	mov	w2, #2
	mov	w3, #272
	mov	w4, #16
	bl	_wlc_phy_table_read_nphy
	ldr	w0, [x19]
	bl	_CHSPEC_IS2G
	cmp	x0, #0
	mov	w8, #3904
	mov	w9, #3936
	csel	w8, w9, w8, eq
	ldr	d0, [sp, #8]
	movi.2s	v1, #240, lsl #8
	and.8b	v0, v0, v1
	dup.2s	v1, w8
	orr.8b	v0, v0, v1
	str	d0, [sp, #8]
	ldr	w1, [x20]
	add	x5, sp, #8
	mov	x0, x19
	mov	w2, #2
	mov	w3, #272
	mov	w4, #16
	bl	_wlc_phy_table_write_nphy
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_NPHY_TBL_ID_RFSEQ,4,2          ; @NPHY_TBL_ID_RFSEQ
	.no_dead_strip	_wlc_phy_internal_cal_txgain_nphy
.subsections_via_symbols
