	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cyapa_initialize
_cyapa_initialize:                      ## @cyapa_initialize
	.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	%rdi, %rbx
	movq	_CYAPA_STATE_NO_DEVICE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 32(%rdi)
	movq	_CYAPA_GEN_UNKNOWN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 28(%rdi)
	addq	$24, %rdi
	callq	_mutex_init
	movq	_PWR_MODE_SLEEP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	%edi, 16(%rbx)
	callq	_cyapa_pwr_cmd_to_sleep_time
	movl	%eax, 20(%rbx)
	movq	_cyapa_gen3_ops@GOTPCREL(%rip), %rax
	movq	%rbx, %rdi
	callq	*(%rax)
	movl	%eax, %r14d
	testl	%eax, %eax
	jne	LBB0_7
## %bb.1:
	movq	_cyapa_gen5_ops@GOTPCREL(%rip), %rax
	movq	%rbx, %rdi
	callq	*(%rax)
	movl	%eax, %r14d
	testl	%eax, %eax
	jne	LBB0_7
## %bb.2:
	movq	_cyapa_gen6_ops@GOTPCREL(%rip), %rax
	movq	%rbx, %rdi
	callq	*(%rax)
	movl	%eax, %r14d
	testl	%eax, %eax
	jne	LBB0_7
## %bb.3:
	movq	%rbx, %rdi
	callq	_cyapa_detect
	movl	%eax, %r14d
	testl	%eax, %eax
	jne	LBB0_7
## %bb.4:
	cmpq	$0, 8(%rbx)
	je	LBB0_5
## %bb.6:
	movq	(%rbx), %rax
	movq	_PWR_MODE_OFF@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movq	_CYAPA_PM_ACTIVE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	xorl	%r14d, %r14d
	movq	%rbx, %rdi
	xorl	%edx, %edx
	callq	*(%rax)
	jmp	LBB0_7
LBB0_5:
	xorl	%r14d, %r14d
LBB0_7:
	movl	%r14d, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_CYAPA_STATE_NO_DEVICE,4,2      ## @CYAPA_STATE_NO_DEVICE
	.comm	_CYAPA_GEN_UNKNOWN,4,2          ## @CYAPA_GEN_UNKNOWN
	.comm	_PWR_MODE_SLEEP,4,2             ## @PWR_MODE_SLEEP
	.comm	_cyapa_gen3_ops,8,3             ## @cyapa_gen3_ops
	.comm	_cyapa_gen5_ops,8,3             ## @cyapa_gen5_ops
	.comm	_cyapa_gen6_ops,8,3             ## @cyapa_gen6_ops
	.comm	_PWR_MODE_OFF,4,2               ## @PWR_MODE_OFF
	.comm	_CYAPA_PM_ACTIVE,4,2            ## @CYAPA_PM_ACTIVE
	.no_dead_strip	_cyapa_initialize
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cyapa_initialize
_cyapa_initialize:                      ; @cyapa_initialize
	.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, x0
Lloh0:
	adrp	x8, _CYAPA_STATE_NO_DEVICE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _CYAPA_STATE_NO_DEVICE@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, _CYAPA_GEN_UNKNOWN@GOTPAGE
Lloh4:
	ldr	x9, [x9, _CYAPA_GEN_UNKNOWN@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	stp	w9, w8, [x0, #28]
	add	x0, x0, #24
	bl	_mutex_init
Lloh6:
	adrp	x8, _PWR_MODE_SLEEP@GOTPAGE
Lloh7:
	ldr	x8, [x8, _PWR_MODE_SLEEP@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
	str	w0, [x19, #16]
	bl	_cyapa_pwr_cmd_to_sleep_time
	str	w0, [x19, #20]
Lloh9:
	adrp	x8, _cyapa_gen3_ops@GOTPAGE
Lloh10:
	ldr	x8, [x8, _cyapa_gen3_ops@GOTPAGEOFF]
Lloh11:
	ldr	x8, [x8]
	mov	x0, x19
	blr	x8
	cbnz	w0, LBB0_7
; %bb.1:
Lloh12:
	adrp	x8, _cyapa_gen5_ops@GOTPAGE
Lloh13:
	ldr	x8, [x8, _cyapa_gen5_ops@GOTPAGEOFF]
Lloh14:
	ldr	x8, [x8]
	mov	x0, x19
	blr	x8
	cbnz	w0, LBB0_7
; %bb.2:
Lloh15:
	adrp	x8, _cyapa_gen6_ops@GOTPAGE
Lloh16:
	ldr	x8, [x8, _cyapa_gen6_ops@GOTPAGEOFF]
Lloh17:
	ldr	x8, [x8]
	mov	x0, x19
	blr	x8
	cbnz	w0, LBB0_7
; %bb.3:
	mov	x0, x19
	bl	_cyapa_detect
	cbnz	w0, LBB0_7
; %bb.4:
	ldr	x8, [x19, #8]
	cbz	x8, LBB0_6
; %bb.5:
	ldr	x8, [x19]
	ldr	x8, [x8]
Lloh18:
	adrp	x9, _PWR_MODE_OFF@GOTPAGE
Lloh19:
	ldr	x9, [x9, _PWR_MODE_OFF@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x9]
Lloh21:
	adrp	x9, _CYAPA_PM_ACTIVE@GOTPAGE
Lloh22:
	ldr	x9, [x9, _CYAPA_PM_ACTIVE@GOTPAGEOFF]
Lloh23:
	ldr	w3, [x9]
	mov	x0, x19
	mov	w2, #0
	blr	x8
LBB0_6:
	mov	w0, #0
LBB0_7:
	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
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_CYAPA_STATE_NO_DEVICE,4,2      ; @CYAPA_STATE_NO_DEVICE
	.comm	_CYAPA_GEN_UNKNOWN,4,2          ; @CYAPA_GEN_UNKNOWN
	.comm	_PWR_MODE_SLEEP,4,2             ; @PWR_MODE_SLEEP
	.comm	_cyapa_gen3_ops,8,3             ; @cyapa_gen3_ops
	.comm	_cyapa_gen5_ops,8,3             ; @cyapa_gen5_ops
	.comm	_cyapa_gen6_ops,8,3             ; @cyapa_gen6_ops
	.comm	_PWR_MODE_OFF,4,2               ; @PWR_MODE_OFF
	.comm	_CYAPA_PM_ACTIVE,4,2            ; @CYAPA_PM_ACTIVE
	.no_dead_strip	_cyapa_initialize
.subsections_via_symbols
