	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function w83627ehf_init_device
_w83627ehf_init_device:                 ## @w83627ehf_init_device
	.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
	movl	%esi, %r15d
	movq	%rdi, %r13
	movq	_W83627EHF_REG_CONFIG@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	callq	_w83627ehf_read_value
	testb	$1, %al
	jne	LBB0_2
## %bb.1:
	movl	(%rbx), %esi
	orl	$1, %eax
	movq	%r13, %rdi
	movl	%eax, %edx
	callq	_w83627ehf_write_value
LBB0_2:
	movq	_NUM_REG_TEMP@GOTPCREL(%rip), %r14
	cmpl	$0, (%r14)
	jle	LBB0_9
## %bb.3:
	xorl	%ebx, %ebx
	jmp	LBB0_4
	.p2align	4, 0x90
LBB0_8:                                 ##   in Loop: Header=BB0_4 Depth=1
	incq	%rbx
	movslq	(%r14), %rax
	cmpq	%rax, %rbx
	jge	LBB0_9
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r13), %eax
	btl	%ebx, %eax
	jae	LBB0_8
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	32(%r13), %rax
	movl	(%rax,%rbx,4), %esi
	testl	%esi, %esi
	je	LBB0_8
## %bb.6:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	%r13, %rdi
	callq	_w83627ehf_read_value
	testb	$1, %al
	je	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	32(%r13), %rcx
	movl	(%rcx,%rbx,4), %esi
	andl	$254, %eax
	movq	%r13, %rdi
	movl	%eax, %edx
	callq	_w83627ehf_write_value
	jmp	LBB0_8
LBB0_9:
	movq	_W83627EHF_REG_VBAT@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	movq	%r13, %rdi
	callq	_w83627ehf_read_value
	movl	%eax, %r14d
	testb	$1, %r14b
	jne	LBB0_11
## %bb.10:
	movl	(%rbx), %esi
	movl	%r14d, %edx
	orl	$1, %edx
	movq	%r13, %rdi
	callq	_w83627ehf_write_value
LBB0_11:
	cmpl	$128, %r15d
	je	LBB0_12
## %bb.13:
	cmpl	$129, %r15d
	jne	LBB0_15
## %bb.14:
	movq	_W83627EHF_REG_DIODE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_w83627ehf_read_value
	movl	%eax, %r15d
	jmp	LBB0_16
LBB0_12:
	xorl	%r15d, %r15d
	jmp	LBB0_16
LBB0_15:
	movl	$112, %r15d
LBB0_16:
	movq	8(%r13), %rax
	testq	%rax, %rax
	je	LBB0_22
## %bb.17:
	movq	16(%r13), %rcx
	movq	(%rcx), %rcx
	movq	(%rax,%rcx,8), %r12
	testq	%r12, %r12
	je	LBB0_22
## %bb.18:
	leaq	L_.str(%rip), %rsi
	movq	%r12, %rdi
	movl	$4, %edx
	callq	_strncmp
	testq	%rax, %rax
	je	LBB0_19
## %bb.20:
	leaq	L_.str.1(%rip), %rsi
	movq	%r12, %rdi
	movl	$3, %edx
	callq	_strncmp
	testq	%rax, %rax
	je	LBB0_21
LBB0_22:
	movl	$4, %eax
	testb	$2, %r14b
	je	LBB0_24
## %bb.23:
	xorl	%eax, %eax
	testb	$16, %r15b
	sete	%al
	addl	%eax, %eax
	incl	%eax
	jmp	LBB0_24
LBB0_19:
	movl	$6, %eax
	jmp	LBB0_24
LBB0_21:
	movl	$5, %eax
LBB0_24:
	movq	24(%r13), %rcx
	movl	%eax, (%rcx)
	movq	8(%r13), %rax
	testq	%rax, %rax
	je	LBB0_30
## %bb.25:
	movq	16(%r13), %rcx
	movq	8(%rcx), %rcx
	movq	(%rax,%rcx,8), %r12
	testq	%r12, %r12
	je	LBB0_30
## %bb.26:
	leaq	L_.str(%rip), %rsi
	movq	%r12, %rdi
	movl	$4, %edx
	callq	_strncmp
	testq	%rax, %rax
	je	LBB0_27
## %bb.28:
	leaq	L_.str.1(%rip), %rsi
	movq	%r12, %rdi
	movl	$3, %edx
	callq	_strncmp
	testq	%rax, %rax
	je	LBB0_29
LBB0_30:
	movl	$4, %eax
	testb	$4, %r14b
	je	LBB0_32
