	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function fan_min_store
_fan_min_store:                         ## @fan_min_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, %r15
	movq	%rdx, %r14
	movq	%rdi, %rbx
	movq	%rsi, %rdi
	callq	_to_sensor_dev_attr
	movq	%rax, %r12
	movq	%rbx, %rdi
	callq	_dev_get_drvdata
	movq	%rax, %r13
	movq	24(%rax), %rbx
	movslq	(%r12), %r12
	leaq	-64(%rbp), %rdx
	movq	%r14, %rdi
	movl	$10, %esi
	callq	_kstrtoul
	testl	%eax, %eax
	jne	LBB0_16
## %bb.1:
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	movq	%r13, %rbx
	addq	$16, %rbx
	movq	%rbx, %rdi
	callq	_mutex_lock
	movq	-64(%rbp), %rcx
	testq	%rcx, %rcx
	je	LBB0_2
## %bb.3:
	cmpq	$663, %rcx                      ## imm = 0x297
	ja	LBB0_5
## %bb.4:
	movq	(%r13), %rax
	movl	$254, (%rax,%r12,4)
	leal	1(%r12), %r14d
	movl	$254, %edi
	movl	$8, %esi
	callq	_FAN_FROM_REG
	leaq	L_.str.1(%rip), %rsi
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movl	%r14d, %edx
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_dev_dbg
	movl	$3, %r14d
	jmp	LBB0_13
LBB0_2:
	movq	(%r13), %rax
	movl	$255, (%rax,%r12,4)
	movq	8(%r13), %rax
	movl	(%rax,%r12,4), %r14d
	leal	1(%r12), %edx
	leaq	L_.str(%rip), %rsi
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	xorl	%eax, %eax
	callq	_dev_dbg
	jmp	LBB0_13
LBB0_5:
	xorl	%r14d, %r14d
	cmpq	$1350000, %rcx                  ## imm = 0x149970
	ja	LBB0_6
## %bb.7:
	movl	$1350000, %eax                  ## imm = 0x149970
	xorl	%edx, %edx
	divl	%ecx
	movl	%eax, %edi
	cmpl	$193, %edi
	jae	LBB0_9
	jmp	LBB0_12
LBB0_6:
	xorl	%edi, %edi
	cmpl	$193, %edi
	jb	LBB0_12
LBB0_9:
	cmpl	$386, %edi                      ## imm = 0x182
	jb	LBB0_10
## %bb.11:
	movl	%edi, %eax
	shrl	$2, %eax
	movl	%edi, %ecx
	shrl	$3, %ecx
	xorl	%r14d, %r14d
	cmpl	$772, %edi                      ## imm = 0x304
	setae	%r14b
	cmovbl	%eax, %ecx
	orl	$2, %r14d
	movl	%ecx, %edi
	jmp	LBB0_12
LBB0_10:
	shrl	%edi
	movl	$1, %r14d
LBB0_12:
	testl	%edi, %edi
	movl	$1, %esi
	cmovel	%esi, %edi
	movq	(%r13), %rax
	movl	%edi, (%rax,%r12,4)
	leal	1(%r12), %eax
	movl	%eax, -52(%rbp)                 ## 4-byte Spill
	movl	%r14d, %ecx
	shll	%cl, %esi
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_FAN_FROM_REG
	leaq	L_.str.2(%rip), %rsi
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movl	-52(%rbp), %edx                 ## 4-byte Reload
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_dev_dbg
LBB0_13:
	movq	8(%r13), %rax
	cmpl	(%rax,%r12,4), %r14d
	je	LBB0_15
## %bb.14:
	movl	%r14d, (%rax,%r12,4)
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movl	%r12d, %esi
	movl	%r14d, %edx
	callq	_adm9240_write_fan_div
LBB0_15:
	movl	%r12d, %edi
	callq	_ADM9240_REG_FAN_MIN
	movq	(%r13), %rcx
	movl	(%rcx,%r12,4), %edx
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movl	%eax, %esi
	callq	_i2c_smbus_write_byte_data
	movq	%rbx, %rdi
	callq	_mutex_unlock
	movl	%r15d, %eax
