	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ath9k_set_power_sleep
_ath9k_set_power_sleep:                 ## @ath9k_set_power_sleep
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	%rdi, %rbx
	movq	_AR_STA_ID1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_AR_STA_ID1_PWR_SAV@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_REG_SET_BIT
	movq	%rbx, %rdi
	callq	_AR_SREV_9462
	testq	%rax, %rax
	jne	LBB0_2
## %bb.1:
	movq	%rbx, %rdi
	callq	_AR_SREV_9565
	testq	%rax, %rax
	je	LBB0_3
LBB0_2:
	movq	_AR_TIMER_MODE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movl	$255, %edx
	callq	_REG_CLR_BIT
	movq	_AR_NDP2_TIMER_MODE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movl	$255, %edx
	callq	_REG_CLR_BIT
	movq	_AR_SLP32_INC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movl	$1048575, %edx                  ## imm = 0xFFFFF
	callq	_REG_CLR_BIT
	movq	_AR_MCI_INTERRUPT_RX_MSG_EN@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	callq	_REG_WRITE
	movl	$100, %edi
	callq	_udelay
LBB0_3:
	movq	_AR_RTC_FORCE_WAKE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_AR_RTC_FORCE_WAKE_EN@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_REG_CLR_BIT
	movq	%rbx, %rdi
	callq	_ath9k_hw_mci_is_enabled
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	movl	$100, %edi
	callq	_udelay
LBB0_5:
	movq	%rbx, %rdi
	callq	_AR_SREV_9100
	testl	%eax, %eax
	jne	LBB0_8
## %bb.6:
	movq	%rbx, %rdi
	callq	_AR_SREV_9300_20_OR_LATER
	testq	%rax, %rax
	jne	LBB0_8
## %bb.7:
	movq	_AR_RC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_AR_RC_AHB@GOTPCREL(%rip), %rax
	movq	_AR_RC_HOSTIF@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	orl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_REG_WRITE
LBB0_8:
	movq	%rbx, %rdi
	callq	_AR_SREV_5416
	testl	%eax, %eax
	jne	LBB0_11
## %bb.9:
	movq	%rbx, %rdi
	callq	_AR_SREV_9271
	testl	%eax, %eax
	jne	LBB0_11
## %bb.10:
	movq	_AR_RTC_RESET@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_AR_RTC_RESET_EN@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_REG_CLR_BIT
	movl	$2, %edi
	callq	_udelay
LBB0_11:
	movq	%rbx, %rdi
	callq	_AR_SREV_9300_20_OR_LATER
	testq	%rax, %rax
	je	LBB0_12
## %bb.13:
	movq	_AR_WA@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_AR_WA_D3_L1_DISABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	notl	%edx
	andl	(%rbx), %edx
	movq	%rbx, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	jmp	_REG_WRITE                      ## TAILCALL
LBB0_12:
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AR_STA_ID1,4,2                 ## @AR_STA_ID1
	.comm	_AR_STA_ID1_PWR_SAV,4,2         ## @AR_STA_ID1_PWR_SAV
	.comm	_AR_TIMER_MODE,4,2              ## @AR_TIMER_MODE
	.comm	_AR_NDP2_TIMER_MODE,4,2         ## @AR_NDP2_TIMER_MODE
	.comm	_AR_SLP32_INC,4,2               ## @AR_SLP32_INC
	.comm	_AR_MCI_INTERRUPT_RX_MSG_EN,4,2 ## @AR_MCI_INTERRUPT_RX_MSG_EN
	.comm	_AR_RTC_FORCE_WAKE,4,2          ## @AR_RTC_FORCE_WAKE
	.comm	_AR_RTC_FORCE_WAKE_EN,4,2       ## @AR_RTC_FORCE_WAKE_EN
	.comm	_AR_RC,4,2                      ## @AR_RC
	.comm	_AR_RC_AHB,4,2                  ## @AR_RC_AHB
	.comm	_AR_RC_HOSTIF,4,2               ## @AR_RC_HOSTIF
	.comm	_AR_RTC_RESET,4,2               ## @AR_RTC_RESET
	.comm	_AR_RTC_RESET_EN,4,2            ## @AR_RTC_RESET_EN
	.comm	_AR_WA,4,2                      ## @AR_WA
	.comm	_AR_WA_D3_L1_DISABLE,4,2        ## @AR_WA_D3_L1_DISABLE
	.no_dead_strip	_ath9k_set_power_sleep
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ath9k_set_power_sleep
_ath9k_set_power_sleep:                 ; @ath9k_set_power_sleep
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
Lloh0:
	adrp	x8, _AR_STA_ID1@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AR_STA_ID1@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x8, _AR_STA_ID1_PWR_SAV@GOTPAGE
