	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function twl6030_calibrate_channel
_twl6030_calibrate_channel:             ## @twl6030_calibrate_channel
	.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	%r13
	pushq	%r12
	pushq	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%ecx, %r13d
	movl	%ecx, -44(%rbp)                 ## 4-byte Spill
	movl	%edx, -56(%rbp)                 ## 4-byte Spill
	movl	%esi, %r14d
	movq	%rdi, %r15
	movq	16(%rdi), %rax
	movq	8(%rax), %rbx
	movl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_twl6030_gpadc_lookup
	cltq
	leaq	(%rax,%rax,2), %rdi
	movq	%rax, %rdx
	shlq	$4, %rdx
	movl	(%rbx,%rdx), %eax
	movl	8(%rbx,%rdx), %esi
	movl	%esi, -52(%rbp)                 ## 4-byte Spill
	subl	4(%rbx,%rdx), %eax
	imull	$1000, %eax, %eax               ## imm = 0x3E8
	movl	12(%rbx,%rdx), %r12d
	subl	%r12d, %esi
	cltd
	idivl	%esi
	movl	%eax, %ebx
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movl	-56(%rbp), %ecx                 ## 4-byte Reload
	subl	%ecx, %r13d
	imull	$1000, %r13d, %eax              ## imm = 0x3E8
	cltd
	idivl	%esi
                                        ## kill: def $eax killed $eax def $rax
	leal	1000(%rax), %edx
	imull	$1000, %ecx, %r13d              ## imm = 0x3E8
	imull	%r12d, %eax
	subl	%eax, %r13d
	movq	8(%r15), %rax
	movl	%ebx, (%rax,%rdi,4)
	movl	%edx, 4(%rax,%rdi,4)
	movl	%edx, %ebx
	movl	%r13d, 8(%rax,%rdi,4)
	movl	(%r15), %edi
	leaq	L_.str(%rip), %rsi
	movl	%r14d, %edx
	callq	_dev_dbg
	movl	(%r15), %edi
	leaq	L_.str.1(%rip), %rsi
	movl	%r14d, %edx
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	callq	_dev_dbg
	movl	(%r15), %edi
	leaq	L_.str.2(%rip), %rsi
	movl	%r14d, %edx
	movl	%r12d, %ecx
	callq	_dev_dbg
	movl	(%r15), %edi
	leaq	L_.str.3(%rip), %rsi
	movl	%r14d, %edx
	movl	-52(%rbp), %ecx                 ## 4-byte Reload
	callq	_dev_dbg
	movl	(%r15), %edi
	leaq	L_.str.4(%rip), %rsi
	movl	%r14d, %edx
	movl	-48(%rbp), %ecx                 ## 4-byte Reload
	callq	_dev_dbg
	movl	(%r15), %edi
	leaq	L_.str.5(%rip), %rsi
	movl	%r14d, %edx
	movl	%ebx, %ecx
	callq	_dev_dbg
	movl	(%r15), %edi
	leaq	L_.str.6(%rip), %rsi
	movl	%r14d, %edx
	movl	%r13d, %ecx
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_dev_dbg                        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"GPADC d1   for Chn: %d = %d\n"

L_.str.1:                               ## @.str.1
	.asciz	"GPADC d2   for Chn: %d = %d\n"

L_.str.2:                               ## @.str.2
	.asciz	"GPADC x1   for Chn: %d = %d\n"

L_.str.3:                               ## @.str.3
	.asciz	"GPADC x2   for Chn: %d = %d\n"

L_.str.4:                               ## @.str.4
	.asciz	"GPADC Gain for Chn: %d = %d\n"

L_.str.5:                               ## @.str.5
	.asciz	"GPADC k    for Chn: %d = %d\n"

L_.str.6:                               ## @.str.6
	.asciz	"GPADC b    for Chn: %d = %d\n"

	.no_dead_strip	_twl6030_calibrate_channel
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function twl6030_calibrate_channel
_twl6030_calibrate_channel:             ; @twl6030_calibrate_channel
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x23, x3
	mov	x24, x2
	mov	x19, x1
	mov	x20, x0
	ldr	x8, [x0, #16]
	ldr	x21, [x8, #8]
	ldr	w2, [x8]
	mov	x0, x21
	bl	_twl6030_gpadc_lookup
	add	x8, x21, w0, sxtw #4
	ldp	w9, w10, [x8]
	sub	w9, w9, w10
	mov	w10, #1000
	mul	w9, w9, w10
	ldp	w25, w26, [x8, #8]
	sub	w8, w25, w26
	sdiv	w27, w9, w8
	sub	w9, w23, w24
	mul	w9, w9, w10
	sdiv	w8, w9, w8
	add	w22, w8, #1000
	mul	w8, w8, w26
	neg	w8, w8
	madd	w21, w24, w10, w8
	ldr	x8, [x20, #8]
	mov	w9, #12
	smaddl	x8, w0, w9, x8
	stp	w27, w22, [x8]
	str	w21, [x8, #8]
	ldr	w0, [x20]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x19
	mov	x3, x24
	bl	_dev_dbg
	ldr	w0, [x20]
Lloh2:
	adrp	x1, l_.str.1@PAGE
Lloh3:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x2, x19
	mov	x3, x23
	bl	_dev_dbg
	ldr	w0, [x20]
Lloh4:
	adrp	x1, l_.str.2@PAGE
Lloh5:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x2, x19
	mov	x3, x26
	bl	_dev_dbg
	ldr	w0, [x20]
Lloh6:
	adrp	x1, l_.str.3@PAGE
Lloh7:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x2, x19
	mov	x3, x25
	bl	_dev_dbg
	ldr	w0, [x20]
Lloh8:
	adrp	x1, l_.str.4@PAGE
Lloh9:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	x2, x19
	mov	x3, x27
	bl	_dev_dbg
	ldr	w0, [x20]
Lloh10:
	adrp	x1, l_.str.5@PAGE
Lloh11:
	add	x1, x1, l_.str.5@PAGEOFF
	mov	x2, x19
	mov	x3, x22
	bl	_dev_dbg
	ldr	w0, [x20]
Lloh12:
	adrp	x1, l_.str.6@PAGE
Lloh13:
	add	x1, x1, l_.str.6@PAGEOFF
	mov	x2, x19
	mov	x3, x21
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	b	_dev_dbg
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"GPADC d1   for Chn: %d = %d\n"

l_.str.1:                               ; @.str.1
	.asciz	"GPADC d2   for Chn: %d = %d\n"

l_.str.2:                               ; @.str.2
	.asciz	"GPADC x1   for Chn: %d = %d\n"

l_.str.3:                               ; @.str.3
	.asciz	"GPADC x2   for Chn: %d = %d\n"

l_.str.4:                               ; @.str.4
	.asciz	"GPADC Gain for Chn: %d = %d\n"

l_.str.5:                               ; @.str.5
	.asciz	"GPADC k    for Chn: %d = %d\n"

l_.str.6:                               ; @.str.6
	.asciz	"GPADC b    for Chn: %d = %d\n"

	.no_dead_strip	_twl6030_calibrate_channel
.subsections_via_symbols
