	.file	"extr_efuse.c_efuse_power_switch.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	efuse_power_switch
	.type	efuse_power_switch, @function
efuse_power_switch:
.LFB0:
	.cfi_startproc
	endbr64
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	mov	r13d, edx
	push	r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	mov	r12, rdi
	push	rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	push	rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	mov	ebx, esi
	sub	rsp, 8
	.cfi_def_cfa_offset 48
	call	rtl_priv@PLT
	mov	rdi, r12
	mov	rbp, rax
	call	rtl_priv@PLT
	mov	rdi, rax
	call	rtl_hal@PLT
	mov	r12, rax
	mov	rax, QWORD PTR [rax]
	test	r13d, r13d
	je	.L2
	mov	rdx, QWORD PTR 0[rbp]
	cmp	rax, QWORD PTR HARDWARE_TYPE_RTL8192SE[rip]
	mov	rdx, QWORD PTR [rdx]
	je	.L3
	cmp	rax, QWORD PTR HARDWARE_TYPE_RTL8192CE[rip]
	je	.L4
	cmp	rax, QWORD PTR HARDWARE_TYPE_RTL8192DE[rip]
	jne	.L28
.L4:
	mov	rax, QWORD PTR SYS_ISO_CTRL[rip]
	mov	rdi, rbp
	mov	esi, DWORD PTR [rdx+rax*4]
	call	rtl_read_word@PLT
	mov	rdx, QWORD PTR 0[rbp]
	mov	rcx, QWORD PTR [rdx]
	mov	rdx, QWORD PTR EFUSE_PWC_EV12V[rip]
	mov	edx, DWORD PTR [rcx+rdx*4]
	test	edx, eax
	je	.L29
.L5:
	mov	rax, QWORD PTR SYS_FUNC_EN[rip]
	mov	rdi, rbp
	mov	esi, DWORD PTR [rcx+rax*4]
	call	rtl_read_word@PLT
	mov	rdx, QWORD PTR 0[rbp]
	mov	rcx, QWORD PTR [rdx]
	mov	rdx, QWORD PTR EFUSE_FEN_ELDR[rip]
	mov	edx, DWORD PTR [rcx+rdx*4]
	test	edx, eax
	je	.L30
.L6:
	mov	rax, QWORD PTR SYS_CLK[rip]
	mov	rdi, rbp
	mov	esi, DWORD PTR [rcx+rax*4]
	call	rtl_read_word@PLT
	mov	rdx, QWORD PTR 0[rbp]
	mov	rsi, QWORD PTR EFUSE_ANA8M[rip]
	mov	rcx, QWORD PTR [rdx]
	mov	rdx, QWORD PTR EFUSE_LOADER_CLK_EN[rip]
	mov	edx, DWORD PTR [rcx+rdx*4]
	mov	esi, DWORD PTR [rcx+rsi*4]
	test	edx, eax
	je	.L8
	test	esi, eax
	je	.L8
.L9:
	test	ebx, ebx
	jne	.L31
.L18:
	mov	rax, QWORD PTR HARDWARE_TYPE_RTL8192SE[rip]
	cmp	QWORD PTR [r12], rax
	je	.L32
.L1:
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L2:
	.cfi_restore_state
	cmp	rax, QWORD PTR HARDWARE_TYPE_RTL8192CE[rip]
	je	.L14
	cmp	rax, QWORD PTR HARDWARE_TYPE_RTL8192DE[rip]
	jne	.L33
.L14:
	test	ebx, ebx
	jne	.L34
.L15:
	mov	rax, QWORD PTR HARDWARE_TYPE_RTL8192SE[rip]
	cmp	QWORD PTR [r12], rax
	jne	.L1
.L35:
	mov	rax, QWORD PTR 0[rbp]
	mov	rdx, QWORD PTR EFUSE_CLK[rip]
	mov	rax, QWORD PTR [rax]
	mov	esi, DWORD PTR [rax+rdx*4]
	mov	edx, 2
	jmp	.L26
	.p2align 4,,10
	.p2align 3
.L8:
	or	edx, eax
	mov	rax, QWORD PTR SYS_CLK[rip]
	mov	rdi, rbp
	or	edx, esi
	mov	esi, DWORD PTR [rcx+rax*4]
	call	rtl_write_word@PLT
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L3:
	test	ebx, ebx
	jne	.L20
.L21:
	mov	rax, QWORD PTR EFUSE_CLK[rip]
	mov	esi, DWORD PTR [rdx+rax*4]
	mov	edx, 3
.L26:
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	rdi, rbp
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	jmp	rtl_write_byte@PLT
	.p2align 4,,10
	.p2align 3
