	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function nt39016_prepare
_nt39016_prepare:                       ## @nt39016_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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	callq	_to_nt39016
	movq	%rax, %r14
	movl	(%rax), %edi
	callq	_regulator_enable
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	movl	%eax, %ebx
	movl	4(%r14), %edi
	leaq	L_.str(%rip), %rsi
	movl	%eax, %edx
	callq	_dev_err
	jmp	LBB0_4
LBB0_2:
	movl	12(%r14), %edi
	movl	$1, %esi
	callq	_gpiod_set_value_cansleep
	movl	$100, %edi
	movl	$1000, %esi                     ## imm = 0x3E8
	callq	_usleep_range
	movl	12(%r14), %edi
	xorl	%ebx, %ebx
	xorl	%esi, %esi
	callq	_gpiod_set_value_cansleep
	movl	$2, %edi
	callq	_udelay
	movl	8(%r14), %r15d
	movq	_nt39016_panel_regs@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	movl	%r12d, %edi
	callq	_ARRAY_SIZE
	movl	%r15d, %edi
	movl	%r12d, %esi
	movl	%eax, %edx
	callq	_regmap_multi_reg_write
	testl	%eax, %eax
	je	LBB0_4
## %bb.3:
	movl	%eax, %r15d
	movl	4(%r14), %edi
	leaq	L_.str.1(%rip), %rsi
	movl	%eax, %edx
	callq	_dev_err
	movl	(%r14), %edi
	callq	_regulator_disable
	movl	%r15d, %ebx
LBB0_4:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Failed to enable power supply: %d"

	.comm	_nt39016_panel_regs,4,2         ## @nt39016_panel_regs
L_.str.1:                               ## @.str.1
	.asciz	"Failed to init registers: %d"

	.no_dead_strip	_nt39016_prepare
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function nt39016_prepare
_nt39016_prepare:                       ; @nt39016_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	_to_nt39016
	mov	x19, x0
	ldr	w0, [x0]
	bl	_regulator_enable
	cbz	w0, LBB0_2
; %bb.1:
	mov	x20, x0
	ldr	w0, [x19, #4]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x20
	bl	_dev_err
	b	LBB0_4
LBB0_2:
	ldr	w0, [x19, #12]
	mov	w1, #1
	bl	_gpiod_set_value_cansleep
	mov	w0, #100
	mov	w1, #1000
	bl	_usleep_range
	ldr	w0, [x19, #12]
	mov	w1, #0
	bl	_gpiod_set_value_cansleep
	mov	w0, #2
	bl	_udelay
	ldr	w20, [x19, #8]
Lloh2:
	adrp	x8, _nt39016_panel_regs@GOTPAGE
Lloh3:
	ldr	x8, [x8, _nt39016_panel_regs@GOTPAGEOFF]
Lloh4:
	ldr	w21, [x8]
	mov	x0, x21
	bl	_ARRAY_SIZE
	mov	x2, x0
	mov	x0, x20
	mov	x1, x21
	bl	_regmap_multi_reg_write
	mov	x20, x0
	cbz	w0, LBB0_4
; %bb.3:
	ldr	w0, [x19, #4]
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x2, x20
	bl	_dev_err
	ldr	w0, [x19]
	bl	_regulator_disable
LBB0_4:
	mov	x0, x20
	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
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Failed to enable power supply: %d"

	.comm	_nt39016_panel_regs,4,2         ; @nt39016_panel_regs
l_.str.1:                               ; @.str.1
	.asciz	"Failed to init registers: %d"

	.no_dead_strip	_nt39016_prepare
.subsections_via_symbols
