	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function set_pwm_enable
_set_pwm_enable:                        ## @set_pwm_enable
	.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	%rcx, %r14
	movq	%rdx, %r15
	movq	%rdi, %rbx
	movq	%rsi, %rdi
	callq	_to_sensor_dev_attr
	movslq	(%rax), %r12
	movq	%rbx, %rdi
	callq	_dev_get_drvdata
	movq	%rax, %r13
	movq	%r15, %rdi
	xorl	%esi, %esi
	movl	$10, %edx
	callq	_simple_strtol
	movl	%eax, %ebx
	movq	%r13, %r15
	addq	$4, %r15
	movq	%r15, %rdi
	callq	_mutex_lock
	cmpl	$1, %ebx
	je	LBB0_4
## %bb.1:
	testl	%ebx, %ebx
	jne	LBB0_3
## %bb.2:
	movq	_IT87_REG_FAN_CTL@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	movq	%r13, %rdi
	callq	_it87_read_value
	movl	(%rbx), %esi
	btsl	%r12d, %eax
	movq	%r13, %rdi
	movl	%eax, %edx
	callq	_it87_write_value
	movl	(%r13), %edx
	btrl	%r12d, %edx
	movl	%edx, (%r13)
	movq	_IT87_REG_FAN_MAIN_CTRL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	jmp	LBB0_5
LBB0_4:
	movl	(%r13), %edx
	btsl	%r12d, %edx
	movl	%edx, (%r13)
	movq	_IT87_REG_FAN_MAIN_CTRL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_it87_write_value
	movl	%r12d, %edi
	callq	_IT87_REG_PWM
	movl	%eax, %ebx
	movq	8(%r13), %rax
	movl	(%rax,%r12,4), %edi
	callq	_PWM_TO_REG
	movq	%r13, %rdi
	movl	%ebx, %esi
	movl	%eax, %edx
LBB0_5:
	callq	_it87_write_value
	movq	%r15, %rdi
	callq	_mutex_unlock
	jmp	LBB0_6
LBB0_3:
	movq	%r15, %rdi
	callq	_mutex_unlock
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subq	(%rax), %r14
LBB0_6:
	movq	%r14, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IT87_REG_FAN_CTL,4,2           ## @IT87_REG_FAN_CTL
	.comm	_IT87_REG_FAN_MAIN_CTRL,4,2     ## @IT87_REG_FAN_MAIN_CTRL
	.comm	_EINVAL,8,3                     ## @EINVAL
	.no_dead_strip	_set_pwm_enable
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function set_pwm_enable
_set_pwm_enable:                        ; @set_pwm_enable
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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	x20, x2
	mov	x21, x0
	mov	x0, x1
	bl	_to_sensor_dev_attr
	ldrsw	x22, [x0]
	mov	x0, x21
	bl	_dev_get_drvdata
	mov	x21, x0
	mov	x0, x20
	mov	x1, #0
	mov	w2, #10
	bl	_simple_strtol
	mov	x23, x0
	add	x20, x21, #4
	mov	x0, x20
	bl	_mutex_lock
	cmp	w23, #1
	b.eq	LBB0_3
; %bb.1:
	cbnz	w23, LBB0_5
; %bb.2:
Lloh0:
	adrp	x23, _IT87_REG_FAN_CTL@GOTPAGE
Lloh1:
	ldr	x23, [x23, _IT87_REG_FAN_CTL@GOTPAGEOFF]
	ldr	w1, [x23]
	mov	x0, x21
	bl	_it87_read_value
	ldr	w1, [x23]
	mov	w8, #1
	lsl	w22, w8, w22
	orr	w2, w0, w22
	mov	x0, x21
	bl	_it87_write_value
	ldr	w8, [x21]
	bic	w2, w8, w22
	str	w2, [x21]
Lloh2:
	adrp	x8, _IT87_REG_FAN_MAIN_CTRL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _IT87_REG_FAN_MAIN_CTRL@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	mov	x0, x21
	b	LBB0_4
LBB0_3:
	mov	w8, #1
	lsl	w8, w8, w22
	ldr	w9, [x21]
	orr	w2, w9, w8
	str	w2, [x21]
Lloh5:
	adrp	x8, _IT87_REG_FAN_MAIN_CTRL@GOTPAGE
Lloh6:
	ldr	x8, [x8, _IT87_REG_FAN_MAIN_CTRL@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	mov	x0, x21
	bl	_it87_write_value
	mov	x0, x22
	bl	_IT87_REG_PWM
	mov	x23, x0
	ldr	x8, [x21, #8]
	ldr	w0, [x8, x22, lsl #2]
	bl	_PWM_TO_REG
	mov	x2, x0
	mov	x0, x21
	mov	x1, x23
LBB0_4:
	bl	_it87_write_value
	mov	x0, x20
	bl	_mutex_unlock
	b	LBB0_6
LBB0_5:
	mov	x0, x20
	bl	_mutex_unlock
Lloh8:
	adrp	x8, _EINVAL@GOTPAGE
Lloh9:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh10:
	ldr	x8, [x8]
	neg	x19, x8
LBB0_6:
	mov	x0, x19
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_IT87_REG_FAN_CTL,4,2           ; @IT87_REG_FAN_CTL
	.comm	_IT87_REG_FAN_MAIN_CTRL,4,2     ; @IT87_REG_FAN_MAIN_CTRL
	.comm	_EINVAL,8,3                     ; @EINVAL
	.no_dead_strip	_set_pwm_enable
.subsections_via_symbols
