	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sun6i_dma_resume
_sun6i_dma_resume:                      ## @sun6i_dma_resume
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movl	(%rdi), %edi
	callq	_to_sun6i_dma_dev
	movq	%rax, %r14
	movq	%rbx, %rdi
	callq	_to_sun6i_vchan
	movq	%rax, %r15
	movq	16(%rax), %r12
	movq	%rbx, %rdi
	callq	_chan2dev
	leaq	L_.str(%rip), %rsi
	movl	%eax, %edi
	movq	%r15, %rdx
	callq	_dev_dbg
	movq	%r15, %rdi
	callq	_spin_lock_irqsave
	testq	%r12, %r12
	je	LBB0_2
## %bb.1:
	movq	_DMA_CHAN_PAUSE_RESUME@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_DMA_CHAN_PAUSE@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	(%r12), %rsi
	callq	_writel
	jmp	LBB0_4
LBB0_2:
	leaq	4(%r15), %rdi
	callq	_list_empty
	testl	%eax, %eax
	jne	LBB0_4
## %bb.3:
	movq	%r14, %rdi
	callq	_spin_lock
	movq	%r15, %rdi
	addq	$8, %rdi
	movq	%r14, %rsi
	addq	$4, %rsi
	callq	_list_add_tail
	movq	%r14, %rdi
	callq	_spin_unlock
LBB0_4:
	movq	%r15, %rdi
	callq	_spin_unlock_irqrestore
	xorl	%eax, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"vchan %p: resume\n"

	.comm	_DMA_CHAN_PAUSE_RESUME,4,2      ## @DMA_CHAN_PAUSE_RESUME
	.comm	_DMA_CHAN_PAUSE,8,3             ## @DMA_CHAN_PAUSE
	.no_dead_strip	_sun6i_dma_resume
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sun6i_dma_resume
_sun6i_dma_resume:                      ; @sun6i_dma_resume
	.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	x21, x0
	ldr	w0, [x0]
	bl	_to_sun6i_dma_dev
	mov	x20, x0
	mov	x0, x21
	bl	_to_sun6i_vchan
	mov	x19, x0
	ldr	x22, [x0, #16]
	mov	x0, x21
	bl	_chan2dev
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x19
	bl	_dev_dbg
	mov	x0, x19
	bl	_spin_lock_irqsave
	cbz	x22, LBB0_2
; %bb.1:
Lloh2:
	adrp	x8, _DMA_CHAN_PAUSE_RESUME@GOTPAGE
Lloh3:
	ldr	x8, [x8, _DMA_CHAN_PAUSE_RESUME@GOTPAGEOFF]
Lloh4:
	ldr	w0, [x8]
	ldr	x8, [x22]
Lloh5:
	adrp	x9, _DMA_CHAN_PAUSE@GOTPAGE
Lloh6:
	ldr	x9, [x9, _DMA_CHAN_PAUSE@GOTPAGEOFF]
Lloh7:
	ldr	x9, [x9]
	add	x1, x9, x8
	bl	_writel
	b	LBB0_4
LBB0_2:
	add	x0, x19, #4
	bl	_list_empty
	cbnz	w0, LBB0_4
; %bb.3:
	mov	x0, x20
	bl	_spin_lock
	add	x0, x19, #8
	add	x1, x20, #4
	bl	_list_add_tail
	mov	x0, x20
	bl	_spin_unlock
LBB0_4:
	mov	x0, x19
	bl	_spin_unlock_irqrestore
	mov	w0, #0
	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 AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"vchan %p: resume\n"

	.comm	_DMA_CHAN_PAUSE_RESUME,4,2      ; @DMA_CHAN_PAUSE_RESUME
	.comm	_DMA_CHAN_PAUSE,8,3             ; @DMA_CHAN_PAUSE
	.no_dead_strip	_sun6i_dma_resume
.subsections_via_symbols
