	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ath9k_hw_stopdmarecv           ## -- Begin function ath9k_hw_stopdmarecv
	.p2align	4, 0x90
_ath9k_hw_stopdmarecv:                  ## @ath9k_hw_stopdmarecv
	.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
	movq	%rsi, -48(%rbp)                 ## 8-byte Spill
	movq	%rdi, %r12
	callq	_ath9k_hw_common
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movq	_AR_MACMISC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_AR_MACMISC_DMA_OBS_LINE_8@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_AR_MACMISC_DMA_OBS_S@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	shll	%cl, %eax
	movq	_AR_MACMISC_MISC_OBS_BUS_1@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movq	_AR_MACMISC_MISC_OBS_BUS_MSB_S@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	shll	%cl, %edx
	orl	%eax, %edx
	movq	%r12, %rdi
	callq	_REG_WRITE
	movq	_AR_CR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_AR_CR_RXD@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r12, %rdi
	callq	_REG_WRITE
	movq	_AH_TIME_QUANTUM@GOTPCREL(%rip), %rcx
	xorl	%r14d, %r14d
	movl	$10000, %eax                    ## imm = 0x2710
	xorl	%edx, %edx
	idivl	(%rcx)
	testl	%eax, %eax
	je	LBB0_6
## %bb.1:
	movl	%eax, %ebx
	movl	$1, %r13d
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_4:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	%r14d, %r15d
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	_AH_TIME_QUANTUM@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_udelay
	movl	%r15d, %r14d
	decl	%ebx
	je	LBB0_6
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	_AR_CR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_REG_READ
	movq	_AR_CR_RXE@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_10
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%r12, %rdi
	callq	_AR_SREV_9300_20_OR_LATER
	testl	%eax, %eax
	jne	LBB0_4
## %bb.7:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_AR_DMADBG_7@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_REG_READ
	movl	%eax, %r15d
	andl	$2032, %r15d                    ## imm = 0x7F0
	cmpl	$448, %r15d                     ## imm = 0x1C0
	jne	LBB0_5
## %bb.8:                               ##   in Loop: Header=BB0_2 Depth=1
	cmpl	$448, %r14d                     ## imm = 0x1C0
	jne	LBB0_5
## %bb.9:
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movl	$1, (%rax)
	jmp	LBB0_10
LBB0_6:
	movq	_AR_CR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_REG_READ
	movl	%eax, %r15d
	movq	_AR_DIAG_SW@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_REG_READ
	movl	%eax, %ebx
	movq	_AR_DMADBG_7@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_REG_READ
	leaq	L_.str(%rip), %rsi
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movl	$10, %edx
	movl	%r15d, %ecx
	movl	%ebx, %r8d
	movl	%eax, %r9d
	callq	_ath_err
	xorl	%r13d, %r13d
LBB0_10:
	movl	%r13d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AR_MACMISC,4,2                 ## @AR_MACMISC
	.comm	_AR_MACMISC_DMA_OBS_LINE_8,4,2  ## @AR_MACMISC_DMA_OBS_LINE_8
	.comm	_AR_MACMISC_DMA_OBS_S,4,2       ## @AR_MACMISC_DMA_OBS_S
	.comm	_AR_MACMISC_MISC_OBS_BUS_1,4,2  ## @AR_MACMISC_MISC_OBS_BUS_1
	.comm	_AR_MACMISC_MISC_OBS_BUS_MSB_S,4,2 ## @AR_MACMISC_MISC_OBS_BUS_MSB_S
	.comm	_AR_CR,4,2                      ## @AR_CR
	.comm	_AR_CR_RXD,4,2                  ## @AR_CR_RXD
	.comm	_AH_TIME_QUANTUM,4,2            ## @AH_TIME_QUANTUM
	.comm	_AR_CR_RXE,4,2                  ## @AR_CR_RXE
	.comm	_AR_DMADBG_7,4,2                ## @AR_DMADBG_7
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"DMA failed to stop in %d ms AR_CR=0x%08x AR_DIAG_SW=0x%08x DMADBG_7=0x%08x\n"

	.comm	_AR_DIAG_SW,4,2                 ## @AR_DIAG_SW
	.comm	_AH_RX_STOP_DMA_TIMEOUT,4,2     ## @AH_RX_STOP_DMA_TIMEOUT
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ath9k_hw_stopdmarecv           ; -- Begin function ath9k_hw_stopdmarecv
	.p2align	2
_ath9k_hw_stopdmarecv:                  ; @ath9k_hw_stopdmarecv
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x21, x1
	mov	x20, x0
	bl	_ath9k_hw_common
	mov	x19, x0
Lloh0:
	adrp	x8, _AR_MACMISC@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AR_MACMISC@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x8, _AR_MACMISC_DMA_OBS_LINE_8@GOTPAGE
