	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ads7828_probe
_ads7828_probe:                         ## @ads7828_probe
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r12
	movq	%rdi, -64(%rbp)                 ## 8-byte Spill
	leaq	8(%rdi), %r14
	movq	%r14, %rdi
	callq	_dev_get_platdata
	movq	%rax, %rbx
	movq	_ADS7828_INT_VREF_MV@GOTPCREL(%rip), %rax
	movl	(%rax), %r13d
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	movl	$24, %esi
	callq	_devm_kzalloc
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %r15
	testq	%rbx, %rbx
	movq	%r12, -56(%rbp)                 ## 8-byte Spill
	je	LBB0_5
## %bb.3:
	movl	(%rbx), %eax
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	cmpl	$0, 4(%rbx)
	je	LBB0_4
## %bb.11:
	movl	8(%rbx), %eax
	testl	%eax, %eax
	cmovnel	%eax, %r13d
	xorl	%r12d, %r12d
	cmpq	$0, (%r14)
	jne	LBB0_13
	jmp	LBB0_14
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r12d, %r12d
	subl	(%rax), %r12d
	jmp	LBB0_24
LBB0_5:
	movq	(%r14), %rdi
	movb	$1, %r12b
	testq	%rdi, %rdi
	je	LBB0_6
## %bb.7:
	leaq	L_.str(%rip), %rsi
	callq	_of_property_read_bool
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	leaq	L_.str.1(%rip), %rsi
	movq	%r14, %rdi
	callq	_devm_regulator_get_optional
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	jne	LBB0_12
## %bb.8:
	movq	%rbx, %rdi
	callq	_regulator_get_voltage
	movl	%eax, %edi
	movl	$1000, %esi                     ## imm = 0x3E8
	callq	_DIV_ROUND_CLOSEST
	movq	%rax, %r13
	movq	_ADS7828_EXT_VREF_MV_MIN@GOTPCREL(%rip), %rax
	xorl	%r12d, %r12d
	cmpl	%r13d, (%rax)
	ja	LBB0_10
## %bb.9:
	movq	_ADS7828_EXT_VREF_MV_MAX@GOTPCREL(%rip), %rax
	cmpl	%r13d, (%rax)
	jae	LBB0_12
LBB0_10:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	subl	(%rax), %r12d
	jmp	LBB0_24
LBB0_4:
	movb	$1, %r12b
LBB0_12:
	cmpq	$0, (%r14)
	je	LBB0_14
LBB0_13:
	movq	%r14, %rdi
	callq	_of_device_get_match_data
	movq	%rax, %rbx
	jmp	LBB0_15
LBB0_6:
	movl	$0, -44(%rbp)                   ## 4-byte Folded Spill
	cmpq	$0, (%r14)
	jne	LBB0_13
LBB0_14:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %ebx
LBB0_15:
	movq	_ADS7828_EXT_VREF_MV_MIN@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_ADS7828_EXT_VREF_MV_MAX@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	%r13d, %edi
	callq	_clamp_val
	movq	_ads7828@GOTPCREL(%rip), %rcx
	imull	$1000, %eax, %edi               ## imm = 0x3E8
	cmpl	(%rcx), %ebx
	movl	$4096, %eax                     ## imm = 0x1000
	movl	$256, %esi                      ## imm = 0x100
	cmovel	%eax, %esi
	movq	_ads2830_regmap_config@GOTPCREL(%rip), %rbx
	cmoveq	_ads2828_regmap_config@GOTPCREL(%rip), %rbx
	callq	_DIV_ROUND_CLOSEST
	movq	%rax, 16(%r15)
	movq	-64(%rbp), %r13                 ## 8-byte Reload
	movq	%r13, %rdi
	movq	%rbx, %rsi
	callq	_devm_regmap_init_i2c
	movq	%rax, 8(%r15)
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_16
## %bb.25:
	movq	8(%r15), %rdi
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_PTR_ERR                        ## TAILCALL
LBB0_16:
	testb	%r12b, %r12b
	je	LBB0_17
## %bb.18:
	movq	_ADS7828_CMD_PD3@GOTPCREL(%rip), %rax
	jmp	LBB0_19
LBB0_17:
	movq	_ADS7828_CMD_PD1@GOTPCREL(%rip), %rax
LBB0_19:
	movl	(%rax), %esi
	movl	%esi, (%r15)
	cmpl	$0, -44(%rbp)                   ## 4-byte Folded Reload
	jne	LBB0_21