.L34:
	.cfi_restore_state
	mov	rax, QWORD PTR 0[rbp]
	mov	rdx, QWORD PTR EFUSE_TEST[rip]
	mov	rdi, rbp
	mov	rax, QWORD PTR [rax]
	mov	esi, DWORD PTR [rax+rdx*4]
	add	esi, 3
	call	rtl_read_byte@PLT
	mov	rcx, QWORD PTR EFUSE_TEST[rip]
	mov	rdi, rbp
	and	eax, 127
	mov	edx, eax
	mov	rax, QWORD PTR 0[rbp]
	mov	rax, QWORD PTR [rax]
	mov	esi, DWORD PTR [rax+rcx*4]
	add	esi, 3
	call	rtl_write_byte@PLT
	mov	rax, QWORD PTR HARDWARE_TYPE_RTL8192SE[rip]
	cmp	QWORD PTR [r12], rax
	jne	.L1
	jmp	.L35
	.p2align 4,,10
	.p2align 3
.L33:
	mov	rax, QWORD PTR 0[rbp]
	mov	rdx, QWORD PTR EFUSE_ACCESS[rip]
	mov	rdi, rbp
	mov	rax, QWORD PTR [rax]
	mov	esi, DWORD PTR [rax+rdx*4]
	xor	edx, edx
	call	rtl_write_byte@PLT
	test	ebx, ebx
	je	.L15
	jmp	.L34
	.p2align 4,,10
	.p2align 3
.L28:
	mov	rax, QWORD PTR EFUSE_ACCESS[rip]
	mov	rdi, rbp
	mov	esi, DWORD PTR [rdx+rax*4]
	mov	edx, 105
	call	rtl_write_byte@PLT
	mov	rax, QWORD PTR 0[rbp]
	mov	rcx, QWORD PTR [rax]
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L29:
	or	edx, eax
	mov	rax, QWORD PTR SYS_ISO_CTRL[rip]
	mov	rdi, rbp
	mov	esi, DWORD PTR [rcx+rax*4]
	call	rtl_write_word@PLT
	mov	rax, QWORD PTR 0[rbp]
	mov	rcx, QWORD PTR [rax]
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L31:
	mov	rax, QWORD PTR 0[rbp]
	mov	rdx, QWORD PTR [rax]
.L20:
	mov	rax, QWORD PTR EFUSE_TEST[rip]
	mov	rdi, rbp
	mov	esi, DWORD PTR [rdx+rax*4]
	add	esi, 3
	call	rtl_read_byte@PLT
	mov	ebx, eax
	mov	rax, QWORD PTR [r12]
	cmp	rax, QWORD PTR HARDWARE_TYPE_RTL8812AE[rip]
	je	.L36
	cmp	rax, QWORD PTR HARDWARE_TYPE_RTL8192SE[rip]
	je	.L11
	mov	eax, DWORD PTR VOLTAGE_V25[rip]
	and	ebx, 15
	sal	eax, 4
	or	ebx, eax
.L11:
	mov	rax, QWORD PTR 0[rbp]
	mov	rcx, QWORD PTR EFUSE_TEST[rip]
	or	bl, -128
	mov	rdi, rbp
	mov	edx, ebx
	mov	rax, QWORD PTR [rax]
	mov	esi, DWORD PTR [rax+rcx*4]
	add	esi, 3
	call	rtl_write_byte@PLT
	jmp	.L18
	.p2align 4,,10
	.p2align 3
.L30:
	or	edx, eax
	mov	rax, QWORD PTR SYS_FUNC_EN[rip]
	mov	rdi, rbp
	mov	esi, DWORD PTR [rcx+rax*4]
	call	rtl_write_word@PLT
	mov	rax, QWORD PTR 0[rbp]
	mov	rcx, QWORD PTR [rax]
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L36:
	mov	edi, 3
	call	BIT@PLT
	mov	edi, 4
	mov	r13d, eax
	call	BIT@PLT
	mov	edi, 5
	or	r13d, eax
	call	BIT@PLT
	mov	edi, 6
	or	r13d, eax
	call	BIT@PLT
	or	r13d, eax
	mov	eax, DWORD PTR VOLTAGE_V25[rip]
	not	r13d
	and	ebx, r13d
	sal	eax, 3
	or	ebx, eax
	jmp	.L11
.L32:
	mov	rax, QWORD PTR 0[rbp]
	mov	rdx, QWORD PTR [rax]
	jmp	.L21
	.cfi_endproc
