	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_rtl8723be_gpio_radio_on_off_checking ## -- Begin function rtl8723be_gpio_radio_on_off_checking
	.p2align	4, 0x90
_rtl8723be_gpio_radio_on_off_checking:  ## @rtl8723be_gpio_radio_on_off_checking
	.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	%rsi, %r14
	movq	%rdi, %rbx
	callq	_rtl_priv
	movq	%rax, %r12
	movq	%rbx, %rdi
	callq	_rtl_priv
	movq	%rax, %rdi
	callq	_rtl_psc
	xorl	%ebx, %ebx
	cmpq	$0, 8(%r12)
	jne	LBB0_17
## %bb.1:
	movq	%rax, %r15
	cmpq	$0, 16(%rax)
	jne	LBB0_17
## %bb.2:
	movq	%r12, %rdi
	callq	_spin_lock
	cmpl	$0, (%r15)
	je	LBB0_4
## %bb.3:
	movq	%r12, %rdi
	callq	_spin_unlock
	jmp	LBB0_17
LBB0_4:
	movl	$1, (%r15)
	movq	%r12, %rdi
	callq	_spin_unlock
	movq	_REG_GPIO_IO_SEL_2@GOTPCREL(%rip), %rax
	movl	(%rax), %r13d
	movq	%r12, %rdi
	movl	%r13d, %esi
	callq	_rtl_read_byte
	movl	%eax, %ebx
	movl	$1, %edi
	callq	_BIT
	notl	%eax
	andl	%eax, %ebx
	movq	%r12, %rdi
	movl	%r13d, %esi
	movl	%ebx, %edx
	callq	_rtl_write_byte
	movq	_REG_GPIO_PIN_CTRL_2@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_rtl_read_byte
	movl	%eax, %ebx
	movq	16(%r12), %r13
	movl	$1, %edi
	callq	_BIT
	andl	%ebx, %eax
	testq	%r13, %r13
	je	LBB0_6
## %bb.5:
	testl	%eax, %eax
	movq	_ERFOFF@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_ERFON@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movl	%eax, %ecx
	cmovel	%edx, %ecx
	jmp	LBB0_7
LBB0_6:
	testl	%eax, %eax
	movq	_ERFON@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_ERFOFF@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%edx, %ecx
	cmovel	%eax, %ecx
LBB0_7:
	movl	4(%r15), %esi
	testl	%esi, %esi
	je	LBB0_10
## %bb.8:
	cmpl	%edx, %ecx
	jne	LBB0_10
## %bb.9:
	xorl	%ebx, %ebx
	leaq	L_.str(%rip), %rcx
	jmp	LBB0_13
LBB0_10:
	testl	%esi, %esi
	jne	LBB0_14
## %bb.11:
	cmpl	%eax, %ecx
	jne	LBB0_14
## %bb.12:
	movl	$1, %ebx
	leaq	L_.str.1(%rip), %rcx
LBB0_13:
	movq	_COMP_RF@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_DBG_DMESG@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r12, %rdi
	callq	_RT_TRACE
	movl	%ebx, 4(%r15)
LBB0_16:
	movq	%r12, %rdi
	callq	_spin_lock
	movl	$0, (%r15)
	movq	%r12, %rdi
	callq	_spin_unlock
	movl	$1, (%r14)
	xorl	%ebx, %ebx
	cmpl	$0, 4(%r15)
	sete	%bl
LBB0_17:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_14:
	movq	_RT_RF_OFF_LEVL_HALT_NIC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	testl	%esi, 8(%r15)
	je	LBB0_16
## %bb.15:
	movq	%r15, %rdi
	callq	_RT_SET_PS_LEVEL
	jmp	LBB0_16
	.cfi_endproc
                                        ## -- End function
	.comm	_REG_GPIO_IO_SEL_2,4,2          ## @REG_GPIO_IO_SEL_2
	.comm	_REG_GPIO_PIN_CTRL_2,4,2        ## @REG_GPIO_PIN_CTRL_2
	.comm	_ERFOFF,4,2                     ## @ERFOFF
	.comm	_ERFON,4,2                      ## @ERFON
	.comm	_COMP_RF,4,2                    ## @COMP_RF
	.comm	_DBG_DMESG,4,2                  ## @DBG_DMESG
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"GPIOChangeRF  - HW Radio ON, RF ON\n"

L_.str.1:                               ## @.str.1
	.asciz	"GPIOChangeRF  - HW Radio OFF, RF OFF\n"

	.comm	_RT_RF_OFF_LEVL_HALT_NIC,4,2    ## @RT_RF_OFF_LEVL_HALT_NIC
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_rtl8723be_gpio_radio_on_off_checking ; -- Begin function rtl8723be_gpio_radio_on_off_checking
	.p2align	2
