	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sun6i_dsi_transfer
_sun6i_dsi_transfer:                    ## @sun6i_dsi_transfer
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rsi, %r14
	callq	_host_to_sun6i_dsi
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_sun6i_dsi_inst_wait_for_completion
	testl	%eax, %eax
	jns	LBB0_2
## %bb.1:
	movq	%rbx, %rdi
	callq	_sun6i_dsi_inst_abort
LBB0_2:
	movl	(%rbx), %edi
	movq	_SUN6I_DSI_CMD_CTL_REG@GOTPCREL(%rip), %rax
	movq	_SUN6I_DSI_CMD_CTL_RX_OVERFLOW@GOTPCREL(%rip), %rcx
	movq	_SUN6I_DSI_CMD_CTL_RX_FLAG@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	orl	(%rcx), %edx
	movl	(%rax), %esi
	movq	_SUN6I_DSI_CMD_CTL_TX_FLAG@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
	callq	_regmap_write
	movl	(%r14), %eax
	leal	-128(%rax), %ecx
	cmpl	$3, %ecx
	jae	LBB0_3
## %bb.8:
	movq	%rbx, %rdi
	movq	%r14, %rsi
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_sun6i_dsi_dcs_write_short      ## TAILCALL
LBB0_3:
	cmpl	$131, %eax
	je	LBB0_6
## %bb.4:
	cmpl	$132, %eax
	jne	LBB0_7
## %bb.5:
	movq	%rbx, %rdi
	movq	%r14, %rsi
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_sun6i_dsi_dcs_write_long       ## TAILCALL
LBB0_6:
	cmpl	$1, 4(%r14)
	jne	LBB0_7
## %bb.9:
	movq	%rbx, %rdi
	movq	%r14, %rsi
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_sun6i_dsi_dcs_read             ## TAILCALL
LBB0_7:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SUN6I_DSI_CMD_CTL_REG,4,2      ## @SUN6I_DSI_CMD_CTL_REG
	.comm	_SUN6I_DSI_CMD_CTL_RX_OVERFLOW,4,2 ## @SUN6I_DSI_CMD_CTL_RX_OVERFLOW
	.comm	_SUN6I_DSI_CMD_CTL_RX_FLAG,4,2  ## @SUN6I_DSI_CMD_CTL_RX_FLAG
	.comm	_SUN6I_DSI_CMD_CTL_TX_FLAG,4,2  ## @SUN6I_DSI_CMD_CTL_TX_FLAG
	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_sun6i_dsi_transfer
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sun6i_dsi_transfer
_sun6i_dsi_transfer:                    ; @sun6i_dsi_transfer
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x1
	bl	_host_to_sun6i_dsi
	mov	x20, x0
	bl	_sun6i_dsi_inst_wait_for_completion
	tbz	w0, #31, LBB0_2
; %bb.1:
	mov	x0, x20
	bl	_sun6i_dsi_inst_abort
LBB0_2:
	ldr	w0, [x20]
Lloh0:
	adrp	x8, _SUN6I_DSI_CMD_CTL_REG@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SUN6I_DSI_CMD_CTL_REG@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x8, _SUN6I_DSI_CMD_CTL_RX_OVERFLOW@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SUN6I_DSI_CMD_CTL_RX_OVERFLOW@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
Lloh6:
	adrp	x9, _SUN6I_DSI_CMD_CTL_RX_FLAG@GOTPAGE
Lloh7:
	ldr	x9, [x9, _SUN6I_DSI_CMD_CTL_RX_FLAG@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	orr	w8, w9, w8
Lloh9:
	adrp	x9, _SUN6I_DSI_CMD_CTL_TX_FLAG@GOTPAGE
Lloh10:
	ldr	x9, [x9, _SUN6I_DSI_CMD_CTL_TX_FLAG@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	orr	w2, w8, w9
	bl	_regmap_write
	ldr	w8, [x19]
	sub	w9, w8, #128
	cmp	w9, #3
	b.hs	LBB0_4
; %bb.3:
	mov	x0, x20
	mov	x1, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_sun6i_dsi_dcs_write_short
LBB0_4:
	cmp	w8, #131
	b.eq	LBB0_7
; %bb.5:
	cmp	w8, #132
	b.ne	LBB0_9
; %bb.6:
	mov	x0, x20
	mov	x1, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_sun6i_dsi_dcs_write_long
LBB0_7:
	ldr	w8, [x19, #4]
	cmp	w8, #1
	b.ne	LBB0_9
; %bb.8:
	mov	x0, x20
	mov	x1, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_sun6i_dsi_dcs_read
LBB0_9:
Lloh12:
	adrp	x8, _EINVAL@GOTPAGE
Lloh13:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	neg	w0, w8
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_SUN6I_DSI_CMD_CTL_REG,4,2      ; @SUN6I_DSI_CMD_CTL_REG
	.comm	_SUN6I_DSI_CMD_CTL_RX_OVERFLOW,4,2 ; @SUN6I_DSI_CMD_CTL_RX_OVERFLOW
	.comm	_SUN6I_DSI_CMD_CTL_RX_FLAG,4,2  ; @SUN6I_DSI_CMD_CTL_RX_FLAG
	.comm	_SUN6I_DSI_CMD_CTL_TX_FLAG,4,2  ; @SUN6I_DSI_CMD_CTL_TX_FLAG
	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_sun6i_dsi_transfer
.subsections_via_symbols
