	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function gl518_probe
_gl518_probe:                           ## @gl518_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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$24, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %r15
	movq	%r14, %rdi
	movq	%rax, %rsi
	callq	_i2c_set_clientdata
	movq	_GL518_REG_REVISION@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_gl518_read_value
	cmpl	$128, %eax
	jne	LBB0_3
## %bb.4:
	movq	_gl518sm_r80@GOTPCREL(%rip), %rax
	jmp	LBB0_5
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_14
LBB0_3:
	movq	_gl518sm_r00@GOTPCREL(%rip), %rax
LBB0_5:
	movq	(%rax), %rax
	movq	%rax, (%r15)
	movq	%r15, %rdi
	addq	$16, %rdi
	callq	_mutex_init
	movl	$255, 8(%r15)
	movq	%r14, %rdi
	callq	_gl518_init_client
	movq	_gl518_group@GOTPCREL(%rip), %rsi
	movq	%r14, %rdi
	callq	_sysfs_create_group
	movl	%eax, %ebx
	testl	%eax, %eax
	je	LBB0_6
LBB0_13:
	movq	%r15, %rdi
	callq	_kfree
LBB0_14:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movq	(%r15), %rax
	movq	_gl518sm_r80@GOTPCREL(%rip), %r12
	cmpq	(%r12), %rax
	jne	LBB0_8
## %bb.7:
	movq	_gl518_group_r80@GOTPCREL(%rip), %rsi
	movq	%r14, %rdi
	callq	_sysfs_create_group
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_11
LBB0_8:
	movq	%r14, %rdi
	callq	_hwmon_device_register
	movl	%eax, 12(%r15)
	movl	%eax, %edi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_9
## %bb.10:
	movl	12(%r15), %edi
	callq	_PTR_ERR
	movl	%eax, %ebx
LBB0_11:
	movq	_gl518_group@GOTPCREL(%rip), %rsi
	movq	%r14, %rdi
	callq	_sysfs_remove_group
	movq	(%r15), %rax
	cmpq	(%r12), %rax
	jne	LBB0_13
## %bb.12:
	movq	_gl518_group_r80@GOTPCREL(%rip), %rsi
	movq	%r14, %rdi
	callq	_sysfs_remove_group
	jmp	LBB0_13
LBB0_9:
	xorl	%ebx, %ebx
	jmp	LBB0_14
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_GL518_REG_REVISION,4,2         ## @GL518_REG_REVISION
	.comm	_gl518sm_r80,8,3                ## @gl518sm_r80
	.comm	_gl518sm_r00,8,3                ## @gl518sm_r00
	.comm	_gl518_group,4,2                ## @gl518_group
	.comm	_gl518_group_r80,4,2            ## @gl518_group_r80
	.no_dead_strip	_gl518_probe
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function gl518_probe
_gl518_probe:                           ; @gl518_probe
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	mov	x20, x0
Lloh0:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	w0, #24
	bl	_kzalloc
	cbz	x0, LBB0_3
; %bb.1:
	mov	x19, x0
	mov	x0, x20
	mov	x1, x19
	bl	_i2c_set_clientdata
Lloh3:
	adrp	x8, _GL518_REG_REVISION@GOTPAGE
Lloh4:
	ldr	x8, [x8, _GL518_REG_REVISION@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_gl518_read_value
Lloh6:
	adrp	x22, _gl518sm_r80@GOTPAGE
Lloh7:
	ldr	x22, [x22, _gl518sm_r80@GOTPAGEOFF]
Lloh8:
	adrp	x8, _gl518sm_r00@GOTPAGE
Lloh9:
	ldr	x8, [x8, _gl518sm_r00@GOTPAGEOFF]
	cmp	w0, #128
	csel	x8, x22, x8, eq
	ldr	x8, [x8]
	str	x8, [x19]
	add	x0, x19, #16
	bl	_mutex_init
	mov	w8, #255
	str	w8, [x19, #8]
	mov	x0, x20
	bl	_gl518_init_client
Lloh10:
	adrp	x1, _gl518_group@GOTPAGE
Lloh11:
	ldr	x1, [x1, _gl518_group@GOTPAGEOFF]
	mov	x0, x20
	bl	_sysfs_create_group
	mov	x21, x0
	cbz	w0, LBB0_5
LBB0_2:
	mov	x0, x19
	bl	_kfree
	b	LBB0_4
LBB0_3:
Lloh12:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh13:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_4:
	mov	x0, x21
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
LBB0_5:
	ldr	x8, [x19]
	ldr	x9, [x22]
	cmp	x8, x9
	b.ne	LBB0_7
; %bb.6:
Lloh15:
	adrp	x1, _gl518_group_r80@GOTPAGE
Lloh16:
	ldr	x1, [x1, _gl518_group_r80@GOTPAGEOFF]
	mov	x0, x20
	bl	_sysfs_create_group
	mov	x21, x0
	cbnz	w0, LBB0_9
LBB0_7:
	mov	x0, x20
	bl	_hwmon_device_register
	str	w0, [x19, #12]
	bl	_IS_ERR
	cbz	x0, LBB0_11
; %bb.8:
	ldr	w0, [x19, #12]
	bl	_PTR_ERR
	mov	x21, x0
LBB0_9:
Lloh17:
	adrp	x1, _gl518_group@GOTPAGE
Lloh18:
	ldr	x1, [x1, _gl518_group@GOTPAGEOFF]
	mov	x0, x20
	bl	_sysfs_remove_group
	ldr	x8, [x19]
	ldr	x9, [x22]
	cmp	x8, x9
	b.ne	LBB0_2
; %bb.10:
Lloh19:
	adrp	x1, _gl518_group_r80@GOTPAGE
Lloh20:
	ldr	x1, [x1, _gl518_group_r80@GOTPAGEOFF]
	mov	x0, x20
	bl	_sysfs_remove_group
	b	LBB0_2
LBB0_11:
	mov	w21, #0
	b	LBB0_4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_GL518_REG_REVISION,4,2         ; @GL518_REG_REVISION
	.comm	_gl518sm_r80,8,3                ; @gl518sm_r80
	.comm	_gl518sm_r00,8,3                ; @gl518sm_r00
	.comm	_gl518_group,4,2                ; @gl518_group
	.comm	_gl518_group_r80,4,2            ; @gl518_group_r80
	.no_dead_strip	_gl518_probe
.subsections_via_symbols
