	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ab8500_charger_ac_get_property
_ab8500_charger_ac_get_property:        ## @ab8500_charger_ac_get_property
	.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
	movq	%rdx, %r14
	movl	%esi, %ebx
	callq	_psy_to_ux500_charger
	movl	%eax, %edi
	callq	_to_ab8500_charger_ac_device_info
	addl	$-128, %ebx
	cmpl	$5, %ebx
	ja	LBB0_22
## %bb.1:
	movq	%rax, %r15
	leaq	LJTI0_0(%rip), %rax
	movslq	(%rax,%rbx,4), %rcx
	addq	%rax, %rcx
	jmpq	*%rcx
LBB0_13:
	movq	%r15, %rdi
	callq	_ab8500_charger_get_ac_voltage
	testl	%eax, %eax
	js	LBB0_14
## %bb.15:
	movl	%eax, 8(%r15)
	jmp	LBB0_16
LBB0_22:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_23
LBB0_18:
	movq	%r15, %rdi
	callq	_ab8500_charger_ac_cv
	movl	%eax, 12(%r15)
	jmp	LBB0_17
LBB0_12:
	movl	4(%r15), %eax
	jmp	LBB0_17
LBB0_11:
	movl	(%r15), %eax
	jmp	LBB0_17
LBB0_2:
	cmpl	$0, 28(%r15)
	je	LBB0_5
## %bb.3:
	movq	_POWER_SUPPLY_HEALTH_UNSPEC_FAILURE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	jmp	LBB0_17
LBB0_19:
	movq	%r15, %rdi
	callq	_ab8500_charger_get_ac_current
	testl	%eax, %eax
	js	LBB0_20
## %bb.21:
	movl	%eax, 16(%r15)
	jmp	LBB0_16
LBB0_14:
	movl	8(%r15), %eax
	jmp	LBB0_16
LBB0_5:
	cmpl	$0, 20(%r15)
	jne	LBB0_7
## %bb.6:
	cmpl	$0, 32(%r15)
	je	LBB0_8
LBB0_7:
	movq	_POWER_SUPPLY_HEALTH_DEAD@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	jmp	LBB0_17
LBB0_20:
	movl	16(%r15), %eax
LBB0_16:
	imull	$1000, %eax, %eax               ## imm = 0x3E8
LBB0_17:
	movl	%eax, (%r14)
	xorl	%eax, %eax
LBB0_23:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_8:
	cmpl	$0, 24(%r15)
	je	LBB0_10
## %bb.9:
	movq	_POWER_SUPPLY_HEALTH_OVERHEAT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	jmp	LBB0_17
LBB0_10:
	movq	_POWER_SUPPLY_HEALTH_GOOD@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	jmp	LBB0_17
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_13, LBB0_13-LJTI0_0
.set L0_0_set_18, LBB0_18-LJTI0_0
.set L0_0_set_12, LBB0_12-LJTI0_0
.set L0_0_set_11, LBB0_11-LJTI0_0
.set L0_0_set_2, LBB0_2-LJTI0_0
.set L0_0_set_19, LBB0_19-LJTI0_0
LJTI0_0:
	.long	L0_0_set_13
	.long	L0_0_set_18
	.long	L0_0_set_12
	.long	L0_0_set_11
	.long	L0_0_set_2
	.long	L0_0_set_19
	.end_data_region
                                        ## -- End function
	.comm	_POWER_SUPPLY_HEALTH_UNSPEC_FAILURE,4,2 ## @POWER_SUPPLY_HEALTH_UNSPEC_FAILURE
	.comm	_POWER_SUPPLY_HEALTH_DEAD,4,2   ## @POWER_SUPPLY_HEALTH_DEAD
	.comm	_POWER_SUPPLY_HEALTH_OVERHEAT,4,2 ## @POWER_SUPPLY_HEALTH_OVERHEAT
	.comm	_POWER_SUPPLY_HEALTH_GOOD,4,2   ## @POWER_SUPPLY_HEALTH_GOOD
	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_ab8500_charger_ac_get_property
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ab8500_charger_ac_get_property
_ab8500_charger_ac_get_property:        ; @ab8500_charger_ac_get_property
	.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
	mov	x19, x2
	mov	x21, x1
	bl	_psy_to_ux500_charger
	bl	_to_ab8500_charger_ac_device_info
	sub	w8, w21, #128
	cmp	w8, #5
	b.hi	LBB0_4
; %bb.1:
	mov	x20, x0
