	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_rtl8225se_rf_set_channel       ## -- Begin function rtl8225se_rf_set_channel
	.p2align	4, 0x90
_rtl8225se_rf_set_channel:              ## @rtl8225se_rf_set_channel
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	(%rsi), %rax
	movl	(%rax), %edi
	callq	_ieee80211_frequency_to_channel
	movl	%eax, %ebx
	movq	%r14, %rdi
	movl	%eax, %esi
	callq	_rtl8225sez2_rf_set_tx_power
	movq	_rtl8225se_chan@GOTPCREL(%rip), %r15
	movq	(%r15), %rax
	movslq	%ebx, %rbx
	movl	-4(%rax,%rbx,4), %edx
	movq	%r14, %rdi
	movl	$7, %esi
	callq	_rtl8187se_rf_writereg
	movq	%r14, %rdi
	movl	$7, %esi
	callq	_rtl8187se_rf_readreg
	andl	$3968, %eax                     ## imm = 0xF80
	movq	(%r15), %rcx
	movl	-4(%rcx,%rbx,4), %edx
	cmpl	%edx, %eax
	je	LBB0_2
## %bb.1:
	movq	%r14, %rdi
	movl	$7, %esi
	callq	_rtl8187se_rf_writereg
LBB0_2:
	movl	$10000, %edi                    ## imm = 0x2710
	movl	$20000, %esi                    ## imm = 0x4E20
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_usleep_range                   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_rtl8225se_chan,8,3             ## @rtl8225se_chan
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_rtl8225se_rf_set_channel       ; -- Begin function rtl8225se_rf_set_channel
	.p2align	2
_rtl8225se_rf_set_channel:              ; @rtl8225se_rf_set_channel
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	mov	x19, x0
	ldr	x8, [x1]
	ldr	w0, [x8]
	bl	_ieee80211_frequency_to_channel
	mov	x20, x0
	mov	x0, x19
	mov	x1, x20
	bl	_rtl8225sez2_rf_set_tx_power
Lloh0:
	adrp	x21, _rtl8225se_chan@GOTPAGE
Lloh1:
	ldr	x21, [x21, _rtl8225se_chan@GOTPAGEOFF]
	ldr	x8, [x21]
	sub	w9, w20, #1
	sbfiz	x20, x9, #2, #32
	ldr	w2, [x8, x20]
	mov	x0, x19
	mov	w1, #7
	bl	_rtl8187se_rf_writereg
	mov	x0, x19
	mov	w1, #7
	bl	_rtl8187se_rf_readreg
	and	w8, w0, #0xf80
	ldr	x9, [x21]
	ldr	w2, [x9, x20]
	cmp	w8, w2
	b.eq	LBB0_2
; %bb.1:
	mov	x0, x19
	mov	w1, #7
	bl	_rtl8187se_rf_writereg
LBB0_2:
	mov	w0, #10000
	mov	w1, #20000
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_usleep_range
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_rtl8225se_chan,8,3             ; @rtl8225se_chan
.subsections_via_symbols
