	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sun4i_gpadc_probe
_sun4i_gpadc_probe:                     ## @sun4i_gpadc_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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movl	$32, %esi
	callq	_devm_iio_device_alloc
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_iio_priv
	movq	%rax, %r15
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_platform_set_drvdata
	leaq	24(%r15), %rdi
	callq	_mutex_init
	movq	%rbx, 16(%r15)
	leaq	12(%r15), %rdi
	callq	_init_completion
	movq	%r14, %rdi
	callq	_dev_name
	movl	%eax, 32(%rbx)
	movq	%r14, 24(%rbx)
	movq	(%r14), %rax
	movq	%rax, 16(%rbx)
	movq	_sun4i_gpadc_iio_info@GOTPCREL(%rip), %rcx
	movq	%rcx, 8(%rbx)
	movq	_INDIO_DIRECT_MODE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, (%rbx)
	movq	%r14, %rdi
	movq	%rbx, %rsi
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	callq	_sun4i_gpadc_probe_dt
	testl	%eax, %eax
	jne	LBB0_14
	jmp	LBB0_6
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_14
LBB0_4:
	callq	_sun4i_gpadc_probe_mfd
	testl	%eax, %eax
	jne	LBB0_14
LBB0_6:
	movq	_SUN4I_GPADC_AUTOSUSPEND_DELAY@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_pm_runtime_set_autosuspend_delay
	movq	%r14, %rdi
	callq	_pm_runtime_use_autosuspend
	movq	%r14, %rdi
	callq	_pm_runtime_set_suspended
	movq	%r14, %rdi
	callq	_pm_runtime_enable
	movq	_CONFIG_THERMAL_OF@GOTPCREL(%rip), %r13
	movl	(%r13), %edi
	callq	_IS_ENABLED
	testq	%rax, %rax
	je	LBB0_9
## %bb.7:
	movl	8(%r15), %edi
	movq	_sun4i_ts_tz_ops@GOTPCREL(%rip), %rcx
	xorl	%esi, %esi
	movq	%r15, %rdx
	callq	_thermal_zone_of_sensor_register
	movl	%eax, 4(%r15)
	movl	%eax, %edi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_9
## %bb.8:
	movl	4(%r15), %edi
	callq	_PTR_ERR
	movq	_ENODEV@GOTPCREL(%rip), %rcx
	addl	(%rcx), %eax
	jne	LBB0_15
LBB0_9:
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_devm_iio_device_register
	movl	%eax, %r12d
	xorl	%eax, %eax
	testl	%r12d, %r12d
	jns	LBB0_14
## %bb.10:
	leaq	L_.str.1(%rip), %rsi
	movq	%r14, %rdi
	xorl	%eax, %eax
	callq	_dev_err
	cmpl	$0, (%r15)
	jne	LBB0_13
## %bb.11:
	movl	(%r13), %edi
	callq	_IS_ENABLED
	testq	%rax, %rax
	je	LBB0_13
## %bb.12:
	movq	%rbx, %rdi
	callq	_iio_map_array_unregister
LBB0_13:
	movq	%r14, %rdi
	callq	_pm_runtime_put
	movq	%r14, %rdi
	callq	_pm_runtime_disable
	movl	%r12d, %eax
LBB0_14:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_15:
	movl	4(%r15), %edi
	callq	_PTR_ERR
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_dev_err
	movl	4(%r15), %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_PTR_ERR                        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_sun4i_gpadc_iio_info,4,2       ## @sun4i_gpadc_iio_info
	.comm	_INDIO_DIRECT_MODE,4,2          ## @INDIO_DIRECT_MODE
	.comm	_SUN4I_GPADC_AUTOSUSPEND_DELAY,4,2 ## @SUN4I_GPADC_AUTOSUSPEND_DELAY
	.comm	_CONFIG_THERMAL_OF,4,2          ## @CONFIG_THERMAL_OF
	.comm	_sun4i_ts_tz_ops,4,2            ## @sun4i_ts_tz_ops
	.comm	_ENODEV,4,2                     ## @ENODEV
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"could not register thermal sensor: %ld\n"

L_.str.1:                               ## @.str.1
	.asciz	"could not register the device\n"

	.no_dead_strip	_sun4i_gpadc_probe
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sun4i_gpadc_probe
_sun4i_gpadc_probe:                     ; @sun4i_gpadc_probe
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x19, x0
	mov	w1, #32
	bl	_devm_iio_device_alloc
	cbz	x0, LBB0_3
