	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function be_set_wol
_be_set_wol:                            ## @be_set_wol
	.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, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	callq	_netdev_priv
	movq	%rax, %r15
	movq	%rsp, %r14
	movq	_ETH_ALEN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	shlq	$2, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %r12
	movq	_WAKE_MAGIC@GOTPCREL(%rip), %r13
	movl	(%r13), %eax
	notl	%eax
	testl	%eax, (%rbx)
	je	LBB0_3
LBB0_1:
	movq	_EOPNOTSUPP@GOTPCREL(%rip), %rax
LBB0_2:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_13:
	movq	%r14, %rsp
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_15
## %bb.14:
	movl	%ebx, %eax
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movq	_BE_WOL_CAP@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r15)
	je	LBB0_4
## %bb.5:
	movq	8(%r15), %rdi
	movl	$4, -64(%rbp)
	leaq	-60(%rbp), %rdx
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%rdi, -72(%rbp)                 ## 8-byte Spill
	movl	$4, %esi
	callq	_dma_alloc_coherent
	movl	%eax, -56(%rbp)
	testl	%eax, %eax
	je	LBB0_6
## %bb.7:
	movq	%r12, %rdi
	callq	_eth_zero_addr
	movl	(%r13), %r13d
	andl	(%rbx), %r13d
	je	LBB0_9
## %bb.8:
	movq	16(%r15), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_ether_addr_copy
LBB0_9:
	leaq	-64(%rbp), %rdx
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_be_cmd_enable_magic_wol
	testl	%eax, %eax
	je	LBB0_11
