	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function i2c_imx_dma_xfer
_i2c_imx_dma_xfer:                      ## @i2c_imx_dma_xfer
	.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, %r15
	movq	8(%rdi), %rbx
	movq	16(%rbx), %rax
	movq	(%rax), %rax
	movq	(%rax), %r14
	movl	(%rsi), %esi
	movl	(%rbx), %ecx
	movl	4(%rbx), %edx
	movq	%r14, %rdi
	callq	_dma_map_single
	movl	%eax, 8(%rbx)
	movq	%r14, %rdi
	movl	%eax, %esi
	callq	_dma_mapping_error
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rsi
	movq	%r15, %rdi
	callq	_dev_err
	jmp	LBB0_7
LBB0_2:
	movq	16(%rbx), %rdi
	movl	4(%rbx), %edx
	movl	8(%rbx), %esi
	movl	28(%rbx), %ecx
	movq	_DMA_PREP_INTERRUPT@GOTPCREL(%rip), %r9
	movq	_DMA_CTRL_ACK@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	orl	(%r9), %r8d
	callq	_dmaengine_prep_slave_single
	testq	%rax, %rax
	je	LBB0_3
## %bb.4:
	movq	%rax, %r12
	leaq	24(%rbx), %rdi
	callq	_reinit_completion
	movq	_i2c_imx_dma_callback@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 8(%r12)
	movq	%r15, (%r12)
	movq	%r12, %rdi
	callq	_dmaengine_submit
	movl	%eax, %edi
	callq	_dma_submit_error
	testq	%rax, %rax
	je	LBB0_9
## %bb.5:
	leaq	L_.str.2(%rip), %rsi
	movq	%r15, %rdi
	callq	_dev_err
	movq	16(%rbx), %rdi
	callq	_dmaengine_terminate_all
	jmp	LBB0_6
LBB0_3:
	leaq	L_.str.1(%rip), %rsi
	movq	%r15, %rdi
	callq	_dev_err
LBB0_6:
	movl	8(%rbx), %esi
	movl	(%rbx), %ecx
	movl	4(%rbx), %edx
	movq	%r14, %rdi
	callq	_dma_unmap_single
LBB0_7:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_8:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_9:
	movq	16(%rbx), %rdi
	callq	_dma_async_issue_pending
	xorl	%eax, %eax
	jmp	LBB0_8
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"DMA mapping failed\n"

	.comm	_DMA_PREP_INTERRUPT,4,2         ## @DMA_PREP_INTERRUPT
	.comm	_DMA_CTRL_ACK,4,2               ## @DMA_CTRL_ACK
L_.str.1:                               ## @.str.1
	.asciz	"Not able to get desc for DMA xfer\n"

	.comm	_i2c_imx_dma_callback,4,2       ## @i2c_imx_dma_callback
L_.str.2:                               ## @.str.2
	.asciz	"DMA submit failed\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_i2c_imx_dma_xfer
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function i2c_imx_dma_xfer
_i2c_imx_dma_xfer:                      ; @i2c_imx_dma_xfer
	.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	x20, x0
	ldr	x22, [x0, #8]
	ldr	x8, [x22, #16]
	ldr	x8, [x8]
	ldr	x19, [x8]
	ldr	w1, [x1]
	ldp	w3, w2, [x22]
	mov	x0, x19
	bl	_dma_map_single
	mov	x1, x0
	str	w0, [x22, #8]
	mov	x0, x19
	bl	_dma_mapping_error
	cbz	x0, LBB0_2
; %bb.1:
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_dev_err
	b	LBB0_7
LBB0_2:
	ldr	x0, [x22, #16]
	ldp	w2, w1, [x22, #4]
Lloh2:
	adrp	x8, _DMA_PREP_INTERRUPT@GOTPAGE
Lloh3:
	ldr	x8, [x8, _DMA_PREP_INTERRUPT@GOTPAGEOFF]
	ldr	w3, [x22, #28]
Lloh4:
	ldr	w8, [x8]
Lloh5:
	adrp	x9, _DMA_CTRL_ACK@GOTPAGE
Lloh6:
	ldr	x9, [x9, _DMA_CTRL_ACK@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	orr	w4, w9, w8
	bl	_dmaengine_prep_slave_single
	cbz	x0, LBB0_5
; %bb.3:
	mov	x21, x0
	add	x0, x22, #24
	bl	_reinit_completion
Lloh8:
	adrp	x8, _i2c_imx_dma_callback@GOTPAGE
Lloh9:
	ldr	x8, [x8, _i2c_imx_dma_callback@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	str	w8, [x21, #8]
	str	x20, [x21]
	mov	x0, x21
	bl	_dmaengine_submit
	bl	_dma_submit_error
	cbz	x0, LBB0_9
; %bb.4:
Lloh11:
	adrp	x1, l_.str.2@PAGE
Lloh12:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x20
	bl	_dev_err
	ldr	x0, [x22, #16]
	bl	_dmaengine_terminate_all
	b	LBB0_6
LBB0_5:
Lloh13:
	adrp	x1, l_.str.1@PAGE
Lloh14:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x20
	bl	_dev_err
LBB0_6:
	ldp	w2, w1, [x22, #4]
	ldr	w3, [x22]
	mov	x0, x19
	bl	_dma_unmap_single
LBB0_7:
Lloh15:
	adrp	x8, _EINVAL@GOTPAGE
Lloh16:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_8:
	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
LBB0_9:
	ldr	x0, [x22, #16]
	bl	_dma_async_issue_pending
	mov	w0, #0
	b	LBB0_8
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"DMA mapping failed\n"

	.comm	_DMA_PREP_INTERRUPT,4,2         ; @DMA_PREP_INTERRUPT
	.comm	_DMA_CTRL_ACK,4,2               ; @DMA_CTRL_ACK
l_.str.1:                               ; @.str.1
	.asciz	"Not able to get desc for DMA xfer\n"

	.comm	_i2c_imx_dma_callback,4,2       ; @i2c_imx_dma_callback
l_.str.2:                               ; @.str.2
	.asciz	"DMA submit failed\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_i2c_imx_dma_xfer
.subsections_via_symbols
