	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ci_send_msg_to_smc
_ci_send_msg_to_smc:                    ## @ci_send_msg_to_smc
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r14d
	movq	%rdi, %rbx
	movl	(%rdi), %edi
	movq	_mmSMC_RESP_0@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%edx, %edx
	callq	_cgs_write_register
	movl	(%rbx), %edi
	movq	_mmSMC_MESSAGE_0@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%r14d, %edx
	callq	_cgs_write_register
	movq	_SMC_RESP_0@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	movq	_SMC_RESP@GOTPCREL(%rip), %r12
	movl	(%r12), %edx
	movq	%rbx, %rdi
	xorl	%ecx, %ecx
	callq	_PHM_WAIT_FIELD_UNEQUAL
	movl	(%rbx), %edi
	movl	(%r15), %esi
	movl	(%r12), %edx
	callq	_PHM_READ_FIELD
	cmpl	$1, %eax
	je	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rdi
	movl	%r14d, %esi
	movl	%eax, %edx
	callq	_pr_info
LBB0_2:
	xorl	%eax, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_mmSMC_RESP_0,4,2               ## @mmSMC_RESP_0
	.comm	_mmSMC_MESSAGE_0,4,2            ## @mmSMC_MESSAGE_0
	.comm	_SMC_RESP_0,4,2                 ## @SMC_RESP_0
	.comm	_SMC_RESP,4,2                   ## @SMC_RESP
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"\n failed to send message %x ret is %d\n"

	.no_dead_strip	_ci_send_msg_to_smc
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ci_send_msg_to_smc
_ci_send_msg_to_smc:                    ; @ci_send_msg_to_smc
	.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, x1
	mov	x20, x0
	ldr	w0, [x0]
Lloh0:
	adrp	x8, _mmSMC_RESP_0@GOTPAGE
Lloh1:
	ldr	x8, [x8, _mmSMC_RESP_0@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	w2, #0
	bl	_cgs_write_register
	ldr	w0, [x20]
Lloh3:
	adrp	x8, _mmSMC_MESSAGE_0@GOTPAGE
Lloh4:
	ldr	x8, [x8, _mmSMC_MESSAGE_0@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	x2, x19
	bl	_cgs_write_register
Lloh6:
	adrp	x21, _SMC_RESP_0@GOTPAGE
Lloh7:
	ldr	x21, [x21, _SMC_RESP_0@GOTPAGEOFF]
	ldr	w1, [x21]
Lloh8:
	adrp	x22, _SMC_RESP@GOTPAGE
Lloh9:
	ldr	x22, [x22, _SMC_RESP@GOTPAGEOFF]
	ldr	w2, [x22]
	mov	x0, x20
	mov	w3, #0
	bl	_PHM_WAIT_FIELD_UNEQUAL
	ldr	w0, [x20]
	ldr	w1, [x21]
	ldr	w2, [x22]
	bl	_PHM_READ_FIELD
	cmp	w0, #1
	b.eq	LBB0_2
; %bb.1:
	mov	x2, x0
Lloh10:
	adrp	x0, l_.str@PAGE
Lloh11:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x19
	bl	_pr_info
LBB0_2:
	mov	w0, #0
	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	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_mmSMC_RESP_0,4,2               ; @mmSMC_RESP_0
	.comm	_mmSMC_MESSAGE_0,4,2            ; @mmSMC_MESSAGE_0
	.comm	_SMC_RESP_0,4,2                 ; @SMC_RESP_0
	.comm	_SMC_RESP,4,2                   ; @SMC_RESP
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"\n failed to send message %x ret is %d\n"

	.no_dead_strip	_ci_send_msg_to_smc
.subsections_via_symbols
