	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function opt3001_probe
_opt3001_probe:                         ## @opt3001_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, %rbx
	leaq	8(%rdi), %r15
	movl	(%rdi), %r14d
	movq	%r15, %rdi
	movl	$32, %esi
	callq	_devm_iio_device_alloc
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %r12
	movl	%r14d, -44(%rbp)                ## 4-byte Spill
	movq	%rax, %rdi
	callq	_iio_priv
	movq	%rax, %r13
	movq	%rbx, 24(%rax)
	movq	%r15, 8(%rax)
	leaq	20(%rax), %rdi
	callq	_mutex_init
	leaq	16(%r13), %rdi
	callq	_init_waitqueue_head
	movq	%rbx, %rdi
	movq	%r12, %rsi
	callq	_i2c_set_clientdata
	movq	%r13, %rdi
	callq	_opt3001_read_id
	movl	%eax, %r14d
	testl	%eax, %eax
	jne	LBB0_11
## %bb.3:
	movq	%r13, %rdi
	callq	_opt3001_configure
	movl	%eax, %r14d
	testl	%eax, %eax
	jne	LBB0_11
## %bb.4:
	movl	4(%rbx), %eax
	movl	%eax, 32(%r12)
	movq	_opt3001_channels@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	%edi, 28(%r12)
	callq	_ARRAY_SIZE
	movl	%eax, 24(%r12)
	movq	%r15, 16(%r12)
	movq	_INDIO_DIRECT_MODE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 8(%r12)
	movq	_opt3001_info@GOTPCREL(%rip), %rax
	movq	%rax, (%r12)
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_devm_iio_device_register
	testl	%eax, %eax
	je	LBB0_6
## %bb.5:
	movl	%eax, %r14d
	leaq	L_.str(%rip), %rsi
	movq	%r15, %rdi
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_11
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
LBB0_11:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movl	-44(%rbp), %esi                 ## 4-byte Reload
	testl	%esi, %esi
	jle	LBB0_10
## %bb.7:
	movq	_opt3001_irq@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_IRQF_TRIGGER_FALLING@GOTPCREL(%rip), %rax
	movq	_IRQF_ONESHOT@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	leaq	L_.str.1(%rip), %r8
	movl	%esi, %edi
	xorl	%r14d, %r14d
	xorl	%esi, %esi
	movq	%r12, %r9
	callq	_request_threaded_irq
	testl	%eax, %eax
	je	LBB0_9
## %bb.8:
	movl	%eax, %ebx
	leaq	L_.str.2(%rip), %rsi
	movq	%r15, %rdi
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	xorl	%eax, %eax
	callq	_dev_err
	movl	%ebx, %r14d
	jmp	LBB0_11
LBB0_10:
	movq	8(%r13), %rdi
	leaq	L_.str.3(%rip), %rsi
	callq	_dev_dbg
	xorl	%r14d, %r14d
	jmp	LBB0_11
LBB0_9:
	movl	$1, (%r13)
	jmp	LBB0_11
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_opt3001_channels,4,2           ## @opt3001_channels
	.comm	_INDIO_DIRECT_MODE,4,2          ## @INDIO_DIRECT_MODE
	.comm	_opt3001_info,4,2               ## @opt3001_info
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"failed to register IIO device\n"

	.comm	_opt3001_irq,4,2                ## @opt3001_irq
	.comm	_IRQF_TRIGGER_FALLING,4,2       ## @IRQF_TRIGGER_FALLING
	.comm	_IRQF_ONESHOT,4,2               ## @IRQF_ONESHOT
L_.str.1:                               ## @.str.1
	.asciz	"opt3001"

L_.str.2:                               ## @.str.2
	.asciz	"failed to request IRQ #%d\n"

L_.str.3:                               ## @.str.3
	.asciz	"enabling interrupt-less operation\n"

	.no_dead_strip	_opt3001_probe
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function opt3001_probe
_opt3001_probe:                         ; @opt3001_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	x23, x0
	mov	x19, x0
	ldr	w20, [x19], #8
	mov	x0, x19
	mov	w1, #32
	bl	_devm_iio_device_alloc
	cbz	x0, LBB0_6
