	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function max44000_read_alsval
_max44000_read_alsval:                  ## @max44000_read_alsval
	.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	%rdi, %rbx
	movl	(%rdi), %edi
	movq	_MAX44000_REG_ALS_DATA_HI@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-20(%rbp), %rdx
	movl	$4, %ecx
	callq	_regmap_bulk_read
	testl	%eax, %eax
	js	LBB0_5
## %bb.1:
	movq	%rbx, %rdi
	callq	_max44000_read_alstim
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_2
## %bb.3:
	movl	-20(%rbp), %edi
	callq	_be16_to_cpu
	movl	%eax, %r14d
	movq	_MAX44000_ALSDATA_OVERFLOW@GOTPCREL(%rip), %rcx
	movl	$16383, %eax                    ## imm = 0x3FFF
	testl	%r14d, (%rcx)
	jne	LBB0_5
## %bb.4:
	movl	%ebx, %edi
	callq	_MAX44000_ALSTIM_SHIFT
	movl	%eax, %ecx
	shll	%cl, %r14d
	movl	%r14d, %eax
	jmp	LBB0_5
LBB0_2:
	movl	%ebx, %eax
LBB0_5:
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MAX44000_REG_ALS_DATA_HI,4,2   ## @MAX44000_REG_ALS_DATA_HI
	.comm	_MAX44000_ALSDATA_OVERFLOW,4,2  ## @MAX44000_ALSDATA_OVERFLOW
	.no_dead_strip	_max44000_read_alsval
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function max44000_read_alsval
_max44000_read_alsval:                  ; @max44000_read_alsval
	.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
	mov	x20, x0
	ldr	w0, [x0]
Lloh0:
	adrp	x8, _MAX44000_REG_ALS_DATA_HI@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MAX44000_REG_ALS_DATA_HI@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	add	x2, sp, #12
	mov	w3, #4
	bl	_regmap_bulk_read
	tbnz	w0, #31, LBB0_4
; %bb.1:
	mov	x0, x20
	bl	_max44000_read_alstim
	mov	x19, x0
	tbnz	w0, #31, LBB0_6
; %bb.2:
	ldr	w0, [sp, #12]
	bl	_be16_to_cpu
Lloh3:
	adrp	x8, _MAX44000_ALSDATA_OVERFLOW@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MAX44000_ALSDATA_OVERFLOW@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	tst	w8, w0
	b.eq	LBB0_5
; %bb.3:
	mov	w19, #16383
	b	LBB0_6
LBB0_4:
	mov	x19, x0
	b	LBB0_6
LBB0_5:
	mov	x20, x0
	mov	x0, x19
	bl	_MAX44000_ALSTIM_SHIFT
	lsl	w19, w20, w0
LBB0_6:
	mov	x0, x19
	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
	.cfi_endproc
                                        ; -- End function
	.comm	_MAX44000_REG_ALS_DATA_HI,4,2   ; @MAX44000_REG_ALS_DATA_HI
	.comm	_MAX44000_ALSDATA_OVERFLOW,4,2  ; @MAX44000_ALSDATA_OVERFLOW
	.no_dead_strip	_max44000_read_alsval
.subsections_via_symbols