Lloh4:
	ldr	x8, [x8, _AR_STA_ID1_PWR_SAV@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	bl	_REG_SET_BIT
	mov	x0, x19
	bl	_AR_SREV_9462
	cbnz	x0, LBB0_2
; %bb.1:
	mov	x0, x19
	bl	_AR_SREV_9565
	cbz	x0, LBB0_3
LBB0_2:
Lloh6:
	adrp	x8, _AR_TIMER_MODE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _AR_TIMER_MODE@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #255
	bl	_REG_CLR_BIT
Lloh9:
	adrp	x8, _AR_NDP2_TIMER_MODE@GOTPAGE
Lloh10:
	ldr	x8, [x8, _AR_NDP2_TIMER_MODE@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #255
	bl	_REG_CLR_BIT
Lloh12:
	adrp	x8, _AR_SLP32_INC@GOTPAGE
Lloh13:
	ldr	x8, [x8, _AR_SLP32_INC@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #1048575
	bl	_REG_CLR_BIT
Lloh15:
	adrp	x8, _AR_MCI_INTERRUPT_RX_MSG_EN@GOTPAGE
Lloh16:
	ldr	x8, [x8, _AR_MCI_INTERRUPT_RX_MSG_EN@GOTPAGEOFF]
Lloh17:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #0
	bl	_REG_WRITE
	mov	w0, #100
	bl	_udelay
LBB0_3:
Lloh18:
	adrp	x8, _AR_RTC_FORCE_WAKE@GOTPAGE
Lloh19:
	ldr	x8, [x8, _AR_RTC_FORCE_WAKE@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
Lloh21:
	adrp	x8, _AR_RTC_FORCE_WAKE_EN@GOTPAGE
Lloh22:
	ldr	x8, [x8, _AR_RTC_FORCE_WAKE_EN@GOTPAGEOFF]
Lloh23:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_REG_CLR_BIT
	mov	x0, x19
	bl	_ath9k_hw_mci_is_enabled
	cbz	x0, LBB0_5
; %bb.4:
	mov	w0, #100
	bl	_udelay
LBB0_5:
	mov	x0, x19
	bl	_AR_SREV_9100
	cbnz	w0, LBB0_8
; %bb.6:
	mov	x0, x19
	bl	_AR_SREV_9300_20_OR_LATER
	cbnz	x0, LBB0_8
; %bb.7:
Lloh24:
	adrp	x8, _AR_RC@GOTPAGE
Lloh25:
	ldr	x8, [x8, _AR_RC@GOTPAGEOFF]
Lloh26:
	adrp	x9, _AR_RC_AHB@GOTPAGE
Lloh27:
	ldr	x9, [x9, _AR_RC_AHB@GOTPAGEOFF]
Lloh28:
	ldr	w1, [x8]
Lloh29:
	ldr	w8, [x9]
Lloh30:
	adrp	x9, _AR_RC_HOSTIF@GOTPAGE
Lloh31:
	ldr	x9, [x9, _AR_RC_HOSTIF@GOTPAGEOFF]
Lloh32:
	ldr	w9, [x9]
	orr	w2, w9, w8
	mov	x0, x19
	bl	_REG_WRITE
LBB0_8:
	mov	x0, x19
	bl	_AR_SREV_5416
	cbnz	w0, LBB0_11
; %bb.9:
	mov	x0, x19
	bl	_AR_SREV_9271
	cbnz	w0, LBB0_11
; %bb.10:
Lloh33:
	adrp	x8, _AR_RTC_RESET@GOTPAGE
Lloh34:
	ldr	x8, [x8, _AR_RTC_RESET@GOTPAGEOFF]
Lloh35:
	ldr	w1, [x8]
Lloh36:
	adrp	x8, _AR_RTC_RESET_EN@GOTPAGE
Lloh37:
	ldr	x8, [x8, _AR_RTC_RESET_EN@GOTPAGEOFF]
Lloh38:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_REG_CLR_BIT
	mov	w0, #2
	bl	_udelay
LBB0_11:
	mov	x0, x19
	bl	_AR_SREV_9300_20_OR_LATER
	cbz	x0, LBB0_13
; %bb.12:
Lloh39:
	adrp	x8, _AR_WA@GOTPAGE
Lloh40:
	ldr	x8, [x8, _AR_WA@GOTPAGEOFF]
Lloh41:
	ldr	w1, [x8]
Lloh42:
	adrp	x8, _AR_WA_D3_L1_DISABLE@GOTPAGE
Lloh43:
	ldr	x8, [x8, _AR_WA_D3_L1_DISABLE@GOTPAGEOFF]
	ldr	w9, [x19]
Lloh44:
	ldr	w8, [x8]
	bic	w2, w9, w8
	mov	x0, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_REG_WRITE
LBB0_13:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh28
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.cfi_endproc
                                        ; -- End function
	.comm	_AR_STA_ID1,4,2                 ; @AR_STA_ID1
	.comm	_AR_STA_ID1_PWR_SAV,4,2         ; @AR_STA_ID1_PWR_SAV
	.comm	_AR_TIMER_MODE,4,2              ; @AR_TIMER_MODE
	.comm	_AR_NDP2_TIMER_MODE,4,2         ; @AR_NDP2_TIMER_MODE
	.comm	_AR_SLP32_INC,4,2               ; @AR_SLP32_INC
	.comm	_AR_MCI_INTERRUPT_RX_MSG_EN,4,2 ; @AR_MCI_INTERRUPT_RX_MSG_EN
	.comm	_AR_RTC_FORCE_WAKE,4,2          ; @AR_RTC_FORCE_WAKE
	.comm	_AR_RTC_FORCE_WAKE_EN,4,2       ; @AR_RTC_FORCE_WAKE_EN
	.comm	_AR_RC,4,2                      ; @AR_RC
	.comm	_AR_RC_AHB,4,2                  ; @AR_RC_AHB
	.comm	_AR_RC_HOSTIF,4,2               ; @AR_RC_HOSTIF
	.comm	_AR_RTC_RESET,4,2               ; @AR_RTC_RESET
	.comm	_AR_RTC_RESET_EN,4,2            ; @AR_RTC_RESET_EN
	.comm	_AR_WA,4,2                      ; @AR_WA
	.comm	_AR_WA_D3_L1_DISABLE,4,2        ; @AR_WA_D3_L1_DISABLE
	.no_dead_strip	_ath9k_set_power_sleep
.subsections_via_symbols