; %bb.1:
	mov	x21, x0
	bl	_iio_priv
	mov	x22, x0
	str	x23, [x0, #24]
	str	x19, [x0, #8]
	add	x0, x0, #20
	bl	_mutex_init
	add	x0, x22, #16
	bl	_init_waitqueue_head
	mov	x0, x23
	mov	x1, x21
	bl	_i2c_set_clientdata
	mov	x0, x22
	bl	_opt3001_read_id
	mov	x24, x0
	cbnz	w0, LBB0_7
; %bb.2:
	mov	x0, x22
	bl	_opt3001_configure
	mov	x24, x0
	cbnz	w0, LBB0_7
; %bb.3:
	ldr	w8, [x23, #4]
Lloh0:
	adrp	x9, _opt3001_channels@GOTPAGE
Lloh1:
	ldr	x9, [x9, _opt3001_channels@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x9]
	stp	w0, w8, [x21, #28]
	bl	_ARRAY_SIZE
	str	w0, [x21, #24]
Lloh3:
	adrp	x8, _INDIO_DIRECT_MODE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _INDIO_DIRECT_MODE@GOTPAGEOFF]
	str	x19, [x21, #16]
Lloh5:
	ldr	w8, [x8]
	str	w8, [x21, #8]
Lloh6:
	adrp	x8, _opt3001_info@GOTPAGE
Lloh7:
	ldr	x8, [x8, _opt3001_info@GOTPAGEOFF]
	str	x8, [x21]
	mov	x0, x19
	mov	x1, x21
	bl	_devm_iio_device_register
	cbz	w0, LBB0_8
; %bb.4:
	mov	x24, x0
Lloh8:
	adrp	x1, l_.str@PAGE
Lloh9:
	add	x1, x1, l_.str@PAGEOFF
LBB0_5:
	mov	x0, x19
	bl	_dev_err
	b	LBB0_7
LBB0_6:
Lloh10:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh11:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	neg	w24, w8
LBB0_7:
	mov	x0, x24
	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_8:
	cmp	w20, #1
	b.lt	LBB0_11
; %bb.9:
Lloh13:
	adrp	x8, _opt3001_irq@GOTPAGE
Lloh14:
	ldr	x8, [x8, _opt3001_irq@GOTPAGEOFF]
Lloh15:
	adrp	x9, _IRQF_TRIGGER_FALLING@GOTPAGE
Lloh16:
	ldr	x9, [x9, _IRQF_TRIGGER_FALLING@GOTPAGEOFF]
Lloh17:
	ldr	w2, [x8]
Lloh18:
	ldr	w8, [x9]
Lloh19:
	adrp	x9, _IRQF_ONESHOT@GOTPAGE
Lloh20:
	ldr	x9, [x9, _IRQF_ONESHOT@GOTPAGEOFF]
Lloh21:
	ldr	w9, [x9]
	orr	w3, w9, w8
Lloh22:
	adrp	x4, l_.str.1@PAGE
Lloh23:
	add	x4, x4, l_.str.1@PAGEOFF
	mov	x0, x20
	mov	x1, #0
	mov	x5, x21
	bl	_request_threaded_irq
	mov	x24, x0
	cbz	w0, LBB0_12
; %bb.10:
	str	x20, [sp]
Lloh24:
	adrp	x1, l_.str.2@PAGE
Lloh25:
	add	x1, x1, l_.str.2@PAGEOFF
	b	LBB0_5
LBB0_11:
	ldr	x0, [x22, #8]
Lloh26:
	adrp	x1, l_.str.3@PAGE
Lloh27:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_dev_dbg
	mov	w24, #0
	b	LBB0_7
LBB0_12:
	mov	w8, #1
	str	w8, [x22]
	b	LBB0_7
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh18
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh17
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpAdd	Lloh26, Lloh27
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_opt3001_channels,4,2           ; @opt3001_channels
	.comm	_INDIO_DIRECT_MODE,4,2          ; @INDIO_DIRECT_MODE
	.comm	_opt3001_info,4,2               ; @opt3001_info
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"failed to register IIO device\n"

	.comm	_opt3001_irq,4,2                ; @opt3001_irq
	.comm	_IRQF_TRIGGER_FALLING,4,2       ; @IRQF_TRIGGER_FALLING
	.comm	_IRQF_ONESHOT,4,2               ; @IRQF_ONESHOT
l_.str.1:                               ; @.str.1
	.asciz	"opt3001"

l_.str.2:                               ; @.str.2
	.asciz	"failed to request IRQ #%d\n"

l_.str.3:                               ; @.str.3
	.asciz	"enabling interrupt-less operation\n"

	.no_dead_strip	_opt3001_probe
.subsections_via_symbols
