	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function vsc85xx_wol_get
_vsc85xx_wol_get:                       ## @vsc85xx_wol_get
	.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
	subq	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r12
	movq	%rdi, %r14
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movl	$0, -56(%rbp)
	movq	$0, -64(%rbp)
	callq	_mutex_lock
	movq	_MSCC_PHY_PAGE_EXTENDED_2@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_phy_select_page
	movl	%eax, -68(%rbp)                 ## 4-byte Spill
	testl	%eax, %eax
	js	LBB0_8
## %bb.1:
	movq	_MSCC_PHY_WOL_MAC_CONTROL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	___phy_read
	movq	_SECURE_ON_ENABLE@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_2
## %bb.3:
	movq	_WAKE_MAGICSECURE@GOTPCREL(%rip), %rcx
	movl	(%r12), %eax
	orl	(%rcx), %eax
	movl	%eax, (%r12)
	jmp	LBB0_4
LBB0_2:
	movl	(%r12), %eax
LBB0_4:
	movq	_WAKE_MAGICSECURE@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_8
## %bb.5:
	movq	_MSCC_PHY_WOL_LOWER_PASSWD@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	___phy_read
	movl	%eax, -64(%rbp)
	movq	_MSCC_PHY_WOL_MID_PASSWD@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	___phy_read
	movl	%eax, -60(%rbp)
	movq	_MSCC_PHY_WOL_UPPER_PASSWD@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	___phy_read
	movl	%eax, -56(%rbp)
	leaq	-64(%rbp), %rdi
	callq	_ARRAY_SIZE
	testl	%eax, %eax
	jle	LBB0_8
## %bb.6:
	movl	$5, %ebx
	xorl	%r15d, %r15d
	leaq	-64(%rbp), %r13
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movzbl	-64(%rbp,%r15,4), %eax
	movq	8(%r12), %rcx
	movl	%eax, (%rcx,%rbx,4)
	movzbl	-63(%rbp,%r15,4), %eax
	movl	%eax, -4(%rcx,%rbx,4)
	incq	%r15
	movq	%r13, %rdi
	callq	_ARRAY_SIZE
	cltq
	addq	$-2, %rbx
	cmpq	%rax, %r15
	jl	LBB0_7