## %bb.31:
	xorl	%eax, %eax
	testb	$32, %r15b
	sete	%al
	addl	%eax, %eax
	incl	%eax
	jmp	LBB0_32
LBB0_27:
	movl	$6, %eax
	jmp	LBB0_32
LBB0_29:
	movl	$5, %eax
LBB0_32:
	movq	24(%r13), %rcx
	movl	%eax, 4(%rcx)
	movq	8(%r13), %rax
	testq	%rax, %rax
	je	LBB0_38
## %bb.33:
	movq	16(%r13), %rcx
	movq	16(%rcx), %rcx
	movq	(%rax,%rcx,8), %r12
	testq	%r12, %r12
	je	LBB0_38
## %bb.34:
	leaq	L_.str(%rip), %rsi
	movq	%r12, %rdi
	movl	$4, %edx
	callq	_strncmp
	testq	%rax, %rax
	je	LBB0_35
## %bb.36:
	leaq	L_.str.1(%rip), %rsi
	movq	%r12, %rdi
	movl	$3, %edx
	callq	_strncmp
	testq	%rax, %rax
	je	LBB0_37
LBB0_38:
	movl	$4, %eax
	testb	$8, %r14b
	je	LBB0_40
## %bb.39:
	xorl	%eax, %eax
	testb	$64, %r15b
	sete	%al
	addl	%eax, %eax
	incl	%eax
	jmp	LBB0_40
LBB0_35:
	movl	$6, %eax
	jmp	LBB0_40
LBB0_37:
	movl	$5, %eax
LBB0_40:
	movq	24(%r13), %rcx
	movl	%eax, 8(%rcx)
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_W83627EHF_REG_CONFIG,4,2       ## @W83627EHF_REG_CONFIG
	.comm	_NUM_REG_TEMP,4,2               ## @NUM_REG_TEMP
	.comm	_W83627EHF_REG_VBAT,4,2         ## @W83627EHF_REG_VBAT
	.comm	_W83627EHF_REG_DIODE,4,2        ## @W83627EHF_REG_DIODE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"PECI"

L_.str.1:                               ## @.str.1
	.asciz	"AMD"

	.no_dead_strip	_w83627ehf_init_device
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function w83627ehf_init_device
_w83627ehf_init_device:                 ; @w83627ehf_init_device
	.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	x21, x1
	mov	x19, x0
Lloh0:
	adrp	x20, _W83627EHF_REG_CONFIG@GOTPAGE
Lloh1:
	ldr	x20, [x20, _W83627EHF_REG_CONFIG@GOTPAGEOFF]
	ldr	w1, [x20]
	bl	_w83627ehf_read_value
	tbnz	w0, #0, LBB0_2
; %bb.1:
	ldr	w1, [x20]
	orr	w2, w0, #0x1
	mov	x0, x19
	bl	_w83627ehf_write_value
LBB0_2:
Lloh2:
	adrp	x20, _NUM_REG_TEMP@GOTPAGE
Lloh3:
	ldr	x20, [x20, _NUM_REG_TEMP@GOTPAGEOFF]
	ldr	w8, [x20]
	cmp	w8, #1
	b.lt	LBB0_9
; %bb.3:
	mov	x22, #0
	b	LBB0_5
