	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bcmgenet_set_wol               ## -- Begin function bcmgenet_set_wol
	.p2align	4, 0x90
_bcmgenet_set_wol:                      ## @bcmgenet_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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	callq	_netdev_priv
	movq	%rax, %rbx
	movq	16(%rax), %r15
	movq	%r15, %rdi
	callq	_device_can_wakeup
	testl	%eax, %eax
	je	LBB0_1
## %bb.3:
	movq	_WAKE_MAGIC@GOTPCREL(%rip), %rax
	movq	_WAKE_MAGICSECURE@GOTPCREL(%rip), %r13
	movl	(%r13), %ecx
	orl	(%rax), %ecx
	notl	%ecx
	testl	%ecx, (%r14)
	je	LBB0_5
## %bb.4:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	jmp	LBB0_2
LBB0_1:
	movq	_ENOTSUPP@GOTPCREL(%rip), %rcx
LBB0_2:
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_16
LBB0_5:
	movq	_UMAC_MPD_CTRL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_bcmgenet_umac_readl
	movl	%eax, %r12d
	movl	(%r13), %eax
	testl	%eax, (%r14)
	je	LBB0_7
## %bb.6:
	movq	8(%r14), %rdi
	callq	_get_unaligned_be16
	movq	_UMAC_MPD_PW_MS@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_bcmgenet_umac_writel
	movq	8(%r14), %rdi
	addq	$8, %rdi
	callq	_get_unaligned_be32
	movq	_UMAC_MPD_PW_LS@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_bcmgenet_umac_writel
	movq	_MPD_PW_EN@GOTPCREL(%rip), %rax
	orl	(%rax), %r12d
	jmp	LBB0_8
LBB0_7:
	movq	_MPD_PW_EN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	notl	%eax
	andl	%eax, %r12d
LBB0_8:
	movq	_UMAC_MPD_CTRL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	movl	%r12d, %esi
	callq	_bcmgenet_umac_writel
	cmpl	$0, (%r14)
	je	LBB0_12
## %bb.9:
	movq	%r15, %rdi
	movl	$1, %esi
	callq	_device_set_wakeup_enable
	cmpl	$0, (%rbx)
	je	LBB0_11
## %bb.10:
	movl	8(%rbx), %edi
	callq	_enable_irq_wake
LBB0_11:
	movl	$0, (%rbx)
	jmp	LBB0_15
LBB0_12:
	movq	%r15, %rdi
	xorl	%esi, %esi
	callq	_device_set_wakeup_enable
	cmpl	$0, (%rbx)
	jne	LBB0_14
## %bb.13:
	movl	8(%rbx), %edi
	callq	_disable_irq_wake
LBB0_14:
	movl	$1, (%rbx)
LBB0_15:
	movl	(%r14), %eax
	movl	%eax, 4(%rbx)
	xorl	%eax, %eax
LBB0_16:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOTSUPP,4,2                   ## @ENOTSUPP
	.comm	_WAKE_MAGIC,4,2                 ## @WAKE_MAGIC
	.comm	_WAKE_MAGICSECURE,4,2           ## @WAKE_MAGICSECURE
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_UMAC_MPD_CTRL,4,2              ## @UMAC_MPD_CTRL
	.comm	_UMAC_MPD_PW_MS,4,2             ## @UMAC_MPD_PW_MS
	.comm	_UMAC_MPD_PW_LS,4,2             ## @UMAC_MPD_PW_LS
	.comm	_MPD_PW_EN,4,2                  ## @MPD_PW_EN
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bcmgenet_set_wol               ; -- Begin function bcmgenet_set_wol
	.p2align	2
