	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ath9k_hw_set_dma
_ath9k_hw_set_dma:                      ## @ath9k_hw_set_dma
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	callq	_ath9k_hw_common
	movq	%rax, %r14
	movq	%rbx, %rdi
	callq	_ENABLE_REGWRITE_BUFFER
	movq	%rbx, %rdi
	callq	_AR_SREV_9300_20_OR_LATER
	testq	%rax, %rax
	jne	LBB0_2
## %bb.1:
	movq	_AR_AHB_MODE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_AR_AHB_PREFETCH_RD_EN@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_REG_SET_BIT
LBB0_2:
	movq	_AR_TXCFG@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	movq	_AR_TXCFG_DMASZ_128B@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_AR_TXCFG_DMASZ_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%rbx, %rdi
	callq	_REG_RMW
	movq	%rbx, %rdi
	callq	_REGWRITE_BUFFER_FLUSH
	movq	%rbx, %rdi
	callq	_AR_SREV_9300_20_OR_LATER
	testq	%rax, %rax
	jne	LBB0_4
## %bb.3:
	movl	(%r15), %esi
	movq	_AR_FTRIG@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	(%rbx), %ecx
	movq	%rbx, %rdi
	callq	_REG_RMW_FIELD
LBB0_4:
	movq	%rbx, %rdi
	callq	_ENABLE_REGWRITE_BUFFER
	movq	_AR_RXCFG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_AR_RXCFG_DMASZ_128B@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_AR_RXCFG_DMASZ_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%rbx, %rdi
	callq	_REG_RMW
	movq	_AR_RXFIFO_CFG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movl	$512, %edx                      ## imm = 0x200
	callq	_REG_WRITE
	movq	%rbx, %rdi
	callq	_AR_SREV_9300_20_OR_LATER
	testq	%rax, %rax
	je	LBB0_6
## %bb.5:
	movq	_AR_RXBP_THRESH@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	movq	_AR_RXBP_THRESH_HP@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	movl	$1, %ecx
	callq	_REG_RMW_FIELD
	movl	(%r15), %esi
	movq	_AR_RXBP_THRESH_LP@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	movl	$1, %ecx
	callq	_REG_RMW_FIELD
	movq	(%r14), %rsi
	subq	8(%rbx), %rsi
	movq	%rbx, %rdi
	callq	_ath9k_hw_set_rx_bufsize
LBB0_6:
	movq	%rbx, %rdi
	callq	_AR_SREV_9285
	testq	%rax, %rax
	je	LBB0_8
## %bb.7:
	movq	_AR_9285_PCU_TXBUF_CTRL_USABLE_SIZE@GOTPCREL(%rip), %rax
	jmp	LBB0_11
LBB0_8:
	movq	%rbx, %rdi
	callq	_AR_SREV_9340_13_OR_LATER
	testq	%rax, %rax
	jne	LBB0_9
## %bb.10:
	movq	_AR_PCU_TXBUF_CTRL_USABLE_SIZE@GOTPCREL(%rip), %rax
	jmp	LBB0_11
LBB0_9:
	movq	_AR_9340_PCU_TXBUF_CTRL_USABLE_SIZE@GOTPCREL(%rip), %rax
LBB0_11:
	movl	(%rax), %r14d
	movq	%rbx, %rdi
	callq	_AR_SREV_9271
	testl	%eax, %eax
	jne	LBB0_13
## %bb.12:
	movq	_AR_PCU_TXBUF_CTRL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movl	%r14d, %edx
	callq	_REG_WRITE
LBB0_13:
	movq	%rbx, %rdi
	callq	_REGWRITE_BUFFER_FLUSH
	movq	%rbx, %rdi
	callq	_AR_SREV_9300_20_OR_LATER
	testq	%rax, %rax
	je	LBB0_14
## %bb.15:
	movq	%rbx, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ath9k_hw_reset_txstatus_ring   ## TAILCALL
