	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function davinci_pcm_dma_request
_davinci_pcm_dma_request:               ## @davinci_pcm_dma_request
	.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, %rdx
	movq	(%rdi), %rax
	movq	(%rax), %r15
	movq	8(%r15), %rax
	movl	(%rax), %edi
	movq	_davinci_pcm_dma_irq@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_EVENTQ_0@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	callq	_edma_alloc_channel
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_4
## %bb.1:
	movl	%ebx, (%r15)
	movl	%ebx, %edi
	callq	_EDMA_CTLR
	movq	_EDMA_SLOT_ANY@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movl	%eax, %edi
	callq	_edma_alloc_slot
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_2
## %bb.3:
	movl	%ebx, 4(%r15)
	leaq	-32(%rbp), %r14
	movl	%ebx, %edi
	movq	%r14, %rsi
	callq	_edma_read_slot
	movq	_TCINTEN@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movl	(%r15), %edi
	callq	_EDMA_CHAN_SLOT
	movl	%eax, %edi
	callq	_EDMA_TCC
	orl	%ebx, %eax
	orl	%eax, -32(%rbp)
	movl	4(%r15), %edi
	callq	_EDMA_CHAN_SLOT
	shll	$5, %eax
	movl	%eax, -28(%rbp)
	movl	4(%r15), %edi
	movq	%r14, %rsi
	callq	_edma_write_slot
	xorl	%ebx, %ebx
	jmp	LBB0_4
LBB0_2:
	movl	(%r15), %edi
	callq	_edma_free_channel
LBB0_4:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_davinci_pcm_dma_irq,4,2        ## @davinci_pcm_dma_irq
	.comm	_EVENTQ_0,4,2                   ## @EVENTQ_0
	.comm	_EDMA_SLOT_ANY,4,2              ## @EDMA_SLOT_ANY
	.comm	_TCINTEN,4,2                    ## @TCINTEN
	.no_dead_strip	_davinci_pcm_dma_request
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function davinci_pcm_dma_request
_davinci_pcm_dma_request:               ; @davinci_pcm_dma_request
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	mov	x2, x0
	ldr	x8, [x0]
	ldr	x20, [x8]
	ldr	x8, [x20, #8]
	ldr	w0, [x8]
Lloh0:
	adrp	x8, _davinci_pcm_dma_irq@GOTPAGE
Lloh1:
	ldr	x8, [x8, _davinci_pcm_dma_irq@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x8, _EVENTQ_0@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EVENTQ_0@GOTPAGEOFF]
Lloh5:
	ldr	w3, [x8]
	bl	_edma_alloc_channel
	mov	x19, x0
	tbnz	w0, #31, LBB0_4
; %bb.1:
	str	w19, [x20]
	mov	x0, x19
	bl	_EDMA_CTLR
Lloh6:
	adrp	x8, _EDMA_SLOT_ANY@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EDMA_SLOT_ANY@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	bl	_edma_alloc_slot
	mov	x19, x0
	tbnz	w0, #31, LBB0_3
; %bb.2:
	str	w19, [x20, #4]
	add	x1, sp, #8
	mov	x0, x19
	bl	_edma_read_slot
Lloh9:
	adrp	x8, _TCINTEN@GOTPAGE
Lloh10:
	ldr	x8, [x8, _TCINTEN@GOTPAGEOFF]
Lloh11:
	ldr	w19, [x8]
	ldr	w0, [x20]
	bl	_EDMA_CHAN_SLOT
	bl	_EDMA_TCC
	orr	w8, w0, w19
	ldr	w9, [sp, #8]
	orr	w8, w8, w9
	str	w8, [sp, #8]
	ldr	w0, [x20, #4]
	bl	_EDMA_CHAN_SLOT
	lsl	w8, w0, #5
	str	w8, [sp, #12]
	ldr	w0, [x20, #4]
	add	x1, sp, #8
	bl	_edma_write_slot
	mov	w19, #0
	b	LBB0_4
LBB0_3:
	ldr	w0, [x20]
	bl	_edma_free_channel
LBB0_4:
	mov	x0, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_davinci_pcm_dma_irq,4,2        ; @davinci_pcm_dma_irq
	.comm	_EVENTQ_0,4,2                   ; @EVENTQ_0
	.comm	_EDMA_SLOT_ANY,4,2              ; @EDMA_SLOT_ANY
	.comm	_TCINTEN,4,2                    ; @TCINTEN
	.no_dead_strip	_davinci_pcm_dma_request
.subsections_via_symbols
