	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ath6kl_wmi_set_wow_mode_cmd    ## -- Begin function ath6kl_wmi_set_wow_mode_cmd
	.p2align	4, 0x90
_ath6kl_wmi_set_wow_mode_cmd:           ## @ath6kl_wmi_set_wow_mode_cmd
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r8d, %r12d
	movl	%ecx, %r13d
	movl	%edx, %r14d
	movl	%esi, %r15d
	movq	_ATH6KL_WOW_MODE_ENABLE@GOTPCREL(%rip), %rax
	cmpl	%edx, (%rax)
	je	LBB0_3
## %bb.1:
	movq	_ATH6KL_WOW_MODE_DISABLE@GOTPCREL(%rip), %rax
	cmpl	%r14d, (%rax)
	je	LBB0_3
## %bb.2:
	leaq	L_.str(%rip), %rdi
	movl	%r14d, %esi
	callq	_ath6kl_err
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	jmp	LBB0_5
LBB0_3:
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	movl	$24, %edi
	callq	_ath6kl_wmi_get_new_buf
	testq	%rax, %rax
	je	LBB0_4
## %bb.6:
	movq	%rax, %rbx
	movl	%r15d, -44(%rbp)                ## 4-byte Spill
	movq	(%rax), %r15
	movl	%r14d, %edi
	callq	_cpu_to_le32
	movq	%rax, 16(%r15)
	movl	%r13d, %edi
	callq	_cpu_to_le32
	movq	%rax, 8(%r15)
	movl	%r12d, %edi
	callq	_cpu_to_le16
	movl	%eax, (%r15)
	movq	_WMI_SET_WOW_MODE_CMDID@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	_NO_SYNC_WMIFLAG@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movl	-44(%rbp), %esi                 ## 4-byte Reload
	movq	%rbx, %rdx
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ath6kl_wmi_cmd_send            ## TAILCALL
LBB0_4:
	movq	_ENOMEM@GOTPCREL(%rip), %rcx
LBB0_5:
	xorl	%eax, %eax
	subl	(%rcx), %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ATH6KL_WOW_MODE_ENABLE,4,2     ## @ATH6KL_WOW_MODE_ENABLE
	.comm	_ATH6KL_WOW_MODE_DISABLE,4,2    ## @ATH6KL_WOW_MODE_DISABLE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"invalid wow mode: %d\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_WMI_SET_WOW_MODE_CMDID,4,2     ## @WMI_SET_WOW_MODE_CMDID
	.comm	_NO_SYNC_WMIFLAG,4,2            ## @NO_SYNC_WMIFLAG
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ath6kl_wmi_set_wow_mode_cmd    ; -- Begin function ath6kl_wmi_set_wow_mode_cmd
	.p2align	2
_ath6kl_wmi_set_wow_mode_cmd:           ; @ath6kl_wmi_set_wow_mode_cmd
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x24, x2
Lloh0:
	adrp	x8, _ATH6KL_WOW_MODE_ENABLE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ATH6KL_WOW_MODE_ENABLE@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, _ATH6KL_WOW_MODE_DISABLE@GOTPAGE
Lloh4:
	ldr	x9, [x9, _ATH6KL_WOW_MODE_DISABLE@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	cmp	w8, w2
	ccmp	w9, w2, #4, ne
	b.ne	LBB0_3
; %bb.1:
	mov	x21, x4
	mov	x22, x3
	mov	x19, x1
	mov	x20, x0
	mov	w0, #24
	bl	_ath6kl_wmi_get_new_buf
	cbz	x0, LBB0_4
; %bb.2:
	mov	x23, x0
	ldr	x25, [x0]
	mov	x0, x24
	bl	_cpu_to_le32
	str	x0, [x25, #16]
	mov	x0, x22
	bl	_cpu_to_le32
	str	x0, [x25, #8]
	mov	x0, x21
	bl	_cpu_to_le16
	str	w0, [x25]
Lloh6:
	adrp	x8, _WMI_SET_WOW_MODE_CMDID@GOTPAGE
Lloh7:
	ldr	x8, [x8, _WMI_SET_WOW_MODE_CMDID@GOTPAGEOFF]
Lloh8:
	ldr	w3, [x8]
Lloh9:
	adrp	x8, _NO_SYNC_WMIFLAG@GOTPAGE
Lloh10:
	ldr	x8, [x8, _NO_SYNC_WMIFLAG@GOTPAGEOFF]
Lloh11:
	ldr	w4, [x8]
	mov	x0, x20
	mov	x1, x19
	mov	x2, x23
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_ath6kl_wmi_cmd_send
LBB0_3:
Lloh12:
	adrp	x0, l_.str@PAGE
Lloh13:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x24
	bl	_ath6kl_err
Lloh14:
	adrp	x8, _EINVAL@GOTPAGE
Lloh15:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_5
LBB0_4:
Lloh16:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh17:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
LBB0_5:
	ldr	w8, [x8]
	neg	w0, w8
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_ATH6KL_WOW_MODE_ENABLE,4,2     ; @ATH6KL_WOW_MODE_ENABLE
	.comm	_ATH6KL_WOW_MODE_DISABLE,4,2    ; @ATH6KL_WOW_MODE_DISABLE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"invalid wow mode: %d\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_WMI_SET_WOW_MODE_CMDID,4,2     ; @WMI_SET_WOW_MODE_CMDID
	.comm	_NO_SYNC_WMIFLAG,4,2            ; @NO_SYNC_WMIFLAG
.subsections_via_symbols
