	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function zx_dma_terminate_chan
_zx_dma_terminate_chan:                 ## @zx_dma_terminate_chan
	.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	%rsi, %r14
	movq	%rdi, %rbx
	movq	_REG_ZX_CTRL@GOTPCREL(%rip), %r15
	movq	(%r15), %rdi
	addq	8(%rbx), %rdi
	callq	_readl_relaxed
	movq	_ZX_CH_ENABLE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	notl	%edi
	andl	%eax, %edi
	movq	_ZX_FORCE_CLOSE@GOTPCREL(%rip), %rax
	orl	(%rax), %edi
	movq	(%r15), %rsi
	addq	8(%rbx), %rsi
	callq	_writel_relaxed
	movb	(%rbx), %cl
	movl	$1, %ebx
	shll	%cl, %ebx
	movq	_REG_ZX_TC_IRQ_RAW@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	(%r14), %rsi
	movl	%ebx, %edi
	callq	_writel_relaxed
	movq	_REG_ZX_SRC_ERR_IRQ_RAW@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	(%r14), %rsi
	movl	%ebx, %edi
	callq	_writel_relaxed
	movq	_REG_ZX_DST_ERR_IRQ_RAW@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	(%r14), %rsi
	movl	%ebx, %edi
	callq	_writel_relaxed
	movq	_REG_ZX_CFG_ERR_IRQ_RAW@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	(%r14), %rsi
	movl	%ebx, %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_writel_relaxed                 ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_REG_ZX_CTRL,8,3                ## @REG_ZX_CTRL
	.comm	_ZX_CH_ENABLE,4,2               ## @ZX_CH_ENABLE
	.comm	_ZX_FORCE_CLOSE,4,2             ## @ZX_FORCE_CLOSE
	.comm	_REG_ZX_TC_IRQ_RAW,8,3          ## @REG_ZX_TC_IRQ_RAW
	.comm	_REG_ZX_SRC_ERR_IRQ_RAW,8,3     ## @REG_ZX_SRC_ERR_IRQ_RAW
	.comm	_REG_ZX_DST_ERR_IRQ_RAW,8,3     ## @REG_ZX_DST_ERR_IRQ_RAW
	.comm	_REG_ZX_CFG_ERR_IRQ_RAW,8,3     ## @REG_ZX_CFG_ERR_IRQ_RAW
	.no_dead_strip	_zx_dma_terminate_chan
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function zx_dma_terminate_chan
_zx_dma_terminate_chan:                 ; @zx_dma_terminate_chan
	.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, x1
	mov	x20, x0
	ldr	x8, [x0, #8]
Lloh0:
	adrp	x21, _REG_ZX_CTRL@GOTPAGE
Lloh1:
	ldr	x21, [x21, _REG_ZX_CTRL@GOTPAGEOFF]
	ldr	x9, [x21]
	add	x0, x9, x8
	bl	_readl_relaxed
Lloh2:
	adrp	x8, _ZX_CH_ENABLE@GOTPAGE
Lloh3:
	ldr	x8, [x8, _ZX_CH_ENABLE@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
Lloh5:
	adrp	x9, _ZX_FORCE_CLOSE@GOTPAGE
Lloh6:
	ldr	x9, [x9, _ZX_FORCE_CLOSE@GOTPAGEOFF]
	bic	w8, w0, w8
Lloh7:
	ldr	w9, [x9]
	orr	w0, w8, w9
	ldr	x8, [x20, #8]
	ldr	x9, [x21]
	add	x1, x9, x8
	bl	_writel_relaxed
	ldr	w8, [x20]
	mov	w9, #1
	lsl	w20, w9, w8
	ldr	x8, [x19]
Lloh8:
	adrp	x9, _REG_ZX_TC_IRQ_RAW@GOTPAGE
Lloh9:
	ldr	x9, [x9, _REG_ZX_TC_IRQ_RAW@GOTPAGEOFF]
Lloh10:
	ldr	x9, [x9]
	add	x1, x9, x8
	mov	x0, x20
	bl	_writel_relaxed
	ldr	x8, [x19]
Lloh11:
	adrp	x9, _REG_ZX_SRC_ERR_IRQ_RAW@GOTPAGE
Lloh12:
	ldr	x9, [x9, _REG_ZX_SRC_ERR_IRQ_RAW@GOTPAGEOFF]
Lloh13:
	ldr	x9, [x9]
	add	x1, x9, x8
	mov	x0, x20
	bl	_writel_relaxed
	ldr	x8, [x19]
Lloh14:
	adrp	x9, _REG_ZX_DST_ERR_IRQ_RAW@GOTPAGE
Lloh15:
	ldr	x9, [x9, _REG_ZX_DST_ERR_IRQ_RAW@GOTPAGEOFF]
Lloh16:
	ldr	x9, [x9]
	add	x1, x9, x8
	mov	x0, x20
	bl	_writel_relaxed
	ldr	x8, [x19]
Lloh17:
	adrp	x9, _REG_ZX_CFG_ERR_IRQ_RAW@GOTPAGE
Lloh18:
	ldr	x9, [x9, _REG_ZX_CFG_ERR_IRQ_RAW@GOTPAGEOFF]
Lloh19:
	ldr	x9, [x9]
	add	x1, x9, x8
	mov	x0, x20
	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	_writel_relaxed
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_REG_ZX_CTRL,8,3                ; @REG_ZX_CTRL
	.comm	_ZX_CH_ENABLE,4,2               ; @ZX_CH_ENABLE
	.comm	_ZX_FORCE_CLOSE,4,2             ; @ZX_FORCE_CLOSE
	.comm	_REG_ZX_TC_IRQ_RAW,8,3          ; @REG_ZX_TC_IRQ_RAW
	.comm	_REG_ZX_SRC_ERR_IRQ_RAW,8,3     ; @REG_ZX_SRC_ERR_IRQ_RAW
	.comm	_REG_ZX_DST_ERR_IRQ_RAW,8,3     ; @REG_ZX_DST_ERR_IRQ_RAW
	.comm	_REG_ZX_CFG_ERR_IRQ_RAW,8,3     ; @REG_ZX_CFG_ERR_IRQ_RAW
	.no_dead_strip	_zx_dma_terminate_chan
.subsections_via_symbols