LBB0_8:
	movl	-68(%rbp), %esi                 ## 4-byte Reload
	movl	%esi, %edx
	sarl	$31, %edx
	andl	%esi, %edx
	movq	%r14, %rdi
	callq	_phy_restore_page
	movq	%r14, %rdi
	callq	_mutex_unlock
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_10
## %bb.9:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_10:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_MSCC_PHY_PAGE_EXTENDED_2,4,2   ## @MSCC_PHY_PAGE_EXTENDED_2
	.comm	_MSCC_PHY_WOL_MAC_CONTROL,4,2   ## @MSCC_PHY_WOL_MAC_CONTROL
	.comm	_SECURE_ON_ENABLE,4,2           ## @SECURE_ON_ENABLE
	.comm	_WAKE_MAGICSECURE,4,2           ## @WAKE_MAGICSECURE
	.comm	_MSCC_PHY_WOL_LOWER_PASSWD,4,2  ## @MSCC_PHY_WOL_LOWER_PASSWD
	.comm	_MSCC_PHY_WOL_MID_PASSWD,4,2    ## @MSCC_PHY_WOL_MID_PASSWD
	.comm	_MSCC_PHY_WOL_UPPER_PASSWD,4,2  ## @MSCC_PHY_WOL_UPPER_PASSWD
	.no_dead_strip	_vsc85xx_wol_get
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function vsc85xx_wol_get
_vsc85xx_wol_get:                       ; @vsc85xx_wol_get
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #24]
	str	wzr, [sp, #16]
	str	xzr, [sp, #8]
	bl	_mutex_lock
Lloh3:
	adrp	x8, _MSCC_PHY_PAGE_EXTENDED_2@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MSCC_PHY_PAGE_EXTENDED_2@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_phy_select_page
	mov	x21, x0
	tbnz	w0, #31, LBB0_8
; %bb.1:
Lloh6:
	adrp	x8, _MSCC_PHY_WOL_MAC_CONTROL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _MSCC_PHY_WOL_MAC_CONTROL@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	x0, x19
	bl	___phy_read
Lloh9:
	adrp	x8, _SECURE_ON_ENABLE@GOTPAGE
Lloh10:
	ldr	x8, [x8, _SECURE_ON_ENABLE@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x8]
Lloh12:
	adrp	x8, _WAKE_MAGICSECURE@GOTPAGE
Lloh13:
	ldr	x8, [x8, _WAKE_MAGICSECURE@GOTPAGEOFF]
	tst	w9, w0
	b.eq	LBB0_3
; %bb.2:
	ldr	w9, [x8]
	ldr	w10, [x20]
	orr	w9, w10, w9
	str	w9, [x20]
	b	LBB0_4
LBB0_3:
	ldr	w9, [x20]
LBB0_4:
	ldr	w8, [x8]
	tst	w8, w9
	b.eq	LBB0_8
; %bb.5:
Lloh14:
	adrp	x8, _MSCC_PHY_WOL_LOWER_PASSWD@GOTPAGE
Lloh15:
	ldr	x8, [x8, _MSCC_PHY_WOL_LOWER_PASSWD@GOTPAGEOFF]
Lloh16:
	ldr	w1, [x8]
	mov	x0, x19
	bl	___phy_read
	str	w0, [sp, #8]
Lloh17:
	adrp	x8, _MSCC_PHY_WOL_MID_PASSWD@GOTPAGE
Lloh18:
	ldr	x8, [x8, _MSCC_PHY_WOL_MID_PASSWD@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
	mov	x0, x19
	bl	___phy_read
	str	w0, [sp, #12]
Lloh20:
	adrp	x8, _MSCC_PHY_WOL_UPPER_PASSWD@GOTPAGE
Lloh21:
	ldr	x8, [x8, _MSCC_PHY_WOL_UPPER_PASSWD@GOTPAGEOFF]
Lloh22:
	ldr	w1, [x8]
	mov	x0, x19
	bl	___phy_read
	str	w0, [sp, #16]
	add	x22, sp, #8
	add	x0, sp, #8
	bl	_ARRAY_SIZE
	cmp	w0, #1
	b.lt	LBB0_8
; %bb.6:
	mov	x23, #0
	mov	x24, #0
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	add	x8, x22, x24, lsl #2
	ldrb	w9, [x8]
	ldr	x10, [x20, #8]
	add	x10, x10, x23
	str	w9, [x10, #20]
	ldrb	w8, [x8, #1]
	str	w8, [x10, #16]
	add	x24, x24, #1
	add	x0, sp, #8
	bl	_ARRAY_SIZE
	sub	x23, x23, #8
	cmp	x24, w0, sxtw
	b.lt	LBB0_7
LBB0_8:
	cmp	w21, #0
	csel	w2, w21, wzr, lt
	mov	x0, x19
	mov	x1, x21
	bl	_phy_restore_page
	mov	x0, x19
	bl	_mutex_unlock
	ldr	x8, [sp, #24]
Lloh23:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh24:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh25:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_10
; %bb.9:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
LBB0_10:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.cfi_endproc
                                        ; -- End function
	.comm	_MSCC_PHY_PAGE_EXTENDED_2,4,2   ; @MSCC_PHY_PAGE_EXTENDED_2
	.comm	_MSCC_PHY_WOL_MAC_CONTROL,4,2   ; @MSCC_PHY_WOL_MAC_CONTROL
	.comm	_SECURE_ON_ENABLE,4,2           ; @SECURE_ON_ENABLE
	.comm	_WAKE_MAGICSECURE,4,2           ; @WAKE_MAGICSECURE
	.comm	_MSCC_PHY_WOL_LOWER_PASSWD,4,2  ; @MSCC_PHY_WOL_LOWER_PASSWD
	.comm	_MSCC_PHY_WOL_MID_PASSWD,4,2    ; @MSCC_PHY_WOL_MID_PASSWD
	.comm	_MSCC_PHY_WOL_UPPER_PASSWD,4,2  ; @MSCC_PHY_WOL_UPPER_PASSWD
	.no_dead_strip	_vsc85xx_wol_get
.subsections_via_symbols