_rtl8723be_gpio_radio_on_off_checking:  ; @rtl8723be_gpio_radio_on_off_checking
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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	x19, x1
	mov	x21, x0
	bl	_rtl_priv
	mov	x20, x0
	mov	x0, x21
	bl	_rtl_priv
	bl	_rtl_psc
	ldr	x8, [x20, #8]
	cbnz	x8, LBB0_2
; %bb.1:
	mov	x21, x0
	ldr	x8, [x0, #16]
	cbz	x8, LBB0_4
LBB0_2:
	mov	w0, #0
LBB0_3:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_4:
	mov	x0, x20
	bl	_spin_lock
	ldr	w8, [x21]
	cbz	w8, LBB0_6
; %bb.5:
	mov	x0, x20
	bl	_spin_unlock
	mov	w0, #0
	b	LBB0_3
LBB0_6:
	mov	w8, #1
	str	w8, [x21]
	mov	x0, x20
	bl	_spin_unlock
Lloh0:
	adrp	x8, _REG_GPIO_IO_SEL_2@GOTPAGE
Lloh1:
	ldr	x8, [x8, _REG_GPIO_IO_SEL_2@GOTPAGEOFF]
Lloh2:
	ldr	w22, [x8]
	mov	x0, x20
	mov	x1, x22
	bl	_rtl_read_byte
	mov	x23, x0
	mov	w0, #1
	bl	_BIT
	bic	w2, w23, w0
	mov	x0, x20
	mov	x1, x22
	bl	_rtl_write_byte
Lloh3:
	adrp	x8, _REG_GPIO_PIN_CTRL_2@GOTPAGE
Lloh4:
	ldr	x8, [x8, _REG_GPIO_PIN_CTRL_2@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_rtl_read_byte
	mov	x22, x0
	ldr	x23, [x20, #16]
	mov	w0, #1
	bl	_BIT
	and	w10, w0, w22
	cbz	x23, LBB0_8
; %bb.7:
Lloh6:
	adrp	x8, _ERFOFF@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ERFOFF@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
Lloh9:
	adrp	x9, _ERFON@GOTPAGE
Lloh10:
	ldr	x9, [x9, _ERFON@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	cmp	w10, #0
	csel	w10, w9, w8, eq
	ldr	w11, [x21, #4]
	cbnz	w11, LBB0_9
	b	LBB0_11
LBB0_8:
Lloh12:
	adrp	x8, _ERFON@GOTPAGE
Lloh13:
	ldr	x8, [x8, _ERFON@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x8]
Lloh15:
	adrp	x8, _ERFOFF@GOTPAGE
Lloh16:
	ldr	x8, [x8, _ERFOFF@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	cmp	w10, #0
	csel	w10, w8, w9, eq
	ldr	w11, [x21, #4]
	cbz	w11, LBB0_11
LBB0_9:
	cmp	w10, w9
	b.ne	LBB0_11
; %bb.10:
	mov	w22, #0
Lloh18:
	adrp	x3, l_.str@PAGE
Lloh19:
	add	x3, x3, l_.str@PAGEOFF
	b	LBB0_14
LBB0_11:
	cbnz	w11, LBB0_16
; %bb.12:
	cmp	w10, w8
	b.ne	LBB0_16
; %bb.13:
	mov	w22, #1
Lloh20:
	adrp	x3, l_.str.1@PAGE
Lloh21:
	add	x3, x3, l_.str.1@PAGEOFF
LBB0_14:
Lloh22:
	adrp	x8, _COMP_RF@GOTPAGE
Lloh23:
	ldr	x8, [x8, _COMP_RF@GOTPAGEOFF]
Lloh24:
	ldr	w1, [x8]
Lloh25:
	adrp	x8, _DBG_DMESG@GOTPAGE
Lloh26:
	ldr	x8, [x8, _DBG_DMESG@GOTPAGEOFF]
Lloh27:
	ldr	w2, [x8]
	mov	x0, x20
	bl	_RT_TRACE
	str	w22, [x21, #4]
LBB0_15:
	mov	x0, x20
	bl	_spin_lock
	str	wzr, [x21]
	mov	x0, x20
	bl	_spin_unlock
	mov	w8, #1
	str	w8, [x19]
	ldr	w8, [x21, #4]
	cmp	w8, #0
	cset	w0, eq
	b	LBB0_3
LBB0_16:
	ldr	w8, [x21, #8]
Lloh28:
	adrp	x9, _RT_RF_OFF_LEVL_HALT_NIC@GOTPAGE
Lloh29:
	ldr	x9, [x9, _RT_RF_OFF_LEVL_HALT_NIC@GOTPAGEOFF]
Lloh30:
	ldr	w1, [x9]
	tst	w1, w8
	b.eq	LBB0_15
; %bb.17:
	mov	x0, x21
	bl	_RT_SET_PS_LEVEL
	b	LBB0_15
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.cfi_endproc
                                        ; -- End function
	.comm	_REG_GPIO_IO_SEL_2,4,2          ; @REG_GPIO_IO_SEL_2
	.comm	_REG_GPIO_PIN_CTRL_2,4,2        ; @REG_GPIO_PIN_CTRL_2
	.comm	_ERFOFF,4,2                     ; @ERFOFF
	.comm	_ERFON,4,2                      ; @ERFON
	.comm	_COMP_RF,4,2                    ; @COMP_RF
	.comm	_DBG_DMESG,4,2                  ; @DBG_DMESG
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"GPIOChangeRF  - HW Radio ON, RF ON\n"

l_.str.1:                               ; @.str.1
	.asciz	"GPIOChangeRF  - HW Radio OFF, RF OFF\n"

	.comm	_RT_RF_OFF_LEVL_HALT_NIC,4,2    ; @RT_RF_OFF_LEVL_HALT_NIC
.subsections_via_symbols
