	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mmc_omap_release_dma
_mmc_omap_release_dma:                  ## @mmc_omap_release_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	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %r15
	movl	24(%rdi), %edi
	callq	_mmc_dev
	movq	_MMC_DATA_WRITE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r13d
	xorl	%ecx, %ecx
	andl	(%r14), %r13d
	setne	%cl
	movq	8(%r15,%rcx,8), %r12
	movq	_DMA_FROM_DEVICE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movq	_DMA_TO_DEVICE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ebx
	testq	%r12, %r12
	je	LBB0_4
## %bb.1:
	cmpq	$0, 16(%r14)
	je	LBB0_3
## %bb.2:
	movq	%r12, %rdi
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	callq	_dmaengine_terminate_all
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	movq	$0, 8(%r14)
LBB0_3:
	movq	(%r12), %rax
	movq	(%rax), %rax
LBB0_4:
	testl	%r13d, %r13d
	cmovel	%edx, %ebx
	movl	4(%r14), %esi
	movl	(%r15), %edx
	movq	%rax, %rdi
	movl	%ebx, %ecx
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_dma_unmap_sg                   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_MMC_DATA_WRITE,4,2             ## @MMC_DATA_WRITE
	.comm	_DMA_TO_DEVICE,4,2              ## @DMA_TO_DEVICE
	.comm	_DMA_FROM_DEVICE,4,2            ## @DMA_FROM_DEVICE
	.no_dead_strip	_mmc_omap_release_dma
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mmc_omap_release_dma
_mmc_omap_release_dma:                  ; @mmc_omap_release_dma
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x20, x1
	mov	x19, x0
	ldr	w0, [x0, #24]
	bl	_mmc_dev
	ldr	w8, [x20]
Lloh0:
	adrp	x9, _MMC_DATA_WRITE@GOTPAGE
Lloh1:
	ldr	x9, [x9, _MMC_DATA_WRITE@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	ands	w22, w9, w8
	mov	w8, #16
	mov	w9, #8
	csel	x8, x9, x8, eq
	ldr	x21, [x19, x8]
Lloh3:
	adrp	x8, _DMA_FROM_DEVICE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _DMA_FROM_DEVICE@GOTPAGEOFF]
Lloh5:
	ldr	w23, [x8]
Lloh6:
	adrp	x8, _DMA_TO_DEVICE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _DMA_TO_DEVICE@GOTPAGEOFF]
Lloh8:
	ldr	w24, [x8]
	cbz	x21, LBB0_4
; %bb.1:
	ldr	x8, [x20, #16]
	cbz	x8, LBB0_3
; %bb.2:
	mov	x0, x21
	bl	_dmaengine_terminate_all
	str	xzr, [x20, #8]
LBB0_3:
	ldr	x8, [x21]
	ldr	x0, [x8]
LBB0_4:
	cmp	w22, #0
	csel	w3, w23, w24, eq
	ldr	w1, [x20, #4]
	ldr	w2, [x19]
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_dma_unmap_sg
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_MMC_DATA_WRITE,4,2             ; @MMC_DATA_WRITE
	.comm	_DMA_TO_DEVICE,4,2              ; @DMA_TO_DEVICE
	.comm	_DMA_FROM_DEVICE,4,2            ; @DMA_FROM_DEVICE
	.no_dead_strip	_mmc_omap_release_dma
.subsections_via_symbols