## %bb.10:
	movl	%eax, %ebx
	leaq	L_.str.1(%rip), %rsi
	movq	-72(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rdi
	callq	_dev_err
	movl	%ebx, %edi
	callq	_be_cmd_status
	movl	%eax, %ebx
	jmp	LBB0_12
LBB0_4:
	movq	8(%r15), %rdi
	leaq	L_.str(%rip), %rsi
	callq	_dev_warn
	jmp	LBB0_1
LBB0_6:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	jmp	LBB0_2
LBB0_11:
	xorl	%ebx, %ebx
	testl	%r13d, %r13d
	setne	%bl
	movq	8(%r15), %rdi
	movq	_PCI_D3hot@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%r13d, %edx
	callq	_pci_enable_wake
	movq	8(%r15), %rdi
	movq	_PCI_D3cold@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%r13d, %edx
	callq	_pci_enable_wake
	movl	%ebx, 4(%r15)
	xorl	%ebx, %ebx
	movq	-72(%rbp), %r15                 ## 8-byte Reload
LBB0_12:
	movl	-56(%rbp), %edx
	movl	-64(%rbp), %esi
	movl	-60(%rbp), %ecx
	movq	%r15, %rdi
	callq	_dma_free_coherent
	jmp	LBB0_13
LBB0_15:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_ETH_ALEN,4,2                   ## @ETH_ALEN
	.comm	_WAKE_MAGIC,4,2                 ## @WAKE_MAGIC
	.comm	_EOPNOTSUPP,4,2                 ## @EOPNOTSUPP
	.comm	_BE_WOL_CAP,4,2                 ## @BE_WOL_CAP
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"WOL not supported\n"

	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
L_.str.1:                               ## @.str.1
	.asciz	"Could not set Wake-on-lan mac address\n"

	.comm	_PCI_D3hot,4,2                  ## @PCI_D3hot
	.comm	_PCI_D3cold,4,2                 ## @PCI_D3cold
	.no_dead_strip	_be_set_wol
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function be_set_wol
_be_set_wol:                            ; @be_set_wol
	.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
	sub	sp, sp, #32
	mov	x21, x1
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-56]
	bl	_netdev_priv
	mov	x20, x0
	mov	x23, sp
	ldr	x19, [x0, #8]
Lloh3:
	adrp	x8, _ETH_ALEN@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ETH_ALEN@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	lsl	x8, x8, #2
	mov	x9, x8
Lloh6:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh7:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	add	x8, x8, #15
	and	x8, x8, #0x7fffffff0
	sub	x22, x9, x8
	mov	sp, x22
	ldr	w8, [x21]
Lloh8:
	adrp	x24, _WAKE_MAGIC@GOTPAGE
Lloh9:
	ldr	x24, [x24, _WAKE_MAGIC@GOTPAGEOFF]
	ldr	w9, [x24]
	bics	wzr, w8, w9
	b.eq	LBB0_5
LBB0_1:
Lloh10:
	adrp	x8, _EOPNOTSUPP@GOTPAGE
Lloh11:
	ldr	x8, [x8, _EOPNOTSUPP@GOTPAGEOFF]
LBB0_2:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_3:
	mov	sp, x23
	ldur	x8, [x29, #-56]
Lloh12:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh13:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh14:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_15
; %bb.4:
	mov	x0, x21
	sub	sp, x29, #48
	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_5:
	ldr	w8, [x20]
Lloh15:
	adrp	x9, _BE_WOL_CAP@GOTPAGE
Lloh16:
	ldr	x9, [x9, _BE_WOL_CAP@GOTPAGEOFF]
Lloh17:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_11
; %bb.6:
	mov	w8, #4
	stur	w8, [x29, #-72]
	sub	x8, x29, #72
	orr	x2, x8, #0x4
Lloh18:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh19:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh20:
	ldr	w3, [x8]
	mov	x0, x19
	mov	w1, #4
	bl	_dma_alloc_coherent
	stur	w0, [x29, #-64]
	cbz	w0, LBB0_12
; %bb.7:
	mov	x0, x22
	bl	_eth_zero_addr
	ldr	w8, [x21]
	ldr	w9, [x24]
	ands	w21, w9, w8
	b.eq	LBB0_9
; %bb.8:
	ldr	x8, [x20, #16]
	ldr	w1, [x8]
	mov	x0, x22
	bl	_ether_addr_copy
LBB0_9:
	sub	x2, x29, #72
	mov	x0, x20
	mov	x1, x22
	bl	_be_cmd_enable_magic_wol
	cbz	w0, LBB0_13
; %bb.10:
	mov	x22, x0
Lloh21:
	adrp	x1, l_.str.1@PAGE
Lloh22:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_dev_err
	mov	x0, x22
	bl	_be_cmd_status
	mov	x21, x0
	b	LBB0_14
LBB0_11:
	ldr	x0, [x20, #8]
Lloh23:
	adrp	x1, l_.str@PAGE
Lloh24:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_warn
	b	LBB0_1
LBB0_12:
Lloh25:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh26:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_2
LBB0_13:
	cmp	w21, #0
	cset	w22, ne
	ldr	x0, [x20, #8]
Lloh27:
	adrp	x8, _PCI_D3hot@GOTPAGE
Lloh28:
	ldr	x8, [x8, _PCI_D3hot@GOTPAGEOFF]
Lloh29:
	ldr	w1, [x8]
	mov	x2, x21
	bl	_pci_enable_wake
	ldr	x0, [x20, #8]
Lloh30:
	adrp	x8, _PCI_D3cold@GOTPAGE
Lloh31:
	ldr	x8, [x8, _PCI_D3cold@GOTPAGEOFF]
Lloh32:
	ldr	w1, [x8]
	mov	x2, x21
	bl	_pci_enable_wake
	mov	w21, #0
	str	w22, [x20, #4]
LBB0_14:
	ldp	w3, w2, [x29, #-68]
	ldur	w1, [x29, #-72]
	mov	x0, x19
	bl	_dma_free_coherent
	b	LBB0_3
LBB0_15:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGot	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.cfi_endproc
                                        ; -- End function
	.comm	_ETH_ALEN,4,2                   ; @ETH_ALEN
	.comm	_WAKE_MAGIC,4,2                 ; @WAKE_MAGIC
	.comm	_EOPNOTSUPP,4,2                 ; @EOPNOTSUPP
	.comm	_BE_WOL_CAP,4,2                 ; @BE_WOL_CAP
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"WOL not supported\n"

	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
l_.str.1:                               ; @.str.1
	.asciz	"Could not set Wake-on-lan mac address\n"

	.comm	_PCI_D3hot,4,2                  ; @PCI_D3hot
	.comm	_PCI_D3cold,4,2                 ; @PCI_D3cold
	.no_dead_strip	_be_set_wol
.subsections_via_symbols