## %bb.20:
	movq	_ADS7828_CMD_SD_SE@GOTPCREL(%rip), %rax
	orl	(%rax), %esi
	movl	%esi, (%r15)
LBB0_21:
	testb	%r12b, %r12b
	je	LBB0_23
## %bb.22:
	movq	8(%r15), %rdi
	leaq	-68(%rbp), %rdx
	callq	_regmap_read
LBB0_23:
	movl	(%r13), %esi
	movq	_ads7828_groups@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r14, %rdi
	movq	%r15, %rdx
	callq	_devm_hwmon_device_register_with_groups
	movq	%rax, %rdi
	callq	_PTR_ERR_OR_ZERO
	movl	%eax, %r12d
LBB0_24:
	movl	%r12d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ADS7828_INT_VREF_MV,4,2        ## @ADS7828_INT_VREF_MV
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"ti,differential-input"

L_.str.1:                               ## @.str.1
	.asciz	"vref"

	.comm	_ADS7828_EXT_VREF_MV_MIN,4,2    ## @ADS7828_EXT_VREF_MV_MIN
	.comm	_ADS7828_EXT_VREF_MV_MAX,4,2    ## @ADS7828_EXT_VREF_MV_MAX
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_ads7828,4,2                    ## @ads7828
	.comm	_ads2828_regmap_config,4,2      ## @ads2828_regmap_config
	.comm	_ads2830_regmap_config,4,2      ## @ads2830_regmap_config
	.comm	_ADS7828_CMD_PD1,4,2            ## @ADS7828_CMD_PD1
	.comm	_ADS7828_CMD_PD3,4,2            ## @ADS7828_CMD_PD3
	.comm	_ADS7828_CMD_SD_SE,4,2          ## @ADS7828_CMD_SD_SE
	.comm	_ads7828_groups,4,2             ## @ads7828_groups
	.no_dead_strip	_ads7828_probe
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ads7828_probe
_ads7828_probe:                         ; @ads7828_probe
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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, x1
	mov	x20, x0
	add	x19, x0, #8
	mov	x0, x19
	bl	_dev_get_platdata
	mov	x25, x0
Lloh0:
	adrp	x8, _ADS7828_INT_VREF_MV@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ADS7828_INT_VREF_MV@GOTPAGEOFF]
Lloh2:
	ldr	w24, [x8]
Lloh3:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	mov	x0, x19
	mov	w1, #24
	bl	_devm_kzalloc
	cbz	x0, LBB0_5
; %bb.1:
	mov	x21, x0
Lloh6:
	adrp	x26, _ADS7828_EXT_VREF_MV_MIN@GOTPAGE
Lloh7:
	ldr	x26, [x26, _ADS7828_EXT_VREF_MV_MIN@GOTPAGEOFF]
Lloh8:
	adrp	x27, _ADS7828_EXT_VREF_MV_MAX@GOTPAGE
Lloh9:
	ldr	x27, [x27, _ADS7828_EXT_VREF_MV_MAX@GOTPAGEOFF]
	cbz	x25, LBB0_7
; %bb.2:
	ldp	w22, w8, [x25]
	cbz	w8, LBB0_12