Lloh0:
	adrp	x9, lJTI0_0@PAGE
Lloh1:
	add	x9, x9, lJTI0_0@PAGEOFF
	adr	x10, LBB0_2
	ldrb	w11, [x9, x8]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_2:
	mov	x0, x20
	bl	_ab8500_charger_get_ac_voltage
	tbnz	w0, #31, LBB0_12
; %bb.3:
	mov	x8, x0
	str	w0, [x20, #8]
	b	LBB0_18
LBB0_4:
Lloh2:
	adrp	x8, _EINVAL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_20
LBB0_5:
	mov	x0, x20
	bl	_ab8500_charger_ac_cv
	mov	x8, x0
	mov	w0, #0
	str	w8, [x20, #12]
	b	LBB0_19
LBB0_6:
	mov	w0, #0
	ldr	w8, [x20, #4]
	b	LBB0_19
LBB0_7:
	mov	w0, #0
	ldr	w8, [x20]
	b	LBB0_19
LBB0_8:
	ldr	w8, [x20, #28]
	cbz	w8, LBB0_13
; %bb.9:
	mov	w0, #0
Lloh5:
	adrp	x8, _POWER_SUPPLY_HEALTH_UNSPEC_FAILURE@GOTPAGE
Lloh6:
	ldr	x8, [x8, _POWER_SUPPLY_HEALTH_UNSPEC_FAILURE@GOTPAGEOFF]
	b	LBB0_16
LBB0_10:
	mov	x0, x20
	bl	_ab8500_charger_get_ac_current
	tbnz	w0, #31, LBB0_17
; %bb.11:
	mov	x8, x0
	str	w0, [x20, #16]
	b	LBB0_18
LBB0_12:
	ldr	w8, [x20, #8]
	b	LBB0_18
LBB0_13:
	ldr	w8, [x20, #20]
	cbnz	w8, LBB0_15
; %bb.14:
	ldr	w8, [x20, #32]
	cbz	w8, LBB0_21
LBB0_15:
	mov	w0, #0
Lloh7:
	adrp	x8, _POWER_SUPPLY_HEALTH_DEAD@GOTPAGE
Lloh8:
	ldr	x8, [x8, _POWER_SUPPLY_HEALTH_DEAD@GOTPAGEOFF]
LBB0_16:
	ldr	w8, [x8]
	b	LBB0_19
LBB0_17:
	ldr	w8, [x20, #16]
LBB0_18:
	mov	w0, #0
	mov	w9, #1000
	mul	w8, w8, w9
LBB0_19:
	str	w8, [x19]
LBB0_20:
	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_21:
	ldr	w8, [x20, #24]
	cbz	w8, LBB0_23
; %bb.22:
	mov	w0, #0
Lloh9:
	adrp	x8, _POWER_SUPPLY_HEALTH_OVERHEAT@GOTPAGE
Lloh10:
	ldr	x8, [x8, _POWER_SUPPLY_HEALTH_OVERHEAT@GOTPAGEOFF]
	b	LBB0_16
LBB0_23:
	mov	w0, #0
Lloh11:
	adrp	x8, _POWER_SUPPLY_HEALTH_GOOD@GOTPAGE
Lloh12:
	ldr	x8, [x8, _POWER_SUPPLY_HEALTH_GOOD@GOTPAGEOFF]
	b	LBB0_16
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh11, Lloh12
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_2-LBB0_2)>>2
	.byte	(LBB0_5-LBB0_2)>>2
	.byte	(LBB0_6-LBB0_2)>>2
	.byte	(LBB0_7-LBB0_2)>>2
	.byte	(LBB0_8-LBB0_2)>>2
	.byte	(LBB0_10-LBB0_2)>>2
                                        ; -- End function
	.comm	_POWER_SUPPLY_HEALTH_UNSPEC_FAILURE,4,2 ; @POWER_SUPPLY_HEALTH_UNSPEC_FAILURE
	.comm	_POWER_SUPPLY_HEALTH_DEAD,4,2   ; @POWER_SUPPLY_HEALTH_DEAD
	.comm	_POWER_SUPPLY_HEALTH_OVERHEAT,4,2 ; @POWER_SUPPLY_HEALTH_OVERHEAT
	.comm	_POWER_SUPPLY_HEALTH_GOOD,4,2   ; @POWER_SUPPLY_HEALTH_GOOD
	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_ab8500_charger_ac_get_property
.subsections_via_symbols
