	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function acpi_power_meter_add
_acpi_power_meter_add:                  ## @acpi_power_meter_add
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	testq	%rdi, %rdi
	je	LBB0_1
## %bb.3:
	movq	%rdi, %r14
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$32, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_4
## %bb.5:
	movq	%rax, %r15
	movq	$0, 24(%rax)
	movq	%r14, 16(%rax)
	movq	%rax, %rdi
	addq	$12, %rdi
	callq	_mutex_init
	movq	%r14, %rdi
	callq	_acpi_device_name
	movq	_ACPI_POWER_METER_DEVICE_NAME@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movl	%eax, %edi
	callq	_strcpy
	movq	%r14, %rdi
	callq	_acpi_device_class
	movq	_ACPI_POWER_METER_CLASS@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movl	%eax, %edi
	callq	_strcpy
	movq	%r15, 8(%r14)
	movq	%r15, %rdi
	callq	_free_capabilities
	movq	%r15, %rdi
	callq	_read_capabilities
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_10
## %bb.6:
	movq	(%r15), %rax
	movq	$-1, (%rax)
	movq	%r15, %rdi
	callq	_setup_attrs
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_10
## %bb.7:
	movq	%r14, %rdi
	callq	_hwmon_device_register
	movl	%eax, 8(%r15)
	movl	%eax, %edi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_8
## %bb.9:
	movl	8(%r15), %edi
	callq	_PTR_ERR
	movl	%eax, %ebx
	movq	%r15, %rdi
	callq	_remove_attrs
LBB0_10:
	movq	%r15, %rdi
	callq	_kfree
	jmp	LBB0_11
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_2
LBB0_4:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
LBB0_2:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_11:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_8:
	xorl	%ebx, %ebx
	jmp	LBB0_11
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_ACPI_POWER_METER_DEVICE_NAME,4,2 ## @ACPI_POWER_METER_DEVICE_NAME
	.comm	_ACPI_POWER_METER_CLASS,4,2     ## @ACPI_POWER_METER_CLASS
	.no_dead_strip	_acpi_power_meter_add
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function acpi_power_meter_add
_acpi_power_meter_add:                  ; @acpi_power_meter_add
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	cbz	x0, LBB0_7
; %bb.1:
	mov	x20, x0
Lloh0:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	w0, #32
	bl	_kzalloc
	cbz	x0, LBB0_8
; %bb.2:
	mov	x19, x0
	stp	x20, xzr, [x0, #16]
	add	x0, x0, #12
	bl	_mutex_init
	mov	x0, x20
	bl	_acpi_device_name
Lloh3:
	adrp	x8, _ACPI_POWER_METER_DEVICE_NAME@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ACPI_POWER_METER_DEVICE_NAME@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	bl	_strcpy
	mov	x0, x20
	bl	_acpi_device_class
Lloh6:
	adrp	x8, _ACPI_POWER_METER_CLASS@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ACPI_POWER_METER_CLASS@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	bl	_strcpy
	str	x19, [x20, #8]
	mov	x0, x19
	bl	_free_capabilities
	mov	x0, x19
	bl	_read_capabilities
	mov	x21, x0
	cbnz	w0, LBB0_6
; %bb.3:
	ldr	x8, [x19]
	movi.2d	v0, #0xffffffffffffffff
	str	d0, [x8]
	mov	x0, x19
	bl	_setup_attrs
	mov	x21, x0
	cbnz	w0, LBB0_6
; %bb.4:
	mov	x0, x20
	bl	_hwmon_device_register
	str	w0, [x19, #8]
	bl	_IS_ERR
	cbz	x0, LBB0_11
; %bb.5:
	ldr	w0, [x19, #8]
	bl	_PTR_ERR
	mov	x21, x0
	mov	x0, x19
	bl	_remove_attrs
LBB0_6:
	mov	x0, x19
	bl	_kfree
	b	LBB0_10
LBB0_7:
Lloh9:
	adrp	x8, _EINVAL@GOTPAGE
Lloh10:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_9
LBB0_8:
Lloh11:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh12:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
LBB0_9:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_10:
	mov	x0, x21
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
LBB0_11:
	mov	w21, #0
	b	LBB0_10
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_ACPI_POWER_METER_DEVICE_NAME,4,2 ; @ACPI_POWER_METER_DEVICE_NAME
	.comm	_ACPI_POWER_METER_CLASS,4,2     ; @ACPI_POWER_METER_CLASS
	.no_dead_strip	_acpi_power_meter_add
.subsections_via_symbols