LBB0_16:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"fan%u low limit set disabled\n"

L_.str.1:                               ## @.str.1
	.asciz	"fan%u low limit set minimum %u\n"

L_.str.2:                               ## @.str.2
	.asciz	"fan%u low limit set fan speed %u\n"

	.no_dead_strip	_fan_min_store
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function fan_min_store
_fan_min_store:                         ; @fan_min_store
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	mov	x19, x3
	mov	x23, x2
	mov	x20, x0
	mov	x0, x1
	bl	_to_sensor_dev_attr
	mov	x22, x0
	mov	x0, x20
	bl	_dev_get_drvdata
	mov	x21, x0
	ldr	x20, [x0, #24]
	ldrsw	x22, [x22]
	add	x2, sp, #8
	mov	x0, x23
	mov	w1, #10
	bl	_kstrtoul
	cbnz	w0, LBB0_10
; %bb.1:
	add	x23, x21, #16
	mov	x0, x23
	bl	_mutex_lock
	ldr	x8, [sp, #8]
	cbz	x8, LBB0_4
; %bb.2:
	cmp	x8, #663
	b.hi	LBB0_5
; %bb.3:
	ldr	x8, [x21]
	mov	w9, #254
	str	w9, [x8, x22, lsl #2]
	add	w24, w22, #1
	mov	w0, #254
	mov	w1, #8
	bl	_FAN_FROM_REG
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh0:
	adrp	x1, l_.str.1@PAGE
Lloh1:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x20
	mov	x2, x24
	bl	_dev_dbg
	mov	w24, #3
	b	LBB0_7
LBB0_4:
	lsl	x8, x22, #2
	mov	w9, #255
	ldp	x10, x11, [x21]
	str	w9, [x10, x8]
	ldr	w24, [x11, x8]
	add	w2, w22, #1
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	b	LBB0_6
LBB0_5:
	mov	w9, #39280
	movk	w9, #20, lsl #16
	udiv	x8, x9, x8
	lsr	w9, w8, #1
	mov	w10, #1
	lsr	w11, w8, #2
	lsr	w12, w8, #3
	mov	w13, #2
	cmp	w8, #771
	csel	w11, w12, w11, hi
	cinc	w12, w13, hi
	cmp	w8, #386
	csel	w12, w10, w12, lo
	csel	w9, w9, w11, lo
	cmp	w8, #193
	csel	w24, wzr, w12, lo
	csel	w8, w8, w9, lo
	cmp	w8, #0
	csinc	w0, w8, wzr, ne
	ldr	x8, [x21]
	str	w0, [x8, x22, lsl #2]
	add	w25, w22, #1
	lsl	w1, w10, w24
	bl	_FAN_FROM_REG
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh4:
	adrp	x1, l_.str.2@PAGE
Lloh5:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x20
	mov	x2, x25
LBB0_6:
	bl	_dev_dbg
LBB0_7:
	ldr	x8, [x21, #8]
	ldr	w9, [x8, x22, lsl #2]
	cmp	w24, w9
	b.eq	LBB0_9
; %bb.8:
	str	w24, [x8, x22, lsl #2]
	mov	x0, x20
	mov	x1, x22
	mov	x2, x24
	bl	_adm9240_write_fan_div
LBB0_9:
	mov	x0, x22
	bl	_ADM9240_REG_FAN_MIN
	mov	x1, x0
	ldr	x8, [x21]
	ldr	w2, [x8, x22, lsl #2]
	mov	x0, x20
	bl	_i2c_smbus_write_byte_data
	mov	x0, x23
	bl	_mutex_unlock
	mov	x0, x19
LBB0_10:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"fan%u low limit set disabled\n"

l_.str.1:                               ; @.str.1
	.asciz	"fan%u low limit set minimum %u\n"

l_.str.2:                               ; @.str.2
	.asciz	"fan%u low limit set fan speed %u\n"

	.no_dead_strip	_fan_min_store
.subsections_via_symbols