Lloh4:
	ldr	x8, [x8, _AR_MACMISC_DMA_OBS_LINE_8@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
Lloh6:
	adrp	x9, _AR_MACMISC_DMA_OBS_S@GOTPAGE
Lloh7:
	ldr	x9, [x9, _AR_MACMISC_DMA_OBS_S@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	lsl	w8, w8, w9
Lloh9:
	adrp	x9, _AR_MACMISC_MISC_OBS_BUS_1@GOTPAGE
Lloh10:
	ldr	x9, [x9, _AR_MACMISC_MISC_OBS_BUS_1@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
Lloh12:
	adrp	x10, _AR_MACMISC_MISC_OBS_BUS_MSB_S@GOTPAGE
Lloh13:
	ldr	x10, [x10, _AR_MACMISC_MISC_OBS_BUS_MSB_S@GOTPAGEOFF]
Lloh14:
	ldr	w10, [x10]
	lsl	w9, w9, w10
	orr	w2, w9, w8
	mov	x0, x20
	bl	_REG_WRITE
Lloh15:
	adrp	x22, _AR_CR@GOTPAGE
Lloh16:
	ldr	x22, [x22, _AR_CR@GOTPAGEOFF]
	ldr	w1, [x22]
Lloh17:
	adrp	x8, _AR_CR_RXD@GOTPAGE
Lloh18:
	ldr	x8, [x8, _AR_CR_RXD@GOTPAGEOFF]
Lloh19:
	ldr	w2, [x8]
	mov	x0, x20
	bl	_REG_WRITE
Lloh20:
	adrp	x24, _AH_TIME_QUANTUM@GOTPAGE
Lloh21:
	ldr	x24, [x24, _AH_TIME_QUANTUM@GOTPAGEOFF]
	ldr	w8, [x24]
	mov	w9, #10000
	sdiv	w25, w9, w8
Lloh22:
	adrp	x23, _AR_DMADBG_7@GOTPAGE
Lloh23:
	ldr	x23, [x23, _AR_DMADBG_7@GOTPAGEOFF]
	cbz	w25, LBB0_9
; %bb.1:
	mov	w27, #0
Lloh24:
	adrp	x26, _AR_CR_RXE@GOTPAGE
Lloh25:
	ldr	x26, [x26, _AR_CR_RXE@GOTPAGEOFF]
	b	LBB0_4
LBB0_2:                                 ;   in Loop: Header=BB0_4 Depth=1
	mov	x28, x27
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	ldr	w0, [x24]
	bl	_udelay
	mov	x27, x28
	subs	w25, w25, #1
	b.eq	LBB0_9
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w1, [x22]
	mov	x0, x20
	bl	_REG_READ
	ldr	w8, [x26]
	tst	w8, w0
	b.eq	LBB0_10
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x0, x20
	bl	_AR_SREV_9300_20_OR_LATER
	cbnz	w0, LBB0_2
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w1, [x23]
	mov	x0, x20
	bl	_REG_READ
	and	w28, w0, #0x7f0
	cmp	w28, #448
	b.ne	LBB0_3
; %bb.7:                                ;   in Loop: Header=BB0_4 Depth=1
	cmp	w27, #448
	b.ne	LBB0_3
; %bb.8:
	mov	w0, #1
	str	w0, [x21]
	b	LBB0_11
LBB0_9:
	ldr	w1, [x22]
	mov	x0, x20
	bl	_REG_READ
	mov	x21, x0
Lloh26:
	adrp	x8, _AR_DIAG_SW@GOTPAGE
Lloh27:
	ldr	x8, [x8, _AR_DIAG_SW@GOTPAGEOFF]
Lloh28:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_REG_READ
	mov	x22, x0
	ldr	w1, [x23]
	mov	x0, x20
	bl	_REG_READ
	mov	x5, x0
Lloh29:
	adrp	x1, l_.str@PAGE
Lloh30:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	mov	w2, #10
	mov	x3, x21
	mov	x4, x22
	bl	_ath_err
	mov	w0, #0
	b	LBB0_11
LBB0_10:
	mov	w0, #1
LBB0_11:
	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
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.cfi_endproc
                                        ; -- End function
	.comm	_AR_MACMISC,4,2                 ; @AR_MACMISC
	.comm	_AR_MACMISC_DMA_OBS_LINE_8,4,2  ; @AR_MACMISC_DMA_OBS_LINE_8
	.comm	_AR_MACMISC_DMA_OBS_S,4,2       ; @AR_MACMISC_DMA_OBS_S
	.comm	_AR_MACMISC_MISC_OBS_BUS_1,4,2  ; @AR_MACMISC_MISC_OBS_BUS_1
	.comm	_AR_MACMISC_MISC_OBS_BUS_MSB_S,4,2 ; @AR_MACMISC_MISC_OBS_BUS_MSB_S
	.comm	_AR_CR,4,2                      ; @AR_CR
	.comm	_AR_CR_RXD,4,2                  ; @AR_CR_RXD
	.comm	_AH_TIME_QUANTUM,4,2            ; @AH_TIME_QUANTUM
	.comm	_AR_CR_RXE,4,2                  ; @AR_CR_RXE
	.comm	_AR_DMADBG_7,4,2                ; @AR_DMADBG_7
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"DMA failed to stop in %d ms AR_CR=0x%08x AR_DIAG_SW=0x%08x DMADBG_7=0x%08x\n"

	.comm	_AR_DIAG_SW,4,2                 ; @AR_DIAG_SW
	.comm	_AH_RX_STOP_DMA_TIMEOUT,4,2     ; @AH_RX_STOP_DMA_TIMEOUT
.subsections_via_symbols
