	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ltc2945_reg_to_val
_ltc2945_reg_to_val:                    ## @ltc2945_reg_to_val
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %ebx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -32(%rbp)
	callq	_dev_get_drvdata
	movq	%rax, %r14
	movl	%ebx, %edi
	callq	_is_power_reg
	cmpq	$1, %rax
	movl	$3, %ecx
	sbbl	$0, %ecx
	leaq	-44(%rbp), %rdx
	movq	%r14, %rdi
	movl	%ebx, %esi
	callq	_regmap_bulk_read
	testl	%eax, %eax
	js	LBB0_3
## %bb.1:
	movl	%ebx, %edi
	callq	_is_power_reg
	movl	-44(%rbp), %ecx
	testq	%rax, %rax
	je	LBB0_4
## %bb.2:
	shll	$16, %ecx
	movl	-40(%rbp), %eax
	shll	$8, %eax
	addl	%ecx, %eax
	addl	-36(%rbp), %eax
	jmp	LBB0_5
LBB0_4:
	shll	$4, %ecx
	movl	-40(%rbp), %eax
	sarl	$4, %eax
	addl	%ecx, %eax
LBB0_5:
	addl	$-128, %ebx
	cmpl	$19, %ebx
	ja	LBB0_16
## %bb.6:
	movslq	%eax, %r15
	leaq	LJTI0_0(%rip), %rax
	movslq	(%rax,%rbx,4), %rcx
	addq	%rax, %rcx
	jmpq	*%rcx
LBB0_7:
	leaq	(%r15,%r15,4), %rax
	leaq	(%rax,%rax,4), %r15
	jmp	LBB0_14
LBB0_8:
	movq	_LTC2945_CONTROL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-48(%rbp), %rdx
	movq	%r14, %rdi
	callq	_regmap_read
	testl	%eax, %eax
	js	LBB0_3
## %bb.9:
	movq	_CONTROL_MULT_SELECT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, -48(%rbp)
	je	LBB0_12
## %bb.10:
	imulq	$625, %r15, %r15                ## imm = 0x271
	jmp	LBB0_14
LBB0_3:
	movslq	%eax, %r15
	jmp	LBB0_14
LBB0_12:
	leaq	(%r15,%r15,4), %rax
	leaq	(%rax,%rax,4), %r15
LBB0_13:
	sarq	%r15
LBB0_14:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-32(%rbp), %rax
	jne	LBB0_17
## %bb.15:
	movq	%r15, %rax
	addq	$24, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_16:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	subq	(%rax), %r15
	jmp	LBB0_14
LBB0_17:
	callq	___stack_chk_fail
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_7, LBB0_7-LJTI0_0
.set L0_0_set_8, LBB0_8-LJTI0_0
.set L0_0_set_13, LBB0_13-LJTI0_0
LJTI0_0:
	.long	L0_0_set_7
	.long	L0_0_set_7
	.long	L0_0_set_8
	.long	L0_0_set_7
	.long	L0_0_set_7
	.long	L0_0_set_7
	.long	L0_0_set_7
	.long	L0_0_set_8
	.long	L0_0_set_8
	.long	L0_0_set_13
	.long	L0_0_set_13
	.long	L0_0_set_7
	.long	L0_0_set_7
	.long	L0_0_set_7
	.long	L0_0_set_7
	.long	L0_0_set_8
	.long	L0_0_set_8
	.long	L0_0_set_13
	.long	L0_0_set_13
	.long	L0_0_set_13
	.end_data_region
                                        ## -- End function
	.comm	_LTC2945_CONTROL,4,2            ## @LTC2945_CONTROL
	.comm	_CONTROL_MULT_SELECT,4,2        ## @CONTROL_MULT_SELECT
	.comm	_EINVAL,8,3                     ## @EINVAL
	.no_dead_strip	_ltc2945_reg_to_val
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ltc2945_reg_to_val
_ltc2945_reg_to_val:                    ; @ltc2945_reg_to_val
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x20, x1
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #24]
	bl	_dev_get_drvdata
	mov	x19, x0
	mov	x0, x20
	bl	_is_power_reg
	cmp	x0, #0
	mov	w8, #2
	cinc	w3, w8, ne
	add	x2, sp, #12
	mov	x0, x19
	mov	x1, x20
	bl	_regmap_bulk_read
                                        ; kill: def $w0 killed $w0 def $x0
	tbnz	w0, #31, LBB0_10
