	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mt7615_eeprom_get_power_index  ## -- Begin function mt7615_eeprom_get_power_index
	.p2align	4, 0x90
_mt7615_eeprom_get_power_index:         ## @mt7615_eeprom_get_power_index
	.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
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	cmpl	$4, %edx
	jl	LBB0_2
## %bb.1:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_13
LBB0_2:
	movl	%edx, %r14d
	movq	%rsi, %rbx
	movq	(%rsi), %rsi
	callq	_mt7615_ext_pa_enabled
	movq	(%rbx), %rcx
	movq	_NL80211_BAND_2GHZ@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	testq	%rax, %rax
	je	LBB0_6
## %bb.3:
	cmpq	%rdx, %rcx
	jne	LBB0_5
## %bb.4:
	movq	_MT_EE_EXT_PA_2G_TARGET_POWER@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	jmp	LBB0_13
LBB0_6:
	cmpq	%rdx, %rcx
	jne	LBB0_8
## %bb.7:
	movq	_MT_EE_TX0_2G_TARGET_POWER@GOTPCREL(%rip), %rcx
	leal	(%r14,%r14,2), %eax
	addl	%eax, %eax
	jmp	LBB0_12
LBB0_5:
	movq	_MT_EE_EXT_PA_5G_TARGET_POWER@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	jmp	LBB0_13
LBB0_8:
	movl	8(%rbx), %edi
	callq	_mt7615_get_channel_group
                                        ## kill: def $eax killed $eax def $rax
	decl	%r14d
	cmpl	$2, %r14d
	ja	LBB0_9
## %bb.10:
	movslq	%r14d, %rcx
	leaq	l_switch.table.mt7615_eeprom_get_power_index(%rip), %rdx
	movq	(%rdx,%rcx,8), %rcx
	jmp	LBB0_11
LBB0_9:
	movq	_MT_EE_TX0_5G_G0_TARGET_POWER@GOTPCREL(%rip), %rcx
LBB0_11:
	leal	(%rax,%rax,4), %eax
LBB0_12:
	addl	(%rcx), %eax
LBB0_13:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_NL80211_BAND_2GHZ,8,3          ## @NL80211_BAND_2GHZ
	.comm	_MT_EE_EXT_PA_2G_TARGET_POWER,4,2 ## @MT_EE_EXT_PA_2G_TARGET_POWER
	.comm	_MT_EE_EXT_PA_5G_TARGET_POWER,4,2 ## @MT_EE_EXT_PA_5G_TARGET_POWER
	.comm	_MT_EE_TX0_2G_TARGET_POWER,4,2  ## @MT_EE_TX0_2G_TARGET_POWER
	.comm	_MT_EE_TX1_5G_G0_TARGET_POWER,4,2 ## @MT_EE_TX1_5G_G0_TARGET_POWER
	.comm	_MT_EE_TX2_5G_G0_TARGET_POWER,4,2 ## @MT_EE_TX2_5G_G0_TARGET_POWER
	.comm	_MT_EE_TX3_5G_G0_TARGET_POWER,4,2 ## @MT_EE_TX3_5G_G0_TARGET_POWER
	.comm	_MT_EE_TX0_5G_G0_TARGET_POWER,4,2 ## @MT_EE_TX0_5G_G0_TARGET_POWER
	.section	__DATA,__const
	.p2align	3                               ## @switch.table.mt7615_eeprom_get_power_index
l_switch.table.mt7615_eeprom_get_power_index:
	.quad	_MT_EE_TX1_5G_G0_TARGET_POWER
	.quad	_MT_EE_TX2_5G_G0_TARGET_POWER
	.quad	_MT_EE_TX3_5G_G0_TARGET_POWER

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mt7615_eeprom_get_power_index  ; -- Begin function mt7615_eeprom_get_power_index
	.p2align	2
_mt7615_eeprom_get_power_index:         ; @mt7615_eeprom_get_power_index
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	cmp	w2, #4
	b.lt	LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _EINVAL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_12