_bcmgenet_set_wol:                      ; @bcmgenet_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
	mov	x19, x1
	bl	_netdev_priv
	mov	x20, x0
	ldr	x21, [x0, #16]
	mov	x0, x21
	bl	_device_can_wakeup
	cbz	w0, LBB0_3
; %bb.1:
	ldr	w8, [x19]
Lloh0:
	adrp	x9, _WAKE_MAGIC@GOTPAGE
Lloh1:
	ldr	x9, [x9, _WAKE_MAGIC@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
Lloh3:
	adrp	x24, _WAKE_MAGICSECURE@GOTPAGE
Lloh4:
	ldr	x24, [x24, _WAKE_MAGICSECURE@GOTPAGEOFF]
	ldr	w10, [x24]
	orr	w9, w10, w9
	bics	wzr, w8, w9
	b.eq	LBB0_5
; %bb.2:
Lloh5:
	adrp	x8, _EINVAL@GOTPAGE
Lloh6:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_4
LBB0_3:
Lloh7:
	adrp	x8, _ENOTSUPP@GOTPAGE
Lloh8:
	ldr	x8, [x8, _ENOTSUPP@GOTPAGEOFF]
LBB0_4:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_16
LBB0_5:
Lloh9:
	adrp	x23, _UMAC_MPD_CTRL@GOTPAGE
Lloh10:
	ldr	x23, [x23, _UMAC_MPD_CTRL@GOTPAGEOFF]
	ldr	w1, [x23]
	mov	x0, x20
	bl	_bcmgenet_umac_readl
	mov	x22, x0
	ldr	w8, [x19]
	ldr	w9, [x24]
	tst	w9, w8
	b.eq	LBB0_7
; %bb.6:
	ldr	x0, [x19, #8]
	bl	_get_unaligned_be16
	mov	x1, x0
Lloh11:
	adrp	x8, _UMAC_MPD_PW_MS@GOTPAGE
Lloh12:
	ldr	x8, [x8, _UMAC_MPD_PW_MS@GOTPAGEOFF]
Lloh13:
	ldr	w2, [x8]
	mov	x0, x20
	bl	_bcmgenet_umac_writel
	ldr	x8, [x19, #8]
	add	x0, x8, #8
	bl	_get_unaligned_be32
	mov	x1, x0
Lloh14:
	adrp	x8, _UMAC_MPD_PW_LS@GOTPAGE
Lloh15:
	ldr	x8, [x8, _UMAC_MPD_PW_LS@GOTPAGEOFF]
Lloh16:
	ldr	w2, [x8]
	mov	x0, x20
	bl	_bcmgenet_umac_writel
Lloh17:
	adrp	x8, _MPD_PW_EN@GOTPAGE
Lloh18:
	ldr	x8, [x8, _MPD_PW_EN@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
	orr	w1, w8, w22
	b	LBB0_8
LBB0_7:
Lloh20:
	adrp	x8, _MPD_PW_EN@GOTPAGE
Lloh21:
	ldr	x8, [x8, _MPD_PW_EN@GOTPAGEOFF]
Lloh22:
	ldr	w8, [x8]
	bic	w1, w22, w8
LBB0_8:
	ldr	w2, [x23]
	mov	x0, x20
	bl	_bcmgenet_umac_writel
	ldr	w8, [x19]
	cbz	w8, LBB0_12
; %bb.9:
	mov	x0, x21
	mov	w1, #1
	bl	_device_set_wakeup_enable
	ldr	w8, [x20]
	cbz	w8, LBB0_11
; %bb.10:
	ldr	w0, [x20, #8]
	bl	_enable_irq_wake
LBB0_11:
	str	wzr, [x20]
	b	LBB0_15
LBB0_12:
	mov	x0, x21
	mov	w1, #0
	bl	_device_set_wakeup_enable
	ldr	w8, [x20]
	cbnz	w8, LBB0_14
; %bb.13:
	ldr	w0, [x20, #8]
	bl	_disable_irq_wake
LBB0_14:
	mov	w8, #1
	str	w8, [x20]
LBB0_15:
	mov	w0, #0
	ldr	w8, [x19]
	str	w8, [x20, #4]
LBB0_16:
	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
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOTSUPP,4,2                   ; @ENOTSUPP
	.comm	_WAKE_MAGIC,4,2                 ; @WAKE_MAGIC
	.comm	_WAKE_MAGICSECURE,4,2           ; @WAKE_MAGICSECURE
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_UMAC_MPD_CTRL,4,2              ; @UMAC_MPD_CTRL
	.comm	_UMAC_MPD_PW_MS,4,2             ; @UMAC_MPD_PW_MS
	.comm	_UMAC_MPD_PW_LS,4,2             ; @UMAC_MPD_PW_LS
	.comm	_MPD_PW_EN,4,2                  ; @MPD_PW_EN
.subsections_via_symbols