; %bb.1:
	mov	x0, x20
	bl	_is_power_reg
	ldr	w8, [sp, #12]
	cbz	x0, LBB0_3
; %bb.2:
	ldp	w9, w10, [sp, #16]
	lsl	w9, w9, #8
	add	w8, w9, w8, lsl #16
	add	w8, w8, w10
	b	LBB0_4
LBB0_3:
	ldr	w9, [sp, #16]
	asr	w9, w9, #4
	add	w8, w9, w8, lsl #4
LBB0_4:
	sub	w9, w20, #128
	cmp	w9, #19
	b.hi	LBB0_15
; %bb.5:
	sxtw	x20, w8
Lloh3:
	adrp	x8, lJTI0_0@PAGE
Lloh4:
	add	x8, x8, lJTI0_0@PAGEOFF
	adr	x10, LBB0_6
	ldrb	w11, [x8, x9]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_6:
	mov	w8, #25
	mul	x0, x20, x8
	b	LBB0_12
LBB0_7:
Lloh5:
	adrp	x8, _LTC2945_CONTROL@GOTPAGE
Lloh6:
	ldr	x8, [x8, _LTC2945_CONTROL@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	add	x2, sp, #8
	mov	x0, x19
	bl	_regmap_read
                                        ; kill: def $w0 killed $w0 def $x0
	tbnz	w0, #31, LBB0_10
; %bb.8:
	ldr	w8, [sp, #8]
Lloh8:
	adrp	x9, _CONTROL_MULT_SELECT@GOTPAGE
Lloh9:
	ldr	x9, [x9, _CONTROL_MULT_SELECT@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_14
; %bb.9:
	mov	w8, #625
	mul	x0, x20, x8
	b	LBB0_12
LBB0_10:
	sxtw	x0, w0
	b	LBB0_12
LBB0_11:
	asr	x0, x20, #1
LBB0_12:
	ldr	x8, [sp, #24]
Lloh11:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh12:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh13:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_16
; %bb.13:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
LBB0_14:
	mov	w8, #25
	mul	x8, x20, x8
	asr	x0, x8, #1
	b	LBB0_12
LBB0_15:
Lloh14:
	adrp	x8, _EINVAL@GOTPAGE
Lloh15:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh16:
	ldr	x8, [x8]
	neg	x0, x8
	b	LBB0_12
LBB0_16:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_6-LBB0_6)>>2
	.byte	(LBB0_6-LBB0_6)>>2
	.byte	(LBB0_7-LBB0_6)>>2
	.byte	(LBB0_6-LBB0_6)>>2
	.byte	(LBB0_6-LBB0_6)>>2
	.byte	(LBB0_6-LBB0_6)>>2
	.byte	(LBB0_6-LBB0_6)>>2
	.byte	(LBB0_7-LBB0_6)>>2
	.byte	(LBB0_7-LBB0_6)>>2
	.byte	(LBB0_11-LBB0_6)>>2
	.byte	(LBB0_11-LBB0_6)>>2
	.byte	(LBB0_6-LBB0_6)>>2
	.byte	(LBB0_6-LBB0_6)>>2
	.byte	(LBB0_6-LBB0_6)>>2
	.byte	(LBB0_6-LBB0_6)>>2
	.byte	(LBB0_7-LBB0_6)>>2
	.byte	(LBB0_7-LBB0_6)>>2
	.byte	(LBB0_11-LBB0_6)>>2
	.byte	(LBB0_11-LBB0_6)>>2
	.byte	(LBB0_11-LBB0_6)>>2
                                        ; -- End function
	.comm	_LTC2945_CONTROL,4,2            ; @LTC2945_CONTROL
	.comm	_CONTROL_MULT_SELECT,4,2        ; @CONTROL_MULT_SELECT
	.comm	_EINVAL,8,3                     ; @EINVAL
	.no_dead_strip	_ltc2945_reg_to_val
.subsections_via_symbols
