	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cyapa_pip_do_calibrate         ## -- Begin function cyapa_pip_do_calibrate
	.p2align	4, 0x90
_cyapa_pip_do_calibrate:                ## @cyapa_pip_do_calibrate
	.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
	movq	%rcx, %r14
	callq	_dev_get_drvdata
	movq	%rax, %r15
	movq	%rax, %rdi
	callq	_cyapa_pip_suspend_scanning
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_6
## %bb.1:
	movq	_PIP_SENSING_MODE_MUTUAL_CAP_FINE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_cyapa_pip_calibrate_pwcs
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_3
## %bb.2:
	movq	_PIP_SENSING_MODE_SELF_CAP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_cyapa_pip_calibrate_pwcs
	movl	%eax, %ebx
LBB0_3:
	movq	%r15, %rdi
	callq	_cyapa_pip_resume_scanning
	movl	%eax, %ecx
	orl	%ebx, %ecx
	je	LBB0_5
## %bb.4:
	testl	%eax, %eax
	cmovnel	%eax, %ebx
	jmp	LBB0_6
LBB0_5:
	movl	%r14d, %ebx
LBB0_6:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PIP_SENSING_MODE_MUTUAL_CAP_FINE,4,2 ## @PIP_SENSING_MODE_MUTUAL_CAP_FINE
	.comm	_PIP_SENSING_MODE_SELF_CAP,4,2  ## @PIP_SENSING_MODE_SELF_CAP
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cyapa_pip_do_calibrate         ; -- Begin function cyapa_pip_do_calibrate
	.p2align	2
_cyapa_pip_do_calibrate:                ; @cyapa_pip_do_calibrate
	.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
	mov	x19, x3
	bl	_dev_get_drvdata
	mov	x20, x0
	bl	_cyapa_pip_suspend_scanning
	cbnz	w0, LBB0_6
; %bb.1:
Lloh0:
	adrp	x8, _PIP_SENSING_MODE_MUTUAL_CAP_FINE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PIP_SENSING_MODE_MUTUAL_CAP_FINE@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_cyapa_pip_calibrate_pwcs
	mov	x21, x0
	cbnz	w0, LBB0_3
; %bb.2:
Lloh3:
	adrp	x8, _PIP_SENSING_MODE_SELF_CAP@GOTPAGE
Lloh4:
	ldr	x8, [x8, _PIP_SENSING_MODE_SELF_CAP@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_cyapa_pip_calibrate_pwcs
	mov	x21, x0
LBB0_3:
	mov	x0, x20
	bl	_cyapa_pip_resume_scanning
	orr	w8, w0, w21
	cbz	w8, LBB0_5
; %bb.4:
	cmp	w0, #0
	csel	w0, w0, w21, ne
	b	LBB0_6
LBB0_5:
	mov	x0, x19
LBB0_6:
	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 AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_PIP_SENSING_MODE_MUTUAL_CAP_FINE,4,2 ; @PIP_SENSING_MODE_MUTUAL_CAP_FINE
	.comm	_PIP_SENSING_MODE_SELF_CAP,4,2  ; @PIP_SENSING_MODE_SELF_CAP
.subsections_via_symbols
