	.file	"extr_eeprom.c_mt76x2_get_power_info.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	mt76x2_get_power_info
	.type	mt76x2_get_power_info, @function
mt76x2_get_power_info:
.LFB0:
	.cfi_startproc
	endbr64
	push	r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	push	r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	mov	r12, rdx
	mov	edx, 32
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	mov	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	mov	rbx, rsi
	xor	esi, esi
	mov	rdi, rbx
	call	memset@PLT
	mov	esi, DWORD PTR MT_EE_TX_POWER_DELTA_BW40[rip]
	mov	rdi, rbp
	call	mt76x02_eeprom_get@PLT
	mov	esi, DWORD PTR MT_EE_TX_POWER_DELTA_BW80[rip]
	mov	rdi, rbp
	mov	r13d, eax
	call	mt76x02_eeprom_get@PLT
	mov	r14d, eax
	mov	rax, QWORD PTR NL80211_BAND_5GHZ[rip]
	cmp	QWORD PTR [r12], rax
	je	.L12
	mov	r8d, DWORD PTR MT_EE_TX_POWER_0_START_2G[rip]
	xor	ecx, ecx
	mov	rdx, r12
	mov	rsi, rbx
	mov	rdi, rbp
	call	mt76x2_get_power_info_2g@PLT
	mov	rdi, rbp
	mov	ecx, 1
	mov	rdx, r12
	mov	r8d, DWORD PTR MT_EE_TX_POWER_1_START_2G[rip]
	mov	rsi, rbx
	call	mt76x2_get_power_info_2g@PLT
	mov	rdi, rbp
	call	mt76x2_tssi_enabled@PLT
	test	rax, rax
	je	.L4
.L6:
	mov	rax, QWORD PTR 16[rbx]
	mov	eax, DWORD PTR [rax]
	mov	DWORD PTR 24[rbx], eax
.L5:
	mov	edi, r13d
	call	mt76x02_rate_power_val@PLT
	mov	edi, r14d
	mov	QWORD PTR 8[rbx], rax
	call	mt76x02_rate_power_val@PLT
	mov	QWORD PTR [rbx], rax
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L12:
	.cfi_restore_state
	mov	r8d, DWORD PTR MT_EE_TX_POWER_0_START_5G[rip]
	xor	ecx, ecx
	mov	rdx, r12
	mov	rsi, rbx
	mov	rdi, rbp
	sar	r13d, 8
	call	mt76x2_get_power_info_5g@PLT
	mov	rdi, rbp
	mov	ecx, 1
	mov	rdx, r12
	mov	r8d, DWORD PTR MT_EE_TX_POWER_1_START_5G[rip]
	mov	rsi, rbx
	call	mt76x2_get_power_info_5g@PLT
	mov	rdi, rbp
	call	mt76x2_tssi_enabled@PLT
	test	rax, rax
	jne	.L6
.L4:
	mov	edi, DWORD PTR 24[rbx]
	call	mt76x02_field_valid@PLT
	test	eax, eax
	je	.L6
	jmp	.L5
	.cfi_endproc
.LFE0:
	.size	mt76x2_get_power_info, .-mt76x2_get_power_info
	.comm	NL80211_BAND_5GHZ,8,8
	.comm	MT_EE_TX_POWER_DELTA_BW80,4,4
	.comm	MT_EE_TX_POWER_DELTA_BW40,4,4
	.comm	MT_EE_TX_POWER_1_START_5G,4,4
	.comm	MT_EE_TX_POWER_1_START_2G,4,4
	.comm	MT_EE_TX_POWER_0_START_5G,4,4
	.comm	MT_EE_TX_POWER_0_START_2G,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_eeprom.c_mt76x2_get_power_info.c"
	.text
	.align	2
	.global	mt76x2_get_power_info
	.syntax unified
	.arm
	.fpu softvfp
	.type	mt76x2_get_power_info, %function
mt76x2_get_power_info:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	mov	r5, r0
	sub	sp, sp, #8
	mov	r6, r2
	mov	r0, r1
	mov	r2, #16
	mov	r4, r1
	mov	r1, #0
	bl	memset
	ldr	r3, .L13
	mov	r0, r5
	ldr	r1, [r3]
	bl	mt76x02_eeprom_get
	ldr	r3, .L13+4
	mov	r7, r0
	ldr	r1, [r3]
	mov	r0, r5
	bl	mt76x02_eeprom_get
	ldr	r3, .L13+8
	ldr	r2, [r6]
	ldr	r3, [r3]
	mov	r8, r0
	cmp	r2, r3
	beq	.L12
	ldr	r2, .L13+12
	mov	r3, #0
	ldr	r1, [r2]
	mov	r0, r5
	mov	r2, r6
	str	r1, [sp]
	mov	r1, r4
	bl	mt76x2_get_power_info_2g
	ldr	r3, .L13+16
	mov	r2, r6
	ldr	r1, [r3]
	mov	r0, r5
	mov	r3, #1
	str	r1, [sp]
	mov	r1, r4
	bl	mt76x2_get_power_info_2g
	mov	r0, r5
	bl	mt76x2_tssi_enabled
	cmp	r0, #0
	beq	.L4
.L6:
	ldr	r3, [r4, #8]
	ldr	r3, [r3]
	str	r3, [r4, #12]
.L5:
	mov	r0, r7
	bl	mt76x02_rate_power_val
	mov	r3, r0
	mov	r0, r8
	str	r3, [r4, #4]
	bl	mt76x02_rate_power_val
	str	r0, [r4]
	add	sp, sp, #8
	@ sp needed
	pop	{r4, r5, r6, r7, r8, pc}
.L12:
	ldr	r2, .L13+20
	mov	r3, #0
	ldr	r1, [r2]
	mov	r0, r5
	mov	r2, r6
	str	r1, [sp]
	mov	r1, r4
	bl	mt76x2_get_power_info_5g
	ldr	r3, .L13+24
	mov	r2, r6
	ldr	r1, [r3]
	mov	r0, r5
	mov	r3, #1
	str	r1, [sp]
	mov	r1, r4
	bl	mt76x2_get_power_info_5g
	mov	r0, r5
	bl	mt76x2_tssi_enabled
	cmp	r0, #0
	asr	r7, r7, #8
	bne	.L6
.L4:
	ldr	r0, [r4, #12]
	bl	mt76x02_field_valid
	cmp	r0, #0
	beq	.L6
	b	.L5
.L14:
	.align	2
.L13:
	.word	MT_EE_TX_POWER_DELTA_BW40
	.word	MT_EE_TX_POWER_DELTA_BW80
	.word	NL80211_BAND_5GHZ
	.word	MT_EE_TX_POWER_0_START_2G
	.word	MT_EE_TX_POWER_1_START_2G
	.word	MT_EE_TX_POWER_0_START_5G
	.word	MT_EE_TX_POWER_1_START_5G
	.size	mt76x2_get_power_info, .-mt76x2_get_power_info
	.comm	NL80211_BAND_5GHZ,4,4
	.comm	MT_EE_TX_POWER_DELTA_BW80,4,4
	.comm	MT_EE_TX_POWER_DELTA_BW40,4,4
	.comm	MT_EE_TX_POWER_1_START_5G,4,4
	.comm	MT_EE_TX_POWER_1_START_2G,4,4
	.comm	MT_EE_TX_POWER_0_START_5G,4,4
	.comm	MT_EE_TX_POWER_0_START_2G,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