.LFE0:
	.size	efuse_power_switch, .-efuse_power_switch
	.comm	VOLTAGE_V25,4,4
	.comm	SYS_ISO_CTRL,8,8
	.comm	SYS_FUNC_EN,8,8
	.comm	SYS_CLK,8,8
	.comm	HARDWARE_TYPE_RTL8812AE,8,8
	.comm	HARDWARE_TYPE_RTL8192SE,8,8
	.comm	HARDWARE_TYPE_RTL8192DE,8,8
	.comm	HARDWARE_TYPE_RTL8192CE,8,8
	.comm	EFUSE_TEST,8,8
	.comm	EFUSE_PWC_EV12V,8,8
	.comm	EFUSE_LOADER_CLK_EN,8,8
	.comm	EFUSE_FEN_ELDR,8,8
	.comm	EFUSE_CLK,8,8
	.comm	EFUSE_ANA8M,8,8
	.comm	EFUSE_ACCESS,8,8
	.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_efuse.c_efuse_power_switch.c"
	.text
	.align	2
	.global	efuse_power_switch
	.syntax unified
	.arm
	.fpu softvfp
	.type	efuse_power_switch, %function
efuse_power_switch:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, lr}
	mov	r5, r2
	mov	r6, r0
	mov	r7, r1
	bl	rtl_priv
	mov	r4, r0
	mov	r0, r6
	bl	rtl_priv
	bl	rtl_hal
	cmp	r5, #0
	mov	r6, r0
	beq	.L2
	ldr	r5, .L34
	ldr	r3, [r0]
	ldr	r1, [r5]
	ldr	r2, [r4]
	cmp	r3, r1
	ldr	r1, [r2]
	beq	.L3
	ldr	r2, .L34+4
	ldr	r2, [r2]
	cmp	r3, r2
	beq	.L4
	ldr	r2, .L34+8
	ldr	r2, [r2]
	cmp	r3, r2
	bne	.L27
