	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function _rtl92s_dm_txpowertracking_callback_thermalmeter
__rtl92s_dm_txpowertracking_callback_thermalmeter: ## @_rtl92s_dm_txpowertracking_callback_thermalmeter
	.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	%rdi, %r14
	callq	_rtl_priv
	movq	%rax, %r15
	movq	%r14, %rdi
	callq	_rtl_priv
	movq	%rax, %rdi
	callq	_rtl_efuse
	movq	%rax, %r12
	movl	$1, (%r15)
	movq	_RF90_PATH_A@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_RF_T_METER@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	movl	$31, %ecx
	callq	_rtl_get_rfreg
	movq	%rax, %rbx
	movq	_COMP_POWER_TRACKING@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_DBG_LOUD@GOTPCREL(%rip), %r13
	movl	(%r13), %edx
	movl	4(%r15), %r9d
	movl	(%r12), %eax
	movl	%eax, (%rsp)
	leaq	L_.str(%rip), %rcx
	movq	%r15, %rdi
	movl	%ebx, %r8d
	xorl	%eax, %eax
	callq	_RT_TRACE
	testl	%ebx, %ebx
	je	LBB0_4
## %bb.1:
	movl	%ebx, 4(%r15)
	movq	%r15, %rdi
	callq	_hal_get_firmwareversion
	cmpl	$53, %eax
	jl	LBB0_3
## %bb.2:
	movq	_FW_CMD_TXPWR_TRACK_THERMAL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_rtl92s_phy_set_fw_cmd
	jmp	LBB0_4
LBB0_3:
	movq	_FW_TXPWR_TRACK_THERMAL@GOTPCREL(%rip), %rax
	movq	16(%r15), %rcx
	movl	(%rcx), %ecx
	shll	$16, %ebx
	orl	(%rax), %ebx
	shll	$8, %ecx
	orl	%ecx, %ebx
	movq	_COMP_POWER_TRACKING@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	(%r13), %edx
	leaq	L_.str.1(%rip), %rcx
	movq	%r15, %rdi
	movl	%ebx, %r8d
	xorl	%eax, %eax
	callq	_RT_TRACE
	movq	_WFM5@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	%ebx, %edx
	callq	_rtl_write_dword
	movq	%r14, %rdi
	callq	_rtl92s_phy_chk_fwcmd_iodone
LBB0_4:
	movq	$0, 8(%r15)
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_RF90_PATH_A,4,2                ## @RF90_PATH_A
	.comm	_RF_T_METER,4,2                 ## @RF_T_METER
	.comm	_COMP_POWER_TRACKING,4,2        ## @COMP_POWER_TRACKING
	.comm	_DBG_LOUD,4,2                   ## @DBG_LOUD
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Readback Thermal Meter = 0x%x pre thermal meter 0x%x eeprom_thermal meter 0x%x\n"

	.comm	_FW_CMD_TXPWR_TRACK_THERMAL,4,2 ## @FW_CMD_TXPWR_TRACK_THERMAL
	.comm	_FW_TXPWR_TRACK_THERMAL,4,2     ## @FW_TXPWR_TRACK_THERMAL
L_.str.1:                               ## @.str.1
	.asciz	"Write to FW Thermal Val = 0x%x\n"

	.comm	_WFM5,4,2                       ## @WFM5
	.no_dead_strip	__rtl92s_dm_txpowertracking_callback_thermalmeter
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function _rtl92s_dm_txpowertracking_callback_thermalmeter
__rtl92s_dm_txpowertracking_callback_thermalmeter: ; @_rtl92s_dm_txpowertracking_callback_thermalmeter
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.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
	mov	x20, x0
	bl	_rtl_priv
	mov	x19, x0
	mov	x0, x20
	bl	_rtl_priv
	bl	_rtl_efuse
	mov	x22, x0
	mov	w8, #1
	str	w8, [x19]
