	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function applesmc_show_fan_speed
_applesmc_show_fan_speed:               ## @applesmc_show_fan_speed
	.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	%rdx, %r14
	movq	%rsi, %rdi
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	callq	_to_sensor_dev_attr_2
	movq	_fan_speed_keys@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	(%rax), %rdx
	movq	(%rcx,%rdx,8), %rcx
	movb	(%rcx), %dl
	movb	%dl, -61(%rbp)
	movb	8(%rax), %al
	addb	$48, %al
	movb	%al, -60(%rbp)
	movb	2(%rcx), %al
	movb	%al, -59(%rbp)
	movb	3(%rcx), %al
	movb	%al, -58(%rbp)
	movb	$0, -57(%rbp)
	movq	_applesmc_lock@GOTPCREL(%rip), %r12
	movq	%r12, %rdi
	callq	_mutex_lock
	leaq	-61(%rbp), %rdi
	leaq	-56(%rbp), %rsi
	movl	$2, %edx
	callq	_applesmc_read_key
	movl	%eax, %r15d
	movl	-56(%rbp), %ebx
	movl	-52(%rbp), %r13d
	movq	%r12, %rdi
	callq	_mutex_unlock
	testl	%r15d, %r15d
	jne	LBB0_2
## %bb.1:
	shll	$8, %ebx
	orl	%r13d, %ebx
	sarl	$2, %ebx
	movq	_PAGE_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movq	%r14, %rdi
	movl	%ebx, %ecx
	callq	_snprintf
	movl	%eax, %r15d
LBB0_2:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_4
## %bb.3:
	movl	%r15d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_fan_speed_keys,8,3             ## @fan_speed_keys
	.comm	_applesmc_lock,4,2              ## @applesmc_lock
	.comm	_PAGE_SIZE,4,2                  ## @PAGE_SIZE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%u\n"

	.no_dead_strip	_applesmc_show_fan_speed
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function applesmc_show_fan_speed
_applesmc_show_fan_speed:               ; @applesmc_show_fan_speed
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	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
	mov	x19, x2
	mov	x0, x1
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #24]
	bl	_to_sensor_dev_attr_2
Lloh3:
	adrp	x8, _fan_speed_keys@GOTPAGE
Lloh4:
	ldr	x8, [x8, _fan_speed_keys@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	ldr	x9, [x0]
	ldr	x8, [x8, x9, lsl #3]
	ldrb	w9, [x8]
	strb	w9, [sp, #11]
	ldrb	w9, [x0, #8]
	add	w9, w9, #48
	strb	w9, [sp, #12]
	ldrb	w9, [x8, #2]
	strb	w9, [sp, #13]
	ldrb	w8, [x8, #3]
	strb	w8, [sp, #14]
	strb	wzr, [sp, #15]
Lloh6:
	adrp	x21, _applesmc_lock@GOTPAGE
Lloh7:
	ldr	x21, [x21, _applesmc_lock@GOTPAGEOFF]
	mov	x0, x21
	bl	_mutex_lock
	add	x0, sp, #11
	add	x1, sp, #16
	mov	w2, #2
	bl	_applesmc_read_key
	mov	x20, x0
	ldp	w22, w23, [sp, #16]
	mov	x0, x21
	bl	_mutex_unlock
	cbnz	w20, LBB0_2
; %bb.1:
	orr	w8, w23, w22, lsl #8
	asr	w3, w8, #2
Lloh8:
	adrp	x8, _PAGE_SIZE@GOTPAGE
Lloh9:
	ldr	x8, [x8, _PAGE_SIZE@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
Lloh11:
	adrp	x2, l_.str@PAGE
Lloh12:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x19
	bl	_snprintf
	mov	x20, x0
LBB0_2:
	ldr	x8, [sp, #24]
Lloh13:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh14:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh15:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_4
; %bb.3:
	mov	x0, x20
	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
	add	sp, sp, #96
	ret
LBB0_4:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.comm	_fan_speed_keys,8,3             ; @fan_speed_keys
	.comm	_applesmc_lock,4,2              ; @applesmc_lock
	.comm	_PAGE_SIZE,4,2                  ; @PAGE_SIZE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%u\n"

	.no_dead_strip	_applesmc_show_fan_speed
.subsections_via_symbols