LBB0_14:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AR_AHB_MODE,4,2                ## @AR_AHB_MODE
	.comm	_AR_AHB_PREFETCH_RD_EN,4,2      ## @AR_AHB_PREFETCH_RD_EN
	.comm	_AR_TXCFG,4,2                   ## @AR_TXCFG
	.comm	_AR_TXCFG_DMASZ_128B,4,2        ## @AR_TXCFG_DMASZ_128B
	.comm	_AR_TXCFG_DMASZ_MASK,4,2        ## @AR_TXCFG_DMASZ_MASK
	.comm	_AR_FTRIG,4,2                   ## @AR_FTRIG
	.comm	_AR_RXCFG,4,2                   ## @AR_RXCFG
	.comm	_AR_RXCFG_DMASZ_128B,4,2        ## @AR_RXCFG_DMASZ_128B
	.comm	_AR_RXCFG_DMASZ_MASK,4,2        ## @AR_RXCFG_DMASZ_MASK
	.comm	_AR_RXFIFO_CFG,4,2              ## @AR_RXFIFO_CFG
	.comm	_AR_RXBP_THRESH,4,2             ## @AR_RXBP_THRESH
	.comm	_AR_RXBP_THRESH_HP,4,2          ## @AR_RXBP_THRESH_HP
	.comm	_AR_RXBP_THRESH_LP,4,2          ## @AR_RXBP_THRESH_LP
	.comm	_AR_9285_PCU_TXBUF_CTRL_USABLE_SIZE,4,2 ## @AR_9285_PCU_TXBUF_CTRL_USABLE_SIZE
	.comm	_AR_9340_PCU_TXBUF_CTRL_USABLE_SIZE,4,2 ## @AR_9340_PCU_TXBUF_CTRL_USABLE_SIZE
	.comm	_AR_PCU_TXBUF_CTRL_USABLE_SIZE,4,2 ## @AR_PCU_TXBUF_CTRL_USABLE_SIZE
	.comm	_AR_PCU_TXBUF_CTRL,4,2          ## @AR_PCU_TXBUF_CTRL
	.no_dead_strip	_ath9k_hw_set_dma
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ath9k_hw_set_dma
_ath9k_hw_set_dma:                      ; @ath9k_hw_set_dma
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	mov	x19, x0
	bl	_ath9k_hw_common
	mov	x20, x0
	mov	x0, x19
	bl	_ENABLE_REGWRITE_BUFFER
	mov	x0, x19
	bl	_AR_SREV_9300_20_OR_LATER
	cbnz	x0, LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _AR_AHB_MODE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AR_AHB_MODE@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x8, _AR_AHB_PREFETCH_RD_EN@GOTPAGE
