	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function rtl8xxxu_add_interface
_rtl8xxxu_add_interface:                ## @rtl8xxxu_add_interface
	.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	%rsi, %r14
	movq	(%rdi), %r15
	movl	(%rsi), %esi
	cmpl	$128, %esi
	jne	LBB0_2
## %bb.1:
	movq	%r15, %rdi
	callq	_rtl8xxxu_stop_tx_beacon
	movq	_REG_BEACON_CTRL@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	movq	%r15, %rdi
	callq	_rtl8xxxu_read8
	movq	_BEACON_ATIM@GOTPCREL(%rip), %rcx
	movq	_BEACON_FUNCTION_ENABLE@GOTPCREL(%rip), %rdx
	orl	(%rcx), %eax
	orl	(%rdx), %eax
	movq	_BEACON_DISABLE_TSF_UPDATE@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	(%rbx), %esi
	movq	%r15, %rdi
	movl	%eax, %edx
	callq	_rtl8xxxu_write8
	movl	(%r14), %esi
	xorl	%ebx, %ebx
	jmp	LBB0_3
LBB0_2:
	movq	_EOPNOTSUPP@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_3:
	movq	%r15, %rdi
	callq	_rtl8xxxu_set_linktype
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_REG_BEACON_CTRL,4,2            ## @REG_BEACON_CTRL
	.comm	_BEACON_ATIM,4,2                ## @BEACON_ATIM
	.comm	_BEACON_FUNCTION_ENABLE,4,2     ## @BEACON_FUNCTION_ENABLE
	.comm	_BEACON_DISABLE_TSF_UPDATE,4,2  ## @BEACON_DISABLE_TSF_UPDATE
	.comm	_EOPNOTSUPP,4,2                 ## @EOPNOTSUPP
	.no_dead_strip	_rtl8xxxu_add_interface
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function rtl8xxxu_add_interface
_rtl8xxxu_add_interface:                ; @rtl8xxxu_add_interface
	.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	x20, x1
	ldr	x19, [x0]
	ldr	w1, [x1]
	cmp	w1, #128
	b.ne	LBB0_2
; %bb.1:
	mov	x0, x19
	bl	_rtl8xxxu_stop_tx_beacon
Lloh0:
	adrp	x21, _REG_BEACON_CTRL@GOTPAGE
Lloh1:
	ldr	x21, [x21, _REG_BEACON_CTRL@GOTPAGEOFF]
	ldr	w1, [x21]
	mov	x0, x19
	bl	_rtl8xxxu_read8
Lloh2:
	adrp	x8, _BEACON_ATIM@GOTPAGE
Lloh3:
	ldr	x8, [x8, _BEACON_ATIM@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
Lloh5:
	adrp	x9, _BEACON_FUNCTION_ENABLE@GOTPAGE
Lloh6:
	ldr	x9, [x9, _BEACON_FUNCTION_ENABLE@GOTPAGEOFF]
Lloh7:
	adrp	x10, _BEACON_DISABLE_TSF_UPDATE@GOTPAGE
Lloh8:
	ldr	x10, [x10, _BEACON_DISABLE_TSF_UPDATE@GOTPAGEOFF]
Lloh9:
	ldr	w9, [x9]
Lloh10:
	ldr	w10, [x10]
	orr	w8, w8, w0
	orr	w8, w8, w9
	orr	w2, w8, w10
	ldr	w1, [x21]
	mov	x0, x19
	bl	_rtl8xxxu_write8
	mov	w21, #0
	ldr	w1, [x20]
	b	LBB0_3
LBB0_2:
Lloh11:
	adrp	x8, _EOPNOTSUPP@GOTPAGE
Lloh12:
	ldr	x8, [x8, _EOPNOTSUPP@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_3:
	mov	x0, x19
	bl	_rtl8xxxu_set_linktype
	mov	x0, x21
	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
	ret
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh9
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_REG_BEACON_CTRL,4,2            ; @REG_BEACON_CTRL
	.comm	_BEACON_ATIM,4,2                ; @BEACON_ATIM
	.comm	_BEACON_FUNCTION_ENABLE,4,2     ; @BEACON_FUNCTION_ENABLE
	.comm	_BEACON_DISABLE_TSF_UPDATE,4,2  ; @BEACON_DISABLE_TSF_UPDATE
	.comm	_EOPNOTSUPP,4,2                 ; @EOPNOTSUPP
	.no_dead_strip	_rtl8xxxu_add_interface
.subsections_via_symbols
