	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function rm68200_prepare
_rm68200_prepare:                       ## @rm68200_prepare
	.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
	callq	_panel_to_rm68200
	movq	%rax, %r15
	movl	20(%rax), %edi
	callq	_to_mipi_dsi_device
	xorl	%ebx, %ebx
	cmpl	$0, (%r15)
	je	LBB0_1
LBB0_8:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movq	%rax, %r14
	movl	16(%r15), %edi
	callq	_regulator_enable
	testl	%eax, %eax
	js	LBB0_2
## %bb.3:
	movq	8(%r15), %rdi
	testq	%rdi, %rdi
	je	LBB0_5
## %bb.4:
	movl	$1, %esi
	callq	_gpiod_set_value_cansleep
	movl	$20, %edi
	callq	_msleep
	movq	8(%r15), %rdi
	xorl	%esi, %esi
	callq	_gpiod_set_value_cansleep
	movl	$100, %edi
	callq	_msleep
LBB0_5:
	movq	%r15, %rdi
	callq	_rm68200_init_sequence
	movq	%r14, %rdi
	callq	_mipi_dsi_dcs_exit_sleep_mode
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_8
## %bb.6:
	movl	$125, %edi
	callq	_msleep
	movq	%r14, %rdi
	callq	_mipi_dsi_dcs_set_display_on
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_8
## %bb.7:
	movl	$20, %edi
	callq	_msleep
	movl	$1, (%r15)
	xorl	%ebx, %ebx
	jmp	LBB0_8
LBB0_2:
	movl	%eax, %ebx
	leaq	L_.str(%rip), %rdi
	movl	%eax, %esi
	callq	_DRM_ERROR
	jmp	LBB0_8
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"failed to enable supply: %d\n"

	.no_dead_strip	_rm68200_prepare
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function rm68200_prepare
_rm68200_prepare:                       ; @rm68200_prepare
	.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
	bl	_panel_to_rm68200
	mov	x19, x0
	ldr	w0, [x0, #20]
	bl	_to_mipi_dsi_device
	ldr	w8, [x19]
	cbz	w8, LBB0_3
; %bb.1:
	mov	w21, #0
LBB0_2:
	mov	x0, x21
	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_3:
	mov	x20, x0
	ldr	w0, [x19, #16]
	bl	_regulator_enable
	tbnz	w0, #31, LBB0_9
; %bb.4:
	ldr	x0, [x19, #8]
	cbz	x0, LBB0_6
; %bb.5:
	mov	w1, #1
	bl	_gpiod_set_value_cansleep
	mov	w0, #20
	bl	_msleep
	ldr	x0, [x19, #8]
	mov	w1, #0
	bl	_gpiod_set_value_cansleep
	mov	w0, #100
	bl	_msleep
LBB0_6:
	mov	x0, x19
	bl	_rm68200_init_sequence
	mov	x0, x20
	bl	_mipi_dsi_dcs_exit_sleep_mode
	mov	x21, x0
	cbnz	w0, LBB0_2
; %bb.7:
	mov	w0, #125
	bl	_msleep
	mov	x0, x20
	bl	_mipi_dsi_dcs_set_display_on
	mov	x21, x0
	cbnz	w0, LBB0_2
; %bb.8:
	mov	w0, #20
	bl	_msleep
	mov	w8, #1
	str	w8, [x19]
	b	LBB0_2
LBB0_9:
	mov	x21, x0
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x21
	bl	_DRM_ERROR
	b	LBB0_2
	.loh AdrpAdd	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"failed to enable supply: %d\n"

	.no_dead_strip	_rm68200_prepare
.subsections_via_symbols