Lloh4:
	ldr	x8, [x8, _AR_AHB_PREFETCH_RD_EN@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_REG_SET_BIT
LBB0_2:
Lloh6:
	adrp	x21, _AR_TXCFG@GOTPAGE
Lloh7:
	ldr	x21, [x21, _AR_TXCFG@GOTPAGEOFF]
	ldr	w1, [x21]
Lloh8:
	adrp	x8, _AR_TXCFG_DMASZ_128B@GOTPAGE
Lloh9:
	ldr	x8, [x8, _AR_TXCFG_DMASZ_128B@GOTPAGEOFF]
Lloh10:
	ldr	w2, [x8]
Lloh11:
	adrp	x8, _AR_TXCFG_DMASZ_MASK@GOTPAGE
Lloh12:
	ldr	x8, [x8, _AR_TXCFG_DMASZ_MASK@GOTPAGEOFF]
Lloh13:
	ldr	w3, [x8]
	mov	x0, x19
	bl	_REG_RMW
	mov	x0, x19
	bl	_REGWRITE_BUFFER_FLUSH
	mov	x0, x19
	bl	_AR_SREV_9300_20_OR_LATER
	cbnz	x0, LBB0_4
; %bb.3:
	ldr	w1, [x21]
Lloh14:
	adrp	x8, _AR_FTRIG@GOTPAGE
Lloh15:
	ldr	x8, [x8, _AR_FTRIG@GOTPAGEOFF]
Lloh16:
	ldr	w2, [x8]
	ldr	w3, [x19]
	mov	x0, x19
	bl	_REG_RMW_FIELD
LBB0_4:
	mov	x0, x19
	bl	_ENABLE_REGWRITE_BUFFER
Lloh17:
	adrp	x8, _AR_RXCFG@GOTPAGE
Lloh18:
	ldr	x8, [x8, _AR_RXCFG@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
Lloh20:
	adrp	x8, _AR_RXCFG_DMASZ_128B@GOTPAGE
Lloh21:
	ldr	x8, [x8, _AR_RXCFG_DMASZ_128B@GOTPAGEOFF]
Lloh22:
	ldr	w2, [x8]
Lloh23:
	adrp	x8, _AR_RXCFG_DMASZ_MASK@GOTPAGE
Lloh24:
	ldr	x8, [x8, _AR_RXCFG_DMASZ_MASK@GOTPAGEOFF]
Lloh25:
	ldr	w3, [x8]
	mov	x0, x19
	bl	_REG_RMW
Lloh26:
	adrp	x8, _AR_RXFIFO_CFG@GOTPAGE
Lloh27:
	ldr	x8, [x8, _AR_RXFIFO_CFG@GOTPAGEOFF]
Lloh28:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #512
	bl	_REG_WRITE
	mov	x0, x19
	bl	_AR_SREV_9300_20_OR_LATER
	cbz	x0, LBB0_6
; %bb.5:
Lloh29:
	adrp	x21, _AR_RXBP_THRESH@GOTPAGE
Lloh30:
	ldr	x21, [x21, _AR_RXBP_THRESH@GOTPAGEOFF]
	ldr	w1, [x21]
Lloh31:
	adrp	x8, _AR_RXBP_THRESH_HP@GOTPAGE
Lloh32:
	ldr	x8, [x8, _AR_RXBP_THRESH_HP@GOTPAGEOFF]
Lloh33:
	ldr	w2, [x8]
	mov	x0, x19
	mov	w3, #1
	bl	_REG_RMW_FIELD
	ldr	w1, [x21]
Lloh34:
	adrp	x8, _AR_RXBP_THRESH_LP@GOTPAGE
Lloh35:
	ldr	x8, [x8, _AR_RXBP_THRESH_LP@GOTPAGEOFF]
Lloh36:
	ldr	w2, [x8]
	mov	x0, x19
	mov	w3, #1
	bl	_REG_RMW_FIELD
	ldr	x8, [x20]
	ldr	x9, [x19, #8]
	sub	x1, x8, x9
	mov	x0, x19
	bl	_ath9k_hw_set_rx_bufsize
LBB0_6:
	mov	x0, x19
	bl	_AR_SREV_9285
	cbz	x0, LBB0_8
; %bb.7:
Lloh37:
	adrp	x8, _AR_9285_PCU_TXBUF_CTRL_USABLE_SIZE@GOTPAGE
Lloh38:
	ldr	x8, [x8, _AR_9285_PCU_TXBUF_CTRL_USABLE_SIZE@GOTPAGEOFF]
	b	LBB0_9
LBB0_8:
	mov	x0, x19
	bl	_AR_SREV_9340_13_OR_LATER
Lloh39:
	adrp	x8, _AR_9340_PCU_TXBUF_CTRL_USABLE_SIZE@GOTPAGE
Lloh40:
	ldr	x8, [x8, _AR_9340_PCU_TXBUF_CTRL_USABLE_SIZE@GOTPAGEOFF]
Lloh41:
	adrp	x9, _AR_PCU_TXBUF_CTRL_USABLE_SIZE@GOTPAGE
Lloh42:
	ldr	x9, [x9, _AR_PCU_TXBUF_CTRL_USABLE_SIZE@GOTPAGEOFF]
	cmp	x0, #0
	csel	x8, x9, x8, eq
LBB0_9:
	ldr	w20, [x8]
	mov	x0, x19
	bl	_AR_SREV_9271
	cbnz	w0, LBB0_11
; %bb.10:
Lloh43:
	adrp	x8, _AR_PCU_TXBUF_CTRL@GOTPAGE
Lloh44:
	ldr	x8, [x8, _AR_PCU_TXBUF_CTRL@GOTPAGEOFF]
Lloh45:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x20
	bl	_REG_WRITE
LBB0_11:
	mov	x0, x19
	bl	_REGWRITE_BUFFER_FLUSH
	mov	x0, x19
	bl	_AR_SREV_9300_20_OR_LATER
	cbz	x0, LBB0_13
; %bb.12:
	mov	x0, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_ath9k_hw_reset_txstatus_ring
LBB0_13:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGot	Lloh29, Lloh30
	.loh AdrpLdrGot	Lloh37, Lloh38
	.loh AdrpLdrGot	Lloh41, Lloh42
	.loh AdrpLdrGot	Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh43, Lloh44, Lloh45
	.cfi_endproc
                                        ; -- End function
	.comm	_AR_AHB_MODE,4,2                ; @AR_AHB_MODE
	.comm	_AR_AHB_PREFETCH_RD_EN,4,2      ; @AR_AHB_PREFETCH_RD_EN
	.comm	_AR_TXCFG,4,2                   ; @AR_TXCFG
	.comm	_AR_TXCFG_DMASZ_128B,4,2        ; @AR_TXCFG_DMASZ_128B
	.comm	_AR_TXCFG_DMASZ_MASK,4,2        ; @AR_TXCFG_DMASZ_MASK
	.comm	_AR_FTRIG,4,2                   ; @AR_FTRIG
	.comm	_AR_RXCFG,4,2                   ; @AR_RXCFG
	.comm	_AR_RXCFG_DMASZ_128B,4,2        ; @AR_RXCFG_DMASZ_128B
	.comm	_AR_RXCFG_DMASZ_MASK,4,2        ; @AR_RXCFG_DMASZ_MASK
	.comm	_AR_RXFIFO_CFG,4,2              ; @AR_RXFIFO_CFG
	.comm	_AR_RXBP_THRESH,4,2             ; @AR_RXBP_THRESH
	.comm	_AR_RXBP_THRESH_HP,4,2          ; @AR_RXBP_THRESH_HP
	.comm	_AR_RXBP_THRESH_LP,4,2          ; @AR_RXBP_THRESH_LP
	.comm	_AR_9285_PCU_TXBUF_CTRL_USABLE_SIZE,4,2 ; @AR_9285_PCU_TXBUF_CTRL_USABLE_SIZE
	.comm	_AR_9340_PCU_TXBUF_CTRL_USABLE_SIZE,4,2 ; @AR_9340_PCU_TXBUF_CTRL_USABLE_SIZE
	.comm	_AR_PCU_TXBUF_CTRL_USABLE_SIZE,4,2 ; @AR_PCU_TXBUF_CTRL_USABLE_SIZE
	.comm	_AR_PCU_TXBUF_CTRL,4,2          ; @AR_PCU_TXBUF_CTRL
	.no_dead_strip	_ath9k_hw_set_dma
.subsections_via_symbols
