	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function power_supply_hwmon_read
_power_supply_hwmon_read:               ## @power_supply_hwmon_read
	.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	%r8, %r14
	movl	%ecx, %r13d
	movl	%edx, %ebx
	movl	%esi, %r15d
	callq	_dev_get_drvdata
	movq	(%rax), %r12
	movl	%r15d, %edi
	movl	%ebx, %esi
	movl	%r13d, %edx
	callq	_power_supply_hwmon_to_property
	testl	%eax, %eax
	js	LBB0_11
## %bb.1:
	leaq	-48(%rbp), %rdx
	movq	%r12, %rdi
	movl	%eax, %esi
	callq	_power_supply_get_property
	testl	%eax, %eax
	jne	LBB0_11
## %bb.2:
	leal	-129(%r15), %eax
	cmpl	$2, %eax
	jae	LBB0_3
## %bb.9:
	movq	-48(%rbp), %rdi
	movl	$1000, %esi                     ## imm = 0x3E8
	callq	_DIV_ROUND_CLOSEST
LBB0_10:
	movq	%rax, (%r14)
	xorl	%eax, %eax
	jmp	LBB0_11
LBB0_3:
	cmpl	$128, %r15d
	jne	LBB0_8
## %bb.4:
	movq	-48(%rbp), %rdi
	leaq	-48(%rbp), %rdx
	movl	$100, %esi
	callq	_check_mul_overflow
	testl	%eax, %eax
	je	LBB0_5
## %bb.6:
	movq	_EOVERFLOW@GOTPCREL(%rip), %rcx
	jmp	LBB0_7
LBB0_8:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
LBB0_7:
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_11:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	movq	-48(%rbp), %rax
	jmp	LBB0_10
	.cfi_endproc
                                        ## -- End function
	.comm	_EOVERFLOW,4,2                  ## @EOVERFLOW
	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_power_supply_hwmon_read
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function power_supply_hwmon_read
_power_supply_hwmon_read:               ; @power_supply_hwmon_read
	.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, x4
	mov	x22, x3
	mov	x23, x2
	mov	x20, x1
	bl	_dev_get_drvdata
	ldr	x21, [x0]
	mov	x0, x20
	mov	x1, x23
	mov	x2, x22
	bl	_power_supply_hwmon_to_property
	mov	x1, x0
	tbnz	w0, #31, LBB0_10
; %bb.1:
	add	x2, sp, #8
	mov	x0, x21
	bl	_power_supply_get_property
	mov	x1, x0
	cbnz	w0, LBB0_10
; %bb.2:
	sub	w8, w20, #129
	cmp	w8, #2
	b.hs	LBB0_5
; %bb.3:
	ldr	x0, [sp, #8]
	mov	w1, #1000
	bl	_DIV_ROUND_CLOSEST
LBB0_4:
	mov	w1, #0
	str	x0, [x19]
	b	LBB0_10
LBB0_5:
	cmp	w20, #128
	b.ne	LBB0_8
; %bb.6:
	ldr	x0, [sp, #8]
	add	x2, sp, #8
	mov	w1, #100
	bl	_check_mul_overflow
	cbz	w0, LBB0_11
; %bb.7:
Lloh0:
	adrp	x8, _EOVERFLOW@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EOVERFLOW@GOTPAGEOFF]
	b	LBB0_9
LBB0_8:
Lloh2:
	adrp	x8, _EINVAL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_9:
	ldr	w8, [x8]
	neg	w1, w8
LBB0_10:
	mov	x0, x1
	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
LBB0_11:
	ldr	x0, [sp, #8]
	b	LBB0_4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.cfi_endproc
                                        ; -- End function
	.comm	_EOVERFLOW,4,2                  ; @EOVERFLOW
	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_power_supply_hwmon_read
.subsections_via_symbols
