	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function fan_div_store
_fan_div_store:                         ## @fan_div_store
	.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
	movq	%rcx, -56(%rbp)                 ## 8-byte Spill
	movq	%rdx, %rbx
	movq	%rsi, %r14
	movq	%rdi, %r12
	callq	_dev_get_drvdata
	movq	%rax, %r13
	movq	16(%rax), %r15
	movq	%r14, %rdi
	callq	_to_sensor_dev_attr
	movslq	(%rax), %r14
	leaq	-48(%rbp), %rdx
	movq	%rbx, %rdi
	movl	$10, %esi
	callq	_kstrtoul
	testl	%eax, %eax
	jne	LBB0_9
## %bb.1:
	movq	-48(%rbp), %rdx
	leaq	-1(%rdx), %rax
	cmpq	$7, %rax
	ja	LBB0_6
## %bb.2:
	leaq	LJTI0_0(%rip), %rcx
	movslq	(%rcx,%rax,4), %rax
	addq	%rcx, %rax
	jmpq	*%rax
LBB0_7:
	movq	$0, -48(%rbp)
	jmp	LBB0_8
LBB0_3:
	movq	$1, -48(%rbp)
	jmp	LBB0_8
LBB0_6:
	leaq	L_.str(%rip), %rsi
	movq	%r12, %rdi
	callq	_dev_err
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_9
LBB0_4:
	movq	$2, -48(%rbp)
	jmp	LBB0_8
LBB0_5:
	movq	$3, -48(%rbp)
LBB0_8:
	movq	%r13, %r12
	addq	$8, %r12
	movq	%r12, %rdi
	callq	_mutex_lock
	movq	_GL518_REG_MISC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_gl518_read_value
	movq	-48(%rbp), %rdx
	movq	(%r13), %rcx
	movq	%rdx, (%rcx,%r14,8)
	leal	(%r14,%r14), %ecx
	movl	$-193, %esi
	sarl	%cl, %esi
	movb	$6, %bl
	subb	%cl, %bl
	movl	%ebx, %ecx
	shlq	%cl, %rdx
	andl	%eax, %esi
	orl	%esi, %edx
	movq	_GL518_REG_MISC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_gl518_write_value
	movq	%r12, %rdi
	callq	_mutex_unlock
	movq	-56(%rbp), %rax                 ## 8-byte Reload
                                        ## kill: def $eax killed $eax killed $rax
LBB0_9:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_7, LBB0_7-LJTI0_0
.set L0_0_set_3, LBB0_3-LJTI0_0
.set L0_0_set_6, LBB0_6-LJTI0_0
.set L0_0_set_4, LBB0_4-LJTI0_0
.set L0_0_set_5, LBB0_5-LJTI0_0
LJTI0_0:
	.long	L0_0_set_7
	.long	L0_0_set_3
	.long	L0_0_set_6
	.long	L0_0_set_4
	.long	L0_0_set_6
	.long	L0_0_set_6
	.long	L0_0_set_6
	.long	L0_0_set_5
	.end_data_region
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Invalid fan clock divider %lu, choose one of 1, 2, 4 or 8\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_GL518_REG_MISC,4,2             ## @GL518_REG_MISC
	.no_dead_strip	_fan_div_store
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function fan_div_store
_fan_div_store:                         ; @fan_div_store
	.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, x3
	mov	x23, x2
	mov	x24, x1
	mov	x22, x0
	bl	_dev_get_drvdata
	mov	x21, x0
	ldr	x20, [x0, #16]
	mov	x0, x24
	bl	_to_sensor_dev_attr
	ldrsw	x24, [x0]
	add	x2, sp, #8
	mov	x0, x23
	mov	w1, #10
	bl	_kstrtoul
	cbnz	w0, LBB0_10
; %bb.1:
	ldr	x2, [sp, #8]
	sub	x8, x2, #1
	cmp	x8, #7
	b.hi	LBB0_5
; %bb.2:
Lloh0:
	adrp	x9, lJTI0_0@PAGE
Lloh1:
	add	x9, x9, lJTI0_0@PAGEOFF
	adr	x10, LBB0_3
	ldrb	w11, [x9, x8]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_3:
	str	xzr, [sp, #8]
	b	LBB0_9
LBB0_4:
	mov	w8, #1
	b	LBB0_8
LBB0_5:
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x22
	bl	_dev_err
Lloh4:
	adrp	x8, _EINVAL@GOTPAGE
Lloh5:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_10
LBB0_6:
	mov	w8, #2
	b	LBB0_8
LBB0_7:
	mov	w8, #3
LBB0_8:
	str	x8, [sp, #8]
LBB0_9:
	add	x22, x21, #8
	mov	x0, x22
	bl	_mutex_lock
Lloh7:
	adrp	x23, _GL518_REG_MISC@GOTPAGE
Lloh8:
	ldr	x23, [x23, _GL518_REG_MISC@GOTPAGEOFF]
	ldr	w1, [x23]
	mov	x0, x20
	bl	_gl518_read_value
	ldr	x8, [sp, #8]
	ldr	x9, [x21]
	str	x8, [x9, x24, lsl #3]
	lsl	w9, w24, #1
	mov	w10, #-193
	asr	w10, w10, w9
	and	w10, w0, w10
	mov	w11, #6
	sub	w9, w11, w9
	lsl	x8, x8, x9
	orr	w2, w10, w8
	ldr	w1, [x23]
	mov	x0, x20
	bl	_gl518_write_value
	mov	x0, x22
	bl	_mutex_unlock
	mov	x0, x19
LBB0_10:
	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
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh7, Lloh8
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_3-LBB0_3)>>2
	.byte	(LBB0_4-LBB0_3)>>2
	.byte	(LBB0_5-LBB0_3)>>2
	.byte	(LBB0_6-LBB0_3)>>2
	.byte	(LBB0_5-LBB0_3)>>2
	.byte	(LBB0_5-LBB0_3)>>2
	.byte	(LBB0_5-LBB0_3)>>2
	.byte	(LBB0_7-LBB0_3)>>2
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Invalid fan clock divider %lu, choose one of 1, 2, 4 or 8\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_GL518_REG_MISC,4,2             ; @GL518_REG_MISC
	.no_dead_strip	_fan_div_store
.subsections_via_symbols