LBB0_2:
	mov	x19, x2
	mov	x20, x1
	ldr	x1, [x1]
	bl	_mt7615_ext_pa_enabled
	ldr	x8, [x20]
Lloh3:
	adrp	x9, _NL80211_BAND_2GHZ@GOTPAGE
Lloh4:
	ldr	x9, [x9, _NL80211_BAND_2GHZ@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x8, x9
	cbz	x0, LBB0_5
; %bb.3:
	b.ne	LBB0_7
; %bb.4:
Lloh6:
	adrp	x8, _MT_EE_EXT_PA_2G_TARGET_POWER@GOTPAGE
Lloh7:
	ldr	x8, [x8, _MT_EE_EXT_PA_2G_TARGET_POWER@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
	b	LBB0_12
LBB0_5:
	b.ne	LBB0_8
; %bb.6:
Lloh9:
	adrp	x8, _MT_EE_TX0_2G_TARGET_POWER@GOTPAGE
Lloh10:
	ldr	x8, [x8, _MT_EE_TX0_2G_TARGET_POWER@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	mov	w9, #6
	madd	w0, w19, w9, w8
	b	LBB0_12
LBB0_7:
Lloh12:
	adrp	x8, _MT_EE_EXT_PA_5G_TARGET_POWER@GOTPAGE
Lloh13:
	ldr	x8, [x8, _MT_EE_EXT_PA_5G_TARGET_POWER@GOTPAGEOFF]
Lloh14:
	ldr	w0, [x8]
	b	LBB0_12
LBB0_8:
	ldr	w0, [x20, #8]
	bl	_mt7615_get_channel_group
	sub	w8, w19, #1
	cmp	w8, #2
	b.hi	LBB0_10
; %bb.9:
Lloh15:
	adrp	x9, l_switch.table.mt7615_eeprom_get_power_index@PAGE
Lloh16:
	add	x9, x9, l_switch.table.mt7615_eeprom_get_power_index@PAGEOFF
	ldr	x8, [x9, w8, sxtw #3]
	b	LBB0_11
LBB0_10:
Lloh17:
	adrp	x8, _MT_EE_TX0_5G_G0_TARGET_POWER@GOTPAGE
Lloh18:
	ldr	x8, [x8, _MT_EE_TX0_5G_G0_TARGET_POWER@GOTPAGEOFF]
LBB0_11:
	ldr	w8, [x8]
	add	w9, w0, w0, lsl #2
	add	w0, w8, w9
LBB0_12:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_NL80211_BAND_2GHZ,8,3          ; @NL80211_BAND_2GHZ
	.comm	_MT_EE_EXT_PA_2G_TARGET_POWER,4,2 ; @MT_EE_EXT_PA_2G_TARGET_POWER
	.comm	_MT_EE_EXT_PA_5G_TARGET_POWER,4,2 ; @MT_EE_EXT_PA_5G_TARGET_POWER
	.comm	_MT_EE_TX0_2G_TARGET_POWER,4,2  ; @MT_EE_TX0_2G_TARGET_POWER
	.comm	_MT_EE_TX1_5G_G0_TARGET_POWER,4,2 ; @MT_EE_TX1_5G_G0_TARGET_POWER
	.comm	_MT_EE_TX2_5G_G0_TARGET_POWER,4,2 ; @MT_EE_TX2_5G_G0_TARGET_POWER
	.comm	_MT_EE_TX3_5G_G0_TARGET_POWER,4,2 ; @MT_EE_TX3_5G_G0_TARGET_POWER
	.comm	_MT_EE_TX0_5G_G0_TARGET_POWER,4,2 ; @MT_EE_TX0_5G_G0_TARGET_POWER
	.section	__DATA,__const
	.p2align	3                               ; @switch.table.mt7615_eeprom_get_power_index
l_switch.table.mt7615_eeprom_get_power_index:
	.quad	_MT_EE_TX1_5G_G0_TARGET_POWER
	.quad	_MT_EE_TX2_5G_G0_TARGET_POWER
	.quad	_MT_EE_TX3_5G_G0_TARGET_POWER

.subsections_via_symbols
