	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function tegra_adma_start
_tegra_adma_start:                      ## @tegra_adma_start
	.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, %r15
	addq	$24, %rdi
	callq	_vchan_next_desc
	testq	%rax, %rax
	je	LBB0_3
## %bb.1:
	movq	%rax, %rbx
	movq	%rax, %rdi
	addq	$4, %rdi
	callq	_list_del
	movq	%rbx, %rdi
	callq	_to_tegra_adma_desc
	testq	%rax, %rax
	je	LBB0_4
## %bb.2:
	movq	%rax, %r14
	xorps	%xmm0, %xmm0
	movups	%xmm0, 8(%r15)
	movq	_ADMA_CH_TC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	(%r14), %edx
	movq	%r15, %rdi
	callq	_tdma_ch_write
	movq	_ADMA_CH_CTRL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	4(%r14), %edx
	movq	%r15, %rdi
	callq	_tdma_ch_write
	movq	_ADMA_CH_LOWER_SRC_ADDR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	8(%r14), %edx
	movq	%r15, %rdi
	callq	_tdma_ch_write
	movq	_ADMA_CH_LOWER_TRG_ADDR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	12(%r14), %edx
	movq	%r15, %rdi
	callq	_tdma_ch_write
	movq	_ADMA_CH_FIFO_CTRL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	16(%r14), %edx
	movq	%r15, %rdi
	callq	_tdma_ch_write
	movq	_ADMA_CH_CONFIG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	20(%r14), %edx
	movq	%r15, %rdi
	callq	_tdma_ch_write
	movq	_ADMA_CH_CMD@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	$1, %edx
	callq	_tdma_ch_write
	movq	%r14, (%r15)
LBB0_3:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	movq	%r15, %rdi
	callq	_tdc2dev
	leaq	L_.str(%rip), %rsi
	movl	%eax, %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_dev_warn                       ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"unable to start DMA, no descriptor\n"

	.comm	_ADMA_CH_TC,4,2                 ## @ADMA_CH_TC
	.comm	_ADMA_CH_CTRL,4,2               ## @ADMA_CH_CTRL
	.comm	_ADMA_CH_LOWER_SRC_ADDR,4,2     ## @ADMA_CH_LOWER_SRC_ADDR
	.comm	_ADMA_CH_LOWER_TRG_ADDR,4,2     ## @ADMA_CH_LOWER_TRG_ADDR
	.comm	_ADMA_CH_FIFO_CTRL,4,2          ## @ADMA_CH_FIFO_CTRL
	.comm	_ADMA_CH_CONFIG,4,2             ## @ADMA_CH_CONFIG
	.comm	_ADMA_CH_CMD,4,2                ## @ADMA_CH_CMD
	.no_dead_strip	_tegra_adma_start
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function tegra_adma_start
_tegra_adma_start:                      ; @tegra_adma_start
	.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
	add	x0, x0, #24
	bl	_vchan_next_desc
	cbz	x0, LBB0_3
; %bb.1:
	mov	x20, x0
	add	x0, x0, #4
	bl	_list_del
	mov	x0, x20
	bl	_to_tegra_adma_desc
	cbz	x0, LBB0_4
; %bb.2:
	mov	x20, x0
	stp	xzr, xzr, [x19, #8]
Lloh0:
	adrp	x8, _ADMA_CH_TC@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ADMA_CH_TC@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	ldr	w2, [x0]
	mov	x0, x19
	bl	_tdma_ch_write
Lloh3:
	adrp	x8, _ADMA_CH_CTRL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ADMA_CH_CTRL@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	ldr	w2, [x20, #4]
	mov	x0, x19
	bl	_tdma_ch_write
Lloh6:
	adrp	x8, _ADMA_CH_LOWER_SRC_ADDR@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ADMA_CH_LOWER_SRC_ADDR@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	ldr	w2, [x20, #8]
	mov	x0, x19
	bl	_tdma_ch_write
Lloh9:
	adrp	x8, _ADMA_CH_LOWER_TRG_ADDR@GOTPAGE
Lloh10:
	ldr	x8, [x8, _ADMA_CH_LOWER_TRG_ADDR@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
	ldr	w2, [x20, #12]
	mov	x0, x19
	bl	_tdma_ch_write
Lloh12:
	adrp	x8, _ADMA_CH_FIFO_CTRL@GOTPAGE
Lloh13:
	ldr	x8, [x8, _ADMA_CH_FIFO_CTRL@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	ldr	w2, [x20, #16]
	mov	x0, x19
	bl	_tdma_ch_write
Lloh15:
	adrp	x8, _ADMA_CH_CONFIG@GOTPAGE
Lloh16:
	ldr	x8, [x8, _ADMA_CH_CONFIG@GOTPAGEOFF]
Lloh17:
	ldr	w1, [x8]
	ldr	w2, [x20, #20]
	mov	x0, x19
	bl	_tdma_ch_write
Lloh18:
	adrp	x8, _ADMA_CH_CMD@GOTPAGE
Lloh19:
	ldr	x8, [x8, _ADMA_CH_CMD@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #1
	bl	_tdma_ch_write
	str	x20, [x19]
LBB0_3:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
LBB0_4:
	mov	x0, x19
	bl	_tdc2dev
Lloh21:
	adrp	x1, l_.str@PAGE
Lloh22:
	add	x1, x1, l_.str@PAGEOFF
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_dev_warn
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.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 AdrpAdd	Lloh21, Lloh22
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"unable to start DMA, no descriptor\n"

	.comm	_ADMA_CH_TC,4,2                 ; @ADMA_CH_TC
	.comm	_ADMA_CH_CTRL,4,2               ; @ADMA_CH_CTRL
	.comm	_ADMA_CH_LOWER_SRC_ADDR,4,2     ; @ADMA_CH_LOWER_SRC_ADDR
	.comm	_ADMA_CH_LOWER_TRG_ADDR,4,2     ; @ADMA_CH_LOWER_TRG_ADDR
	.comm	_ADMA_CH_FIFO_CTRL,4,2          ; @ADMA_CH_FIFO_CTRL
	.comm	_ADMA_CH_CONFIG,4,2             ; @ADMA_CH_CONFIG
	.comm	_ADMA_CH_CMD,4,2                ; @ADMA_CH_CMD
	.no_dead_strip	_tegra_adma_start
.subsections_via_symbols
