	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cqspi_direct_read_execute
_cqspi_direct_read_execute:             ## @cqspi_direct_read_execute
	.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
	subq	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %rbx
	movq	%rdx, %r14
	movq	%rsi, %r12
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	movq	8(%rdi), %rax
	movq	(%rax), %rdx
	cmpl	$0, (%rdx)
	je	LBB0_2
## %bb.1:
	movq	_DMA_CTRL_ACK@GOTPCREL(%rip), %rax
	movq	_DMA_PREP_INTERRUPT@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r13d
	orl	(%rax), %r13d
	movq	16(%rdx), %r15
	addq	%r14, %r15
	movq	%r12, %rdi
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	movq	%rdx, -64(%rbp)                 ## 8-byte Spill
	callq	_virt_addr_valid
	movq	-64(%rbp), %rdx                 ## 8-byte Reload
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	testl	%eax, %eax
	je	LBB0_2
## %bb.3:
	movq	-56(%rbp), %r14                 ## 8-byte Reload
	movl	(%r14), %edi
	movq	_DMA_FROM_DEVICE@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r12, %rsi
	movq	%rbx, %rdx
	movq	%rbx, %r12
	callq	_dma_map_single
	movq	%rax, %rbx
	movl	(%r14), %edi
	movq	%rax, %rsi
	callq	_dma_mapping_error
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	movl	(%r14), %edi
	leaq	L_.str(%rip), %rsi
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_dev_err
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
	jmp	LBB0_13
LBB0_2:
	addq	8(%rdx), %r14
	movq	%r12, %rdi
	movq	%r14, %rsi
	movq	%rbx, %rdx
	callq	_memcpy_fromio
	xorl	%ebx, %ebx
LBB0_13:
	movl	%ebx, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	movq	%rbx, %rsi
	movq	-64(%rbp), %rbx                 ## 8-byte Reload
	movl	(%rbx), %edi
	movq	%rsi, -72(%rbp)                 ## 8-byte Spill
	movq	%r15, %rdx
	movq	%r12, %rcx
	movl	%r13d, %r8d
	callq	_dmaengine_prep_dma_memcpy
	testq	%rax, %rax
	je	LBB0_6
## %bb.8:
	movq	_cqspi_rx_dma_callback@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 16(%rax)
	movq	%rbx, 8(%rax)
	movq	%rax, %rdi
	callq	*(%rax)
	movl	%eax, %r14d
	movq	%rbx, %r15
	addq	$4, %rbx
	movq	%rbx, %rdi
	callq	_reinit_completion
	movl	%r14d, %edi
	callq	_dma_submit_error
	testl	%eax, %eax
	je	LBB0_10
## %bb.9:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	leaq	L_.str.2(%rip), %rsi
	xorl	%ebx, %ebx
	movl	%r14d, %edx
	movq	%rax, %r14
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_7
LBB0_6:
	movl	(%r14), %edi
	leaq	L_.str.1(%rip), %rsi
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_dev_err
LBB0_7:
	movq	_EIO@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
	movq	_DMA_FROM_DEVICE@GOTPCREL(%rip), %r12
LBB0_12:
	movl	(%r14), %edi
	movl	(%r12), %ecx
	movq	-72(%rbp), %rsi                 ## 8-byte Reload
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	callq	_dma_unmap_single
	jmp	LBB0_13
LBB0_10:
	movl	(%r15), %edi
	callq	_dma_async_issue_pending
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_msecs_to_jiffies
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_wait_for_completion_timeout
	xorl	%ebx, %ebx
	testl	%eax, %eax
	movq	-56(%rbp), %r14                 ## 8-byte Reload
	movq	_DMA_FROM_DEVICE@GOTPCREL(%rip), %r12
	jne	LBB0_12
## %bb.11:
	movl	(%r15), %edi
	callq	_dmaengine_terminate_sync
	movl	(%r14), %edi
	leaq	L_.str.3(%rip), %rsi
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_dev_err
	movq	_ETIMEDOUT@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
	jmp	LBB0_12
	.cfi_endproc
                                        ## -- End function
	.comm	_DMA_CTRL_ACK,4,2               ## @DMA_CTRL_ACK
	.comm	_DMA_PREP_INTERRUPT,4,2         ## @DMA_PREP_INTERRUPT
	.comm	_DMA_FROM_DEVICE,4,2            ## @DMA_FROM_DEVICE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"dma mapping failed\n"

	.comm	_ENOMEM,4,2                     ## @ENOMEM
L_.str.1:                               ## @.str.1
	.asciz	"device_prep_dma_memcpy error\n"

	.comm	_EIO,4,2                        ## @EIO
	.comm	_cqspi_rx_dma_callback,4,2      ## @cqspi_rx_dma_callback
L_.str.2:                               ## @.str.2
	.asciz	"dma_submit_error %d\n"

