	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function wl3501_set_to_wla
_wl3501_set_to_wla:                     ## @wl3501_set_to_wla
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%ecx, %r14d
	movq	%rdx, %r15
	movl	%esi, %ebx
	movq	%rdi, %r12
	testl	$32768, %esi                    ## imm = 0x8000
	jne	LBB0_1
## %bb.2:
	movq	_WL3501_BSS_SPAGE0@GOTPCREL(%rip), %rax
	jmp	LBB0_3
LBB0_1:
	movq	_WL3501_BSS_SPAGE1@GOTPCREL(%rip), %rax
LBB0_3:
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_wl3501_switch_page
	movzbl	%bl, %edi
	movq	_WL3501_NIC_LMAL@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	(%r12), %rsi
	callq	_wl3501_outb
	shrl	$8, %ebx
	andl	$127, %ebx
	movq	_WL3501_NIC_LMAH@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	(%r12), %rsi
	movl	%ebx, %edi
	callq	_wl3501_outb
	movq	_WL3501_NIC_IODPA@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	(%r12), %rdi
	movq	%r15, %rsi
	movl	%r14d, %edx
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_wl3501_outsb                   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_WL3501_BSS_SPAGE1,4,2          ## @WL3501_BSS_SPAGE1
	.comm	_WL3501_BSS_SPAGE0,4,2          ## @WL3501_BSS_SPAGE0
	.comm	_WL3501_NIC_LMAL,8,3            ## @WL3501_NIC_LMAL
	.comm	_WL3501_NIC_LMAH,8,3            ## @WL3501_NIC_LMAH
	.comm	_WL3501_NIC_IODPA,8,3           ## @WL3501_NIC_IODPA
	.no_dead_strip	_wl3501_set_to_wla
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function wl3501_set_to_wla
_wl3501_set_to_wla:                     ; @wl3501_set_to_wla
	.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, x3
	mov	x20, x2
	mov	x21, x1
	mov	x22, x0
Lloh0:
	adrp	x8, _WL3501_BSS_SPAGE1@GOTPAGE
Lloh1:
	ldr	x8, [x8, _WL3501_BSS_SPAGE1@GOTPAGEOFF]
Lloh2:
	adrp	x9, _WL3501_BSS_SPAGE0@GOTPAGE
Lloh3:
	ldr	x9, [x9, _WL3501_BSS_SPAGE0@GOTPAGEOFF]
	tst	w1, #0x8000
	csel	x8, x9, x8, eq
	ldr	w1, [x8]
	bl	_wl3501_switch_page
	and	w0, w21, #0xff
	ldr	x8, [x22]
Lloh4:
	adrp	x9, _WL3501_NIC_LMAL@GOTPAGE
Lloh5:
	ldr	x9, [x9, _WL3501_NIC_LMAL@GOTPAGEOFF]
Lloh6:
	ldr	x9, [x9]
	add	x1, x9, x8
	bl	_wl3501_outb
	ubfx	w0, w21, #8, #7
	ldr	x8, [x22]
Lloh7:
	adrp	x9, _WL3501_NIC_LMAH@GOTPAGE
Lloh8:
	ldr	x9, [x9, _WL3501_NIC_LMAH@GOTPAGEOFF]
Lloh9:
	ldr	x9, [x9]
	add	x1, x9, x8
	bl	_wl3501_outb
Lloh10:
	adrp	x8, _WL3501_NIC_IODPA@GOTPAGE
Lloh11:
	ldr	x8, [x8, _WL3501_NIC_IODPA@GOTPAGEOFF]
	ldr	x9, [x22]
Lloh12:
	ldr	x8, [x8]
	add	x0, x8, x9
	mov	x1, x20
	mov	x2, x19
	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	_wl3501_outsb
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_WL3501_BSS_SPAGE1,4,2          ; @WL3501_BSS_SPAGE1
	.comm	_WL3501_BSS_SPAGE0,4,2          ; @WL3501_BSS_SPAGE0
	.comm	_WL3501_NIC_LMAL,8,3            ; @WL3501_NIC_LMAL
	.comm	_WL3501_NIC_LMAH,8,3            ; @WL3501_NIC_LMAH
	.comm	_WL3501_NIC_IODPA,8,3           ; @WL3501_NIC_IODPA
	.no_dead_strip	_wl3501_set_to_wla
.subsections_via_symbols
