	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function atlas_check_ph_calibration
_atlas_check_ph_calibration:            ## @atlas_check_ph_calibration
	.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
	subq	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	8(%rdi), %r14
	movl	(%rdi), %edi
	movq	_ATLAS_REG_PH_CALIB_STATUS@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-20(%rbp), %rdx
	callq	_regmap_read
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_10
## %bb.1:
	movl	-20(%rbp), %eax
	movq	_ATLAS_REG_PH_CALIB_STATUS_MASK@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_2
## %bb.3:
	movq	_ATLAS_REG_PH_CALIB_STATUS_LOW@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_5
## %bb.4:
	leaq	L_.str.1(%rip), %rsi
	movq	%r14, %rdi
	callq	_dev_warn
	movl	-20(%rbp), %eax
LBB0_5:
	movq	_ATLAS_REG_PH_CALIB_STATUS_MID@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_7
## %bb.6:
	leaq	L_.str.2(%rip), %rsi
	movq	%r14, %rdi
	callq	_dev_warn
	movl	-20(%rbp), %eax
LBB0_7:
	movq	_ATLAS_REG_PH_CALIB_STATUS_HIGH@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_10
## %bb.8:
	leaq	L_.str.3(%rip), %rsi
	jmp	LBB0_9
LBB0_2:
	leaq	L_.str(%rip), %rsi
LBB0_9:
	movq	%r14, %rdi
	callq	_dev_warn
LBB0_10:
	movl	%ebx, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ATLAS_REG_PH_CALIB_STATUS,4,2  ## @ATLAS_REG_PH_CALIB_STATUS
	.comm	_ATLAS_REG_PH_CALIB_STATUS_MASK,4,2 ## @ATLAS_REG_PH_CALIB_STATUS_MASK
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"device has not been calibrated\n"

	.comm	_ATLAS_REG_PH_CALIB_STATUS_LOW,4,2 ## @ATLAS_REG_PH_CALIB_STATUS_LOW
L_.str.1:                               ## @.str.1
	.asciz	"device missing low point calibration\n"

	.comm	_ATLAS_REG_PH_CALIB_STATUS_MID,4,2 ## @ATLAS_REG_PH_CALIB_STATUS_MID
L_.str.2:                               ## @.str.2
	.asciz	"device missing mid point calibration\n"

	.comm	_ATLAS_REG_PH_CALIB_STATUS_HIGH,4,2 ## @ATLAS_REG_PH_CALIB_STATUS_HIGH
L_.str.3:                               ## @.str.3
	.asciz	"device missing high point calibration\n"

	.no_dead_strip	_atlas_check_ph_calibration
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function atlas_check_ph_calibration
_atlas_check_ph_calibration:            ; @atlas_check_ph_calibration
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	ldr	x19, [x0, #8]
	ldr	w0, [x0]
Lloh0:
	adrp	x8, _ATLAS_REG_PH_CALIB_STATUS@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ATLAS_REG_PH_CALIB_STATUS@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	add	x2, sp, #12
	bl	_regmap_read
	mov	x20, x0
	cbnz	w0, LBB0_10
; %bb.1:
	ldr	w8, [sp, #12]
Lloh3:
	adrp	x9, _ATLAS_REG_PH_CALIB_STATUS_MASK@GOTPAGE
Lloh4:
	ldr	x9, [x9, _ATLAS_REG_PH_CALIB_STATUS_MASK@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_8
; %bb.2:
Lloh6:
	adrp	x9, _ATLAS_REG_PH_CALIB_STATUS_LOW@GOTPAGE
Lloh7:
	ldr	x9, [x9, _ATLAS_REG_PH_CALIB_STATUS_LOW@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_4
; %bb.3:
Lloh9:
	adrp	x1, l_.str.1@PAGE
Lloh10:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_dev_warn
	ldr	w8, [sp, #12]
LBB0_4:
Lloh11:
	adrp	x9, _ATLAS_REG_PH_CALIB_STATUS_MID@GOTPAGE
Lloh12:
	ldr	x9, [x9, _ATLAS_REG_PH_CALIB_STATUS_MID@GOTPAGEOFF]
Lloh13:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_6
; %bb.5:
Lloh14:
	adrp	x1, l_.str.2@PAGE
Lloh15:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x19
	bl	_dev_warn
	ldr	w8, [sp, #12]
LBB0_6:
Lloh16:
	adrp	x9, _ATLAS_REG_PH_CALIB_STATUS_HIGH@GOTPAGE
Lloh17:
	ldr	x9, [x9, _ATLAS_REG_PH_CALIB_STATUS_HIGH@GOTPAGEOFF]
Lloh18:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_10
; %bb.7:
Lloh19:
	adrp	x1, l_.str.3@PAGE
Lloh20:
	add	x1, x1, l_.str.3@PAGEOFF
	b	LBB0_9
LBB0_8:
Lloh21:
	adrp	x1, l_.str@PAGE
Lloh22:
	add	x1, x1, l_.str@PAGEOFF
LBB0_9:
	mov	x0, x19
	bl	_dev_warn
LBB0_10:
	mov	x0, x20
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpAdd	Lloh21, Lloh22
	.cfi_endproc
                                        ; -- End function
	.comm	_ATLAS_REG_PH_CALIB_STATUS,4,2  ; @ATLAS_REG_PH_CALIB_STATUS
	.comm	_ATLAS_REG_PH_CALIB_STATUS_MASK,4,2 ; @ATLAS_REG_PH_CALIB_STATUS_MASK
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"device has not been calibrated\n"

	.comm	_ATLAS_REG_PH_CALIB_STATUS_LOW,4,2 ; @ATLAS_REG_PH_CALIB_STATUS_LOW
l_.str.1:                               ; @.str.1
	.asciz	"device missing low point calibration\n"

	.comm	_ATLAS_REG_PH_CALIB_STATUS_MID,4,2 ; @ATLAS_REG_PH_CALIB_STATUS_MID
l_.str.2:                               ; @.str.2
	.asciz	"device missing mid point calibration\n"

	.comm	_ATLAS_REG_PH_CALIB_STATUS_HIGH,4,2 ; @ATLAS_REG_PH_CALIB_STATUS_HIGH
l_.str.3:                               ; @.str.3
	.asciz	"device missing high point calibration\n"

	.no_dead_strip	_atlas_check_ph_calibration
.subsections_via_symbols