.L4:
	ldr	r8, .L34+12
	mov	r0, r4
	ldr	r3, [r8]
	ldr	r1, [r1, r3, lsl #2]
	bl	rtl_read_word
	ldr	r3, [r4]
	ldr	r2, .L34+16
	ldr	r3, [r3]
	ldr	r2, [r2]
	ldr	r2, [r3, r2, lsl #2]
	tst	r2, r0
	beq	.L28
.L5:
	ldr	r8, .L34+20
	mov	r0, r4
	ldr	r2, [r8]
	ldr	r1, [r3, r2, lsl #2]
	bl	rtl_read_word
	ldr	r3, [r4]
	ldr	r2, .L34+24
	ldr	r3, [r3]
	ldr	r2, [r2]
	ldr	r2, [r3, r2, lsl #2]
	tst	r2, r0
	beq	.L29
.L6:
	ldr	r8, .L34+28
	mov	r0, r4
	ldr	r2, [r8]
	ldr	r1, [r3, r2, lsl #2]
	bl	rtl_read_word
	ldr	r2, [r4]
	ldr	r3, .L34+32
	ldr	r1, [r2]
	ldr	r3, [r3]
	ldr	r2, .L34+36
	ldr	r3, [r1, r3, lsl #2]
	ldr	r2, [r2]
	tst	r3, r0
	ldr	r2, [r1, r2, lsl #2]
	beq	.L8
	tst	r2, r0
	beq	.L8
.L9:
	cmp	r7, #0
	bne	.L30
.L18:
	ldr	r2, [r6]
	ldr	r3, [r5]
	cmp	r2, r3
	popne	{r4, r5, r6, r7, r8, r9, r10, pc}
	ldr	r3, [r4]
	ldr	r1, [r3]
	b	.L21
.L2:
	ldr	r2, .L34+4
	ldr	r3, [r0]
	ldr	r2, [r2]
	cmp	r3, r2
	beq	.L14
	ldr	r2, .L34+8
	ldr	r2, [r2]
	cmp	r3, r2
	bne	.L31
.L14:
	cmp	r7, #0
	bne	.L32
.L15:
	ldr	r3, .L34
	ldr	r2, [r6]
	ldr	r3, [r3]
	cmp	r2, r3
	popne	{r4, r5, r6, r7, r8, r9, r10, pc}
	ldr	r3, [r4]
	ldr	r2, .L34+40
	ldr	r3, [r3]
	ldr	r2, [r2]
	mov	r0, r4
	pop	{r4, r5, r6, r7, r8, r9, r10, lr}
	ldr	r1, [r3, r2, lsl #2]
	mov	r2, #2
	b	rtl_write_byte
.L8:
	ldr	ip, [r8]
	orr	r0, r3, r0
	orr	r2, r0, r2
	ldr	r1, [r1, ip, lsl #2]
	mov	r0, r4
	bl	rtl_write_word
	b	.L9
.L3:
	cmp	r7, #0
	bne	.L20
.L21:
	ldr	r3, .L34+40
	mov	r0, r4
	pop	{r4, r5, r6, r7, r8, r9, r10, lr}
	ldr	r3, [r3]
	mov	r2, #3
	ldr	r1, [r1, r3, lsl #2]
	b	rtl_write_byte
.L32:
	ldr	r3, [r4]
	ldr	r5, .L34+44
	ldr	r3, [r3]
	ldr	r2, [r5]
	mov	r0, r4
	ldr	r1, [r3, r2, lsl #2]
	add	r1, r1, #3
	bl	rtl_read_byte
	ldr	r3, [r4]
	ldr	r1, [r5]
	ldr	r3, [r3]
	and	r2, r0, #127
	ldr	r1, [r3, r1, lsl #2]
	mov	r0, r4
	add	r1, r1, #3
	bl	rtl_write_byte
	b	.L15
.L31:
	ldr	r3, [r4]
	ldr	r2, .L34+48
	ldr	r3, [r3]
	ldr	r1, [r2]
	mov	r0, r4
	mov	r2, r5
	ldr	r1, [r3, r1, lsl #2]
	bl	rtl_write_byte
	cmp	r7, #0
	beq	.L15
	b	.L32
.L27:
	ldr	r3, .L34+48
	mov	r2, #105
	ldr	r3, [r3]
	mov	r0, r4
	ldr	r1, [r1, r3, lsl #2]
	bl	rtl_write_byte
	ldr	r3, [r4]
	ldr	r3, [r3]
	b	.L5
.L28:
	ldr	r1, [r8]
	orr	r2, r2, r0
	ldr	r1, [r3, r1, lsl #2]
	mov	r0, r4
	bl	rtl_write_word
	ldr	r3, [r4]
	ldr	r3, [r3]
	b	.L5
.L30:
	ldr	r3, [r4]
	ldr	r1, [r3]
.L20:
	ldr	r8, .L34+44
	mov	r0, r4
	ldr	r3, [r8]
	ldr	r1, [r1, r3, lsl #2]
	add	r1, r1, #3
	bl	rtl_read_byte
	ldr	r2, .L34+52
	ldr	r3, [r6]
	ldr	r1, [r2]
	mov	r7, r0
	cmp	r3, r1
	beq	.L33
	ldr	r2, [r5]
	cmp	r3, r2
	ldrne	r3, .L34+56
	andne	r7, r0, #15
	ldrne	r0, [r3]
	orrne	r7, r7, r0, lsl #4
.L11:
	ldr	r3, [r4]
	ldr	r1, [r8]
	ldr	r3, [r3]
	mov	r0, r4
	ldr	r1, [r3, r1, lsl #2]
	orr	r2, r7, #128
	add	r1, r1, #3
	bl	rtl_write_byte
	b	.L18
.L29:
	ldr	r1, [r8]
	orr	r2, r2, r0
	ldr	r1, [r3, r1, lsl #2]
	mov	r0, r4
	bl	rtl_write_word
	ldr	r3, [r4]
	ldr	r3, [r3]
	b	.L6
.L33:
	mov	r0, #3
	bl	BIT
	mov	r9, r0
	mov	r0, #4
	bl	BIT
	mov	r3, r0
	mov	r0, #5
	orr	r9, r9, r3
	bl	BIT
	mov	r3, r0
	mov	r0, #6
	orr	r9, r9, r3
	bl	BIT
	ldr	r3, .L34+56
	orr	r9, r9, r0
	ldr	r3, [r3]
	bic	r7, r7, r9
	orr	r7, r7, r3, lsl #3
	b	.L11
.L35:
	.align	2
.L34:
	.word	HARDWARE_TYPE_RTL8192SE
	.word	HARDWARE_TYPE_RTL8192CE
	.word	HARDWARE_TYPE_RTL8192DE
	.word	SYS_ISO_CTRL
	.word	EFUSE_PWC_EV12V
	.word	SYS_FUNC_EN
	.word	EFUSE_FEN_ELDR
	.word	SYS_CLK
	.word	EFUSE_LOADER_CLK_EN
	.word	EFUSE_ANA8M
	.word	EFUSE_CLK
	.word	EFUSE_TEST
	.word	EFUSE_ACCESS
	.word	HARDWARE_TYPE_RTL8812AE
	.word	VOLTAGE_V25
	.size	efuse_power_switch, .-efuse_power_switch
	.comm	VOLTAGE_V25,4,4
	.comm	SYS_ISO_CTRL,4,4
	.comm	SYS_FUNC_EN,4,4
	.comm	SYS_CLK,4,4
	.comm	HARDWARE_TYPE_RTL8812AE,4,4
	.comm	HARDWARE_TYPE_RTL8192SE,4,4
	.comm	HARDWARE_TYPE_RTL8192DE,4,4
	.comm	HARDWARE_TYPE_RTL8192CE,4,4
	.comm	EFUSE_TEST,4,4
	.comm	EFUSE_PWC_EV12V,4,4
	.comm	EFUSE_LOADER_CLK_EN,4,4
	.comm	EFUSE_FEN_ELDR,4,4
	.comm	EFUSE_CLK,4,4
	.comm	EFUSE_ANA8M,4,4
	.comm	EFUSE_ACCESS,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