Lloh0:
	adrp	x8, _RF90_PATH_A@GOTPAGE
Lloh1:
	ldr	x8, [x8, _RF90_PATH_A@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x8, _RF_T_METER@GOTPAGE
Lloh4:
	ldr	x8, [x8, _RF_T_METER@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	mov	x0, x20
	mov	w3, #31
	bl	_rtl_get_rfreg
	mov	x21, x0
Lloh6:
	adrp	x23, _COMP_POWER_TRACKING@GOTPAGE
Lloh7:
	ldr	x23, [x23, _COMP_POWER_TRACKING@GOTPAGEOFF]
	ldr	w1, [x23]
Lloh8:
	adrp	x24, _DBG_LOUD@GOTPAGE
Lloh9:
	ldr	x24, [x24, _DBG_LOUD@GOTPAGEOFF]
	ldr	w2, [x24]
	ldr	w8, [x19, #4]
	ldr	w9, [x22]
Lloh10:
	adrp	x3, l_.str@PAGE
Lloh11:
	add	x3, x3, l_.str@PAGEOFF
	stp	x8, x9, [sp]
	mov	x0, x19
	mov	x4, x21
	bl	_RT_TRACE
	cbz	w21, LBB0_4
; %bb.1:
	str	w21, [x19, #4]
	mov	x0, x19
	bl	_hal_get_firmwareversion
	cmp	w0, #53
	b.lt	LBB0_3
; %bb.2:
Lloh12:
	adrp	x8, _FW_CMD_TXPWR_TRACK_THERMAL@GOTPAGE
Lloh13:
	ldr	x8, [x8, _FW_CMD_TXPWR_TRACK_THERMAL@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_rtl92s_phy_set_fw_cmd
	b	LBB0_4
LBB0_3:
Lloh15:
	adrp	x8, _FW_TXPWR_TRACK_THERMAL@GOTPAGE
Lloh16:
	ldr	x8, [x8, _FW_TXPWR_TRACK_THERMAL@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	ldr	x9, [x19, #16]
	ldr	w9, [x9]
	orr	w8, w8, w21, lsl #16
	orr	w21, w8, w9, lsl #8
	ldr	w1, [x23]
	ldr	w2, [x24]
Lloh18:
	adrp	x3, l_.str.1@PAGE
Lloh19:
	add	x3, x3, l_.str.1@PAGEOFF
	mov	x0, x19
	mov	x4, x21
	bl	_RT_TRACE
Lloh20:
	adrp	x8, _WFM5@GOTPAGE
Lloh21:
	ldr	x8, [x8, _WFM5@GOTPAGEOFF]
Lloh22:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x21
	bl	_rtl_write_dword
	mov	x0, x20
	bl	_rtl92s_phy_chk_fwcmd_iodone
LBB0_4:
	str	xzr, [x19, #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
	add	sp, sp, #80
	ret
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_RF90_PATH_A,4,2                ; @RF90_PATH_A
	.comm	_RF_T_METER,4,2                 ; @RF_T_METER
	.comm	_COMP_POWER_TRACKING,4,2        ; @COMP_POWER_TRACKING
	.comm	_DBG_LOUD,4,2                   ; @DBG_LOUD
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Readback Thermal Meter = 0x%x pre thermal meter 0x%x eeprom_thermal meter 0x%x\n"

	.comm	_FW_CMD_TXPWR_TRACK_THERMAL,4,2 ; @FW_CMD_TXPWR_TRACK_THERMAL
	.comm	_FW_TXPWR_TRACK_THERMAL,4,2     ; @FW_TXPWR_TRACK_THERMAL
l_.str.1:                               ; @.str.1
	.asciz	"Write to FW Thermal Val = 0x%x\n"

	.comm	_WFM5,4,2                       ; @WFM5
	.no_dead_strip	__rtl92s_dm_txpowertracking_callback_thermalmeter
.subsections_via_symbols