; %bb.1:
	mov	x20, x0
	bl	_iio_priv
	mov	x21, x0
	mov	x0, x19
	mov	x1, x20
	bl	_platform_set_drvdata
	add	x0, x21, #24
	bl	_mutex_init
	str	x20, [x21, #16]
	add	x0, x21, #12
	bl	_init_completion
	mov	x0, x19
	bl	_dev_name
	str	w0, [x20, #32]
	str	x19, [x20, #24]
	ldr	x8, [x19]
Lloh0:
	adrp	x9, _sun4i_gpadc_iio_info@GOTPAGE
Lloh1:
	ldr	x9, [x9, _sun4i_gpadc_iio_info@GOTPAGEOFF]
	stp	x9, x8, [x20, #8]
Lloh2:
	adrp	x9, _INDIO_DIRECT_MODE@GOTPAGE
Lloh3:
	ldr	x9, [x9, _INDIO_DIRECT_MODE@GOTPAGEOFF]
Lloh4:
	ldr	w9, [x9]
	str	w9, [x20]
	mov	x0, x19
	mov	x1, x20
	cbz	x8, LBB0_4
; %bb.2:
	bl	_sun4i_gpadc_probe_dt
	mov	x22, x0
	cbnz	w0, LBB0_14
	b	LBB0_5
LBB0_3:
Lloh5:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_14
LBB0_4:
	bl	_sun4i_gpadc_probe_mfd
	mov	x22, x0
	cbnz	w0, LBB0_14
LBB0_5:
Lloh8:
	adrp	x8, _SUN4I_GPADC_AUTOSUSPEND_DELAY@GOTPAGE
Lloh9:
	ldr	x8, [x8, _SUN4I_GPADC_AUTOSUSPEND_DELAY@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_pm_runtime_set_autosuspend_delay
	mov	x0, x19
	bl	_pm_runtime_use_autosuspend
	mov	x0, x19
	bl	_pm_runtime_set_suspended
	mov	x0, x19
	bl	_pm_runtime_enable
Lloh11:
	adrp	x23, _CONFIG_THERMAL_OF@GOTPAGE
Lloh12:
	ldr	x23, [x23, _CONFIG_THERMAL_OF@GOTPAGEOFF]
	ldr	w0, [x23]
	bl	_IS_ENABLED
	cbz	x0, LBB0_8
; %bb.6:
	ldr	w0, [x21, #8]
Lloh13:
	adrp	x3, _sun4i_ts_tz_ops@GOTPAGE
Lloh14:
	ldr	x3, [x3, _sun4i_ts_tz_ops@GOTPAGEOFF]
	mov	w1, #0
	mov	x2, x21
	bl	_thermal_zone_of_sensor_register
	str	w0, [x21, #4]
	bl	_IS_ERR
	cbz	x0, LBB0_8
; %bb.7:
	ldr	w0, [x21, #4]
	bl	_PTR_ERR
Lloh15:
	adrp	x8, _ENODEV@GOTPAGE
Lloh16:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	cmn	w0, w8
	b.ne	LBB0_15
LBB0_8:
	mov	x0, x19
	mov	x1, x20
	bl	_devm_iio_device_register
	tbnz	w0, #31, LBB0_10
; %bb.9:
	mov	w22, #0
	b	LBB0_14
LBB0_10:
	mov	x22, x0
Lloh18:
	adrp	x1, l_.str.1@PAGE
Lloh19:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_dev_err
	ldr	w8, [x21]
	cbnz	w8, LBB0_13
; %bb.11:
	ldr	w0, [x23]
	bl	_IS_ENABLED
	cbz	x0, LBB0_13
; %bb.12:
	mov	x0, x20
	bl	_iio_map_array_unregister
LBB0_13:
	mov	x0, x19
	bl	_pm_runtime_put
	mov	x0, x19
	bl	_pm_runtime_disable
LBB0_14:
	mov	x0, x22
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_15:
	ldr	w0, [x21, #4]
	bl	_PTR_ERR
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh20:
	adrp	x1, l_.str@PAGE
Lloh21:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_dev_err
	ldr	w0, [x21, #4]
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	b	_PTR_ERR
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpAdd	Lloh20, Lloh21
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_sun4i_gpadc_iio_info,4,2       ; @sun4i_gpadc_iio_info
	.comm	_INDIO_DIRECT_MODE,4,2          ; @INDIO_DIRECT_MODE
	.comm	_SUN4I_GPADC_AUTOSUSPEND_DELAY,4,2 ; @SUN4I_GPADC_AUTOSUSPEND_DELAY
	.comm	_CONFIG_THERMAL_OF,4,2          ; @CONFIG_THERMAL_OF
	.comm	_sun4i_ts_tz_ops,4,2            ; @sun4i_ts_tz_ops
	.comm	_ENODEV,4,2                     ; @ENODEV
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"could not register thermal sensor: %ld\n"

l_.str.1:                               ; @.str.1
	.asciz	"could not register the device\n"

	.no_dead_strip	_sun4i_gpadc_probe
.subsections_via_symbols