L_.str.3:                               ## @.str.3
	.asciz	"DMA wait_for_completion_timeout\n"

	.comm	_ETIMEDOUT,4,2                  ## @ETIMEDOUT
	.no_dead_strip	_cqspi_direct_read_execute
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cqspi_direct_read_execute
_cqspi_direct_read_execute:             ; @cqspi_direct_read_execute
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x3
	mov	x22, x2
	mov	x21, x1
	ldr	x8, [x0, #8]
	ldr	x25, [x8]
	ldr	w8, [x25]
	cbz	w8, LBB0_4
; %bb.1:
	mov	x20, x0
Lloh0:
	adrp	x8, _DMA_CTRL_ACK@GOTPAGE
Lloh1:
	ldr	x8, [x8, _DMA_CTRL_ACK@GOTPAGEOFF]
Lloh2:
	ldr	w23, [x8]
Lloh3:
	adrp	x8, _DMA_PREP_INTERRUPT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _DMA_PREP_INTERRUPT@GOTPAGEOFF]
Lloh5:
	ldr	w27, [x8]
	ldr	x26, [x25, #16]
	mov	x0, x21
	bl	_virt_addr_valid
	cbz	w0, LBB0_4
; %bb.2:
	ldr	w0, [x20]
Lloh6:
	adrp	x24, _DMA_FROM_DEVICE@GOTPAGE
Lloh7:
	ldr	x24, [x24, _DMA_FROM_DEVICE@GOTPAGEOFF]
	ldr	w3, [x24]
	mov	x1, x21
	mov	x2, x19
	bl	_dma_map_single
	mov	x21, x0
	ldr	w0, [x20]
	mov	x1, x21
	bl	_dma_mapping_error
	cbz	x0, LBB0_6
; %bb.3:
	ldr	w0, [x20]
Lloh8:
	adrp	x1, l_.str@PAGE
Lloh9:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err
Lloh10:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh11:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_5
LBB0_4:
	ldr	x8, [x25, #8]
	add	x1, x8, x22
	mov	x0, x21
	mov	x2, x19
	bl	_memcpy_fromio
	mov	w22, #0
LBB0_5:
	mov	x0, x22
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_6:
	orr	w4, w27, w23
	add	x2, x26, x22
	ldr	w0, [x25]
	mov	x1, x21
	mov	x3, x19
	bl	_dmaengine_prep_dma_memcpy
	cbz	x0, LBB0_9
; %bb.7:
Lloh13:
	adrp	x8, _cqspi_rx_dma_callback@GOTPAGE
Lloh14:
	ldr	x8, [x8, _cqspi_rx_dma_callback@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	str	w8, [x0, #16]
	str	x25, [x0, #8]
	ldr	x8, [x0]
	blr	x8
	mov	x23, x0
	add	x22, x25, #4
	mov	x0, x22
	bl	_reinit_completion
	mov	x0, x23
	bl	_dma_submit_error
	cbz	w0, LBB0_13
; %bb.8:
	ldr	w0, [x20]
	str	x23, [sp]
Lloh16:
	adrp	x1, l_.str.2@PAGE
Lloh17:
	add	x1, x1, l_.str.2@PAGEOFF
	b	LBB0_10
LBB0_9:
	ldr	w0, [x20]
Lloh18:
	adrp	x1, l_.str.1@PAGE
Lloh19:
	add	x1, x1, l_.str.1@PAGEOFF
LBB0_10:
	bl	_dev_err
Lloh20:
	adrp	x8, _EIO@GOTPAGE
Lloh21:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
LBB0_11:
	ldr	w8, [x8]
	neg	w22, w8
LBB0_12:
	ldr	w0, [x20]
	ldr	w3, [x24]
	mov	x1, x21
	mov	x2, x19
	bl	_dma_unmap_single
	b	LBB0_5
LBB0_13:
	ldr	w0, [x25]
	bl	_dma_async_issue_pending
	mov	x0, x19
	bl	_msecs_to_jiffies
	mov	x1, x0
	mov	x0, x22
	bl	_wait_for_completion_timeout
	cbz	w0, LBB0_15
; %bb.14:
	mov	w22, #0
	b	LBB0_12
LBB0_15:
	ldr	w0, [x25]
	bl	_dmaengine_terminate_sync
	ldr	w0, [x20]
Lloh22:
	adrp	x1, l_.str.3@PAGE
Lloh23:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_dev_err
Lloh24:
	adrp	x8, _ETIMEDOUT@GOTPAGE
Lloh25:
	ldr	x8, [x8, _ETIMEDOUT@GOTPAGEOFF]
	b	LBB0_11
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpAdd	Lloh22, Lloh23
	.cfi_endproc
                                        ; -- End function
	.comm	_DMA_CTRL_ACK,4,2               ; @DMA_CTRL_ACK
	.comm	_DMA_PREP_INTERRUPT,4,2         ; @DMA_PREP_INTERRUPT
	.comm	_DMA_FROM_DEVICE,4,2            ; @DMA_FROM_DEVICE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"dma mapping failed\n"

	.comm	_ENOMEM,4,2                     ; @ENOMEM
l_.str.1:                               ; @.str.1
	.asciz	"device_prep_dma_memcpy error\n"

	.comm	_EIO,4,2                        ; @EIO
	.comm	_cqspi_rx_dma_callback,4,2      ; @cqspi_rx_dma_callback
l_.str.2:                               ; @.str.2
	.asciz	"dma_submit_error %d\n"

l_.str.3:                               ; @.str.3
	.asciz	"DMA wait_for_completion_timeout\n"

	.comm	_ETIMEDOUT,4,2                  ; @ETIMEDOUT
	.no_dead_strip	_cqspi_direct_read_execute
.subsections_via_symbols