; %bb.3:
	mov	w28, #0
	ldr	w8, [x25, #8]
	cmp	w8, #0
	csel	w24, w24, w8, eq
	ldr	x8, [x19]
	cbnz	x8, LBB0_13
LBB0_4:
	ldr	w23, [x23]
	b	LBB0_14
LBB0_5:
Lloh10:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh11:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
LBB0_6:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_21
LBB0_7:
	ldr	x0, [x19]
	cbz	x0, LBB0_11
; %bb.8:
Lloh12:
	adrp	x1, l_.str@PAGE
Lloh13:
	add	x1, x1, l_.str@PAGEOFF
	bl	_of_property_read_bool
	mov	x22, x0
Lloh14:
	adrp	x1, l_.str.1@PAGE
Lloh15:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_devm_regulator_get_optional
	mov	x25, x0
	bl	_IS_ERR
	cbnz	x0, LBB0_12
; %bb.9:
	mov	x0, x25
	bl	_regulator_get_voltage
	mov	w1, #1000
	bl	_DIV_ROUND_CLOSEST
	mov	x24, x0
	ldr	w8, [x26]
	ldr	w9, [x27]
	cmp	w8, w24
	ccmp	w9, w24, #0, ls
	b.hs	LBB0_22
; %bb.10:
Lloh16:
	adrp	x8, _EINVAL@GOTPAGE
Lloh17:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_6
LBB0_11:
	mov	w22, #0
LBB0_12:
	mov	w28, #1
	ldr	x8, [x19]
	cbz	x8, LBB0_4
LBB0_13:
	mov	x0, x19
	bl	_of_device_get_match_data
	mov	x23, x0
LBB0_14:
	ldr	w1, [x26]
	ldr	w2, [x27]
	mov	x0, x24
	bl	_clamp_val
Lloh18:
	adrp	x8, _ads7828@GOTPAGE
Lloh19:
	ldr	x8, [x8, _ads7828@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	mov	w9, #1000
	mul	w0, w0, w9
	mov	w9, #256
	mov	w10, #4096
	cmp	w23, w8
	csel	w1, w10, w9, eq
Lloh21:
	adrp	x8, _ads2830_regmap_config@GOTPAGE
Lloh22:
	ldr	x8, [x8, _ads2830_regmap_config@GOTPAGEOFF]
Lloh23:
	adrp	x9, _ads2828_regmap_config@GOTPAGE
Lloh24:
	ldr	x9, [x9, _ads2828_regmap_config@GOTPAGEOFF]
	csel	x23, x9, x8, eq
	bl	_DIV_ROUND_CLOSEST
	str	x0, [x21, #16]
	mov	x0, x20
	mov	x1, x23
	bl	_devm_regmap_init_i2c
	str	x0, [x21, #8]
	bl	_IS_ERR
	cbz	x0, LBB0_16
; %bb.15:
	ldr	x0, [x21, #8]
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	b	_PTR_ERR
LBB0_16:
Lloh25:
	adrp	x8, _ADS7828_CMD_PD1@GOTPAGE
Lloh26:
	ldr	x8, [x8, _ADS7828_CMD_PD1@GOTPAGEOFF]
Lloh27:
	adrp	x9, _ADS7828_CMD_PD3@GOTPAGE
Lloh28:
	ldr	x9, [x9, _ADS7828_CMD_PD3@GOTPAGEOFF]
	cmp	w28, #0
	csel	x8, x9, x8, ne
	ldr	w1, [x8]
	str	w1, [x21]
	cbnz	w22, LBB0_18
; %bb.17:
Lloh29:
	adrp	x8, _ADS7828_CMD_SD_SE@GOTPAGE
Lloh30:
	ldr	x8, [x8, _ADS7828_CMD_SD_SE@GOTPAGEOFF]
Lloh31:
	ldr	w8, [x8]
	orr	w1, w8, w1
	str	w1, [x21]
LBB0_18:
	cbz	w28, LBB0_20
; %bb.19:
	ldr	x0, [x21, #8]
	add	x2, sp, #12
	bl	_regmap_read
LBB0_20:
	ldr	w1, [x20]
Lloh32:
	adrp	x8, _ads7828_groups@GOTPAGE
Lloh33:
	ldr	x8, [x8, _ads7828_groups@GOTPAGEOFF]
Lloh34:
	ldr	w3, [x8]
	mov	x0, x19
	mov	x2, x21
	bl	_devm_hwmon_device_register_with_groups
	bl	_PTR_ERR_OR_ZERO
LBB0_21:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_22:
	mov	w28, #0
	ldr	x8, [x19]
	cbnz	x8, LBB0_13
	b	LBB0_4
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh23, Lloh24
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh27, Lloh28
	.loh AdrpLdrGot	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.cfi_endproc
                                        ; -- End function
	.comm	_ADS7828_INT_VREF_MV,4,2        ; @ADS7828_INT_VREF_MV
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"ti,differential-input"

l_.str.1:                               ; @.str.1
	.asciz	"vref"

	.comm	_ADS7828_EXT_VREF_MV_MIN,4,2    ; @ADS7828_EXT_VREF_MV_MIN
	.comm	_ADS7828_EXT_VREF_MV_MAX,4,2    ; @ADS7828_EXT_VREF_MV_MAX
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_ads7828,4,2                    ; @ads7828
	.comm	_ads2828_regmap_config,4,2      ; @ads2828_regmap_config
	.comm	_ads2830_regmap_config,4,2      ; @ads2830_regmap_config
	.comm	_ADS7828_CMD_PD1,4,2            ; @ADS7828_CMD_PD1
	.comm	_ADS7828_CMD_PD3,4,2            ; @ADS7828_CMD_PD3
	.comm	_ADS7828_CMD_SD_SE,4,2          ; @ADS7828_CMD_SD_SE
	.comm	_ads7828_groups,4,2             ; @ads7828_groups
	.no_dead_strip	_ads7828_probe
.subsections_via_symbols