LBB0_4:                                 ;   in Loop: Header=BB0_5 Depth=1
	add	x22, x22, #1
	ldrsw	x8, [x20]
	cmp	x22, x8
	b.ge	LBB0_9
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w8, [x19]
	lsr	w8, w8, w22
	tbz	w8, #0, LBB0_4
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	x8, [x19, #32]
	ldr	w1, [x8, x22, lsl #2]
	cbz	w1, LBB0_4
; %bb.7:                                ;   in Loop: Header=BB0_5 Depth=1
	mov	x0, x19
	bl	_w83627ehf_read_value
	tbz	w0, #0, LBB0_4
; %bb.8:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	x8, [x19, #32]
	ldr	w1, [x8, x22, lsl #2]
	and	w2, w0, #0xfe
	mov	x0, x19
	bl	_w83627ehf_write_value
	b	LBB0_4
LBB0_9:
Lloh4:
	adrp	x22, _W83627EHF_REG_VBAT@GOTPAGE
Lloh5:
	ldr	x22, [x22, _W83627EHF_REG_VBAT@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x19
	bl	_w83627ehf_read_value
	mov	x20, x0
	tbnz	w0, #0, LBB0_11
; %bb.10:
	ldr	w1, [x22]
	orr	w2, w20, #0x1
	mov	x0, x19
	bl	_w83627ehf_write_value
LBB0_11:
	cmp	w21, #128
	b.eq	LBB0_14
; %bb.12:
	cmp	w21, #129
	b.ne	LBB0_15
; %bb.13:
Lloh6:
	adrp	x8, _W83627EHF_REG_DIODE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _W83627EHF_REG_DIODE@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_w83627ehf_read_value
	mov	x21, x0
	ldr	x8, [x19, #8]
	cbnz	x8, LBB0_16
	b	LBB0_19
LBB0_14:
	mov	w21, #0
	ldr	x8, [x19, #8]
	cbnz	x8, LBB0_16
	b	LBB0_19
LBB0_15:
	mov	w21, #112
	ldr	x8, [x19, #8]
	cbz	x8, LBB0_19
LBB0_16:
	ldr	x9, [x19, #16]
	ldr	x9, [x9]
	ldr	x22, [x8, x9, lsl #3]
	cbz	x22, LBB0_19
; %bb.17:
Lloh9:
	adrp	x1, l_.str@PAGE
Lloh10:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x22
	mov	w2, #4
	bl	_strncmp
	cbz	x0, LBB0_22
; %bb.18:
Lloh11:
	adrp	x1, l_.str.1@PAGE
Lloh12:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x22
	mov	w2, #3
	bl	_strncmp
	cbz	x0, LBB0_23
LBB0_19:
	tbnz	w20, #1, LBB0_21
; %bb.20:
	mov	w8, #4
	b	LBB0_24
LBB0_21:
	tst	w21, #0x10
	mov	w8, #3
	csinc	w8, w8, wzr, eq
	b	LBB0_24
LBB0_22:
	mov	w8, #6
	b	LBB0_24
LBB0_23:
	mov	w8, #5
LBB0_24:
	ldr	x9, [x19, #24]
	str	w8, [x9]
	ldr	x8, [x19, #8]
	cbz	x8, LBB0_28
; %bb.25:
	ldr	x9, [x19, #16]
	ldr	x9, [x9, #8]
	ldr	x22, [x8, x9, lsl #3]
	cbz	x22, LBB0_28
; %bb.26:
Lloh13:
	adrp	x1, l_.str@PAGE
Lloh14:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x22
	mov	w2, #4
	bl	_strncmp
	cbz	x0, LBB0_31
; %bb.27:
Lloh15:
	adrp	x1, l_.str.1@PAGE
Lloh16:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x22
	mov	w2, #3
	bl	_strncmp
	cbz	x0, LBB0_32
LBB0_28:
	tbnz	w20, #2, LBB0_30
; %bb.29:
	mov	w8, #4
	b	LBB0_33
LBB0_30:
	tst	w21, #0x20
	mov	w8, #3
	csinc	w8, w8, wzr, eq
	b	LBB0_33
LBB0_31:
	mov	w8, #6
	b	LBB0_33
LBB0_32:
	mov	w8, #5
LBB0_33:
	ldr	x9, [x19, #24]
	str	w8, [x9, #4]
	ldr	x8, [x19, #8]
	cbz	x8, LBB0_37
; %bb.34:
	ldr	x9, [x19, #16]
	ldr	x9, [x9, #16]
	ldr	x22, [x8, x9, lsl #3]
	cbz	x22, LBB0_37
; %bb.35:
Lloh17:
	adrp	x1, l_.str@PAGE
Lloh18:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x22
	mov	w2, #4
	bl	_strncmp
	cbz	x0, LBB0_40
; %bb.36:
Lloh19:
	adrp	x1, l_.str.1@PAGE
Lloh20:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x22
	mov	w2, #3
	bl	_strncmp
	cbz	x0, LBB0_41
LBB0_37:
	tbnz	w20, #3, LBB0_39
; %bb.38:
	mov	w8, #4
	b	LBB0_42
LBB0_39:
	tst	w21, #0x40
	mov	w8, #3
	csinc	w8, w8, wzr, eq
	b	LBB0_42
LBB0_40:
	mov	w8, #6
	b	LBB0_42
LBB0_41:
	mov	w8, #5
LBB0_42:
	ldr	x9, [x19, #24]
	str	w8, [x9, #8]
	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
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_W83627EHF_REG_CONFIG,4,2       ; @W83627EHF_REG_CONFIG
	.comm	_NUM_REG_TEMP,4,2               ; @NUM_REG_TEMP
	.comm	_W83627EHF_REG_VBAT,4,2         ; @W83627EHF_REG_VBAT
	.comm	_W83627EHF_REG_DIODE,4,2        ; @W83627EHF_REG_DIODE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"PECI"

l_.str.1:                               ; @.str.1
	.asciz	"AMD"

	.no_dead_strip	_w83627ehf_init_device
.subsections_via_symbols
