	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_hv_fcopy_onchannelcallback     ## -- Begin function hv_fcopy_onchannelcallback
	.p2align	4, 0x90
_hv_fcopy_onchannelcallback:            ## @hv_fcopy_onchannelcallback
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_fcopy_transaction@GOTPCREL(%rip), %r12
	movq	(%r12), %rax
	movq	_HVUTIL_READY@GOTPCREL(%rip), %r13
	cmpq	(%r13), %rax
	jg	LBB0_9
## %bb.1:
	movq	%rdi, %r14
	movq	_recv_buffer@GOTPCREL(%rip), %r15
	movq	(%r15), %rsi
	movq	_PAGE_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	addl	%edx, %edx
	leaq	-56(%rbp), %rcx
	leaq	-44(%rbp), %r8
	callq	_vmbus_recvpacket
	movq	-56(%rbp), %rax
	testq	%rax, %rax
	jle	LBB0_9
## %bb.2:
	movq	(%r15), %rbx
	movq	16(%rbx), %rcx
	movq	_ICMSGTYPE_NEGOTIATE@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jne	LBB0_6
## %bb.3:
	leaq	16(%rbx), %rdi
	movq	_fw_versions@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_FW_VER_COUNT@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	_fcopy_versions@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	movq	_FCOPY_VER_COUNT@GOTPCREL(%rip), %rax
	movl	(%rax), %r9d
	leaq	-48(%rbp), %rax
	movq	%rbx, %rsi
	pushq	%rax
	pushq	$0
	callq	_vmbus_prep_negotiate_resp
	addq	$16, %rsp
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	movl	-48(%rbp), %esi
	movzwl	%si, %edx
	sarl	$16, %esi
	leaq	L_.str(%rip), %rdi
	callq	_pr_info
LBB0_5:
	movq	_ICMSGHDRFLAG_TRANSACTION@GOTPCREL(%rip), %rax
	movq	_ICMSGHDRFLAG_RESPONSE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	movl	%ecx, 24(%rbx)
	movq	(%r15), %rsi
	movq	-56(%rbp), %rdx
	movl	-44(%rbp), %ecx
	movq	_VM_PKT_DATA_INBAND@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	movq	%r14, %rdi
	xorl	%r9d, %r9d
	callq	_vmbus_sendpacket
	jmp	LBB0_9
LBB0_6:
	addq	$80, %rbx
	movq	%rax, 24(%r12)
	movl	-44(%rbp), %eax
	movl	%eax, 16(%r12)
	movq	%rbx, 8(%r12)
	movq	(%r12), %rax
	cmpq	(%r13), %rax
	jge	LBB0_8
## %bb.7:
	movq	_HV_E_FAIL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_fcopy_respond_to_host
	jmp	LBB0_9
LBB0_8:
	movq	_HVUTIL_HOSTMSG_RECEIVED@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, (%r12)
	movq	_fcopy_send_work@GOTPCREL(%rip), %rdi
	callq	_schedule_work
	movq	_HV_UTIL_TIMEOUT@GOTPCREL(%rip), %rax
	movq	_HZ@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	imull	(%rax), %esi
	movq	_fcopy_timeout_work@GOTPCREL(%rip), %rdi
	callq	_schedule_delayed_work
LBB0_9:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_fcopy_transaction,32,3         ## @fcopy_transaction
	.comm	_HVUTIL_READY,8,3               ## @HVUTIL_READY
	.comm	_recv_buffer,8,3                ## @recv_buffer
	.comm	_PAGE_SIZE,4,2                  ## @PAGE_SIZE
	.comm	_ICMSGTYPE_NEGOTIATE,8,3        ## @ICMSGTYPE_NEGOTIATE
	.comm	_fw_versions,4,2                ## @fw_versions
	.comm	_FW_VER_COUNT,4,2               ## @FW_VER_COUNT
	.comm	_fcopy_versions,4,2             ## @fcopy_versions
	.comm	_FCOPY_VER_COUNT,4,2            ## @FCOPY_VER_COUNT
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"FCopy IC version %d.%d\n"

	.comm	_HV_E_FAIL,4,2                  ## @HV_E_FAIL
	.comm	_HVUTIL_HOSTMSG_RECEIVED,8,3    ## @HVUTIL_HOSTMSG_RECEIVED
	.comm	_fcopy_send_work,4,2            ## @fcopy_send_work
	.comm	_fcopy_timeout_work,4,2         ## @fcopy_timeout_work
	.comm	_HV_UTIL_TIMEOUT,4,2            ## @HV_UTIL_TIMEOUT
	.comm	_HZ,4,2                         ## @HZ
	.comm	_ICMSGHDRFLAG_TRANSACTION,4,2   ## @ICMSGHDRFLAG_TRANSACTION
	.comm	_ICMSGHDRFLAG_RESPONSE,4,2      ## @ICMSGHDRFLAG_RESPONSE
	.comm	_VM_PKT_DATA_INBAND,4,2         ## @VM_PKT_DATA_INBAND
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_hv_fcopy_onchannelcallback     ; -- Begin function hv_fcopy_onchannelcallback
	.p2align	2
_hv_fcopy_onchannelcallback:            ; @hv_fcopy_onchannelcallback
	.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
Lloh0:
	adrp	x22, _fcopy_transaction@GOTPAGE
Lloh1:
	ldr	x22, [x22, _fcopy_transaction@GOTPAGEOFF]
	ldr	x8, [x22]
Lloh2:
	adrp	x23, _HVUTIL_READY@GOTPAGE
Lloh3:
	ldr	x23, [x23, _HVUTIL_READY@GOTPAGEOFF]
	ldr	x9, [x23]
	cmp	x8, x9
	b.gt	LBB0_9
; %bb.1:
	mov	x19, x0
Lloh4:
	adrp	x21, _recv_buffer@GOTPAGE
Lloh5:
	ldr	x21, [x21, _recv_buffer@GOTPAGEOFF]
	ldr	x1, [x21]
Lloh6:
	adrp	x8, _PAGE_SIZE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _PAGE_SIZE@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	lsl	w2, w8, #1
	add	x3, sp, #8
	add	x4, sp, #4
	bl	_vmbus_recvpacket
	ldr	x8, [sp, #8]
	cmp	x8, #1
	b.lt	LBB0_9
; %bb.2:
	ldr	x20, [x21]
	mov	x0, x20
	ldr	x9, [x0, #16]!
Lloh9:
	adrp	x10, _ICMSGTYPE_NEGOTIATE@GOTPAGE
Lloh10:
	ldr	x10, [x10, _ICMSGTYPE_NEGOTIATE@GOTPAGEOFF]
Lloh11:
	ldr	x10, [x10]
	cmp	x9, x10
	b.ne	LBB0_6
; %bb.3:
Lloh12:
	adrp	x8, _fw_versions@GOTPAGE
Lloh13:
	ldr	x8, [x8, _fw_versions@GOTPAGEOFF]
Lloh14:
	ldr	w2, [x8]
Lloh15:
	adrp	x8, _FW_VER_COUNT@GOTPAGE
Lloh16:
	ldr	x8, [x8, _FW_VER_COUNT@GOTPAGEOFF]
Lloh17:
	ldr	w3, [x8]
Lloh18:
	adrp	x8, _fcopy_versions@GOTPAGE
Lloh19:
	ldr	x8, [x8, _fcopy_versions@GOTPAGEOFF]
Lloh20:
	ldr	w4, [x8]
Lloh21:
	adrp	x8, _FCOPY_VER_COUNT@GOTPAGE
Lloh22:
	ldr	x8, [x8, _FCOPY_VER_COUNT@GOTPAGEOFF]
Lloh23:
	ldr	w5, [x8]
	mov	x7, sp
	mov	x1, x20
	mov	x6, #0
	bl	_vmbus_prep_negotiate_resp
	cbz	x0, LBB0_5
; %bb.4:
	ldr	w8, [sp]
	asr	w1, w8, #16
	and	w2, w8, #0xffff
Lloh24:
	adrp	x0, l_.str@PAGE
Lloh25:
	add	x0, x0, l_.str@PAGEOFF
	bl	_pr_info
LBB0_5:
Lloh26:
	adrp	x8, _ICMSGHDRFLAG_TRANSACTION@GOTPAGE
Lloh27:
	ldr	x8, [x8, _ICMSGHDRFLAG_TRANSACTION@GOTPAGEOFF]
Lloh28:
	ldr	w8, [x8]
Lloh29:
	adrp	x9, _ICMSGHDRFLAG_RESPONSE@GOTPAGE
Lloh30:
	ldr	x9, [x9, _ICMSGHDRFLAG_RESPONSE@GOTPAGEOFF]
Lloh31:
	ldr	w9, [x9]
	orr	w8, w9, w8
	str	w8, [x20, #24]
	ldr	x1, [x21]
	ldr	x2, [sp, #8]
	ldr	w3, [sp, #4]
Lloh32:
	adrp	x8, _VM_PKT_DATA_INBAND@GOTPAGE
Lloh33:
	ldr	x8, [x8, _VM_PKT_DATA_INBAND@GOTPAGEOFF]
Lloh34:
	ldr	w4, [x8]
	mov	x0, x19
	mov	w5, #0
	bl	_vmbus_sendpacket
	b	LBB0_9
LBB0_6:
	add	x9, x20, #80
	str	x8, [x22, #24]
	ldr	w8, [sp, #4]
	str	w8, [x22, #16]
	str	x9, [x22, #8]
	ldr	x8, [x22]
	ldr	x9, [x23]
	cmp	x8, x9
	b.ge	LBB0_8
; %bb.7:
Lloh35:
	adrp	x8, _HV_E_FAIL@GOTPAGE
Lloh36:
	ldr	x8, [x8, _HV_E_FAIL@GOTPAGEOFF]
Lloh37:
	ldr	w0, [x8]
	bl	_fcopy_respond_to_host
	b	LBB0_9
LBB0_8:
Lloh38:
	adrp	x8, _HVUTIL_HOSTMSG_RECEIVED@GOTPAGE
Lloh39:
	ldr	x8, [x8, _HVUTIL_HOSTMSG_RECEIVED@GOTPAGEOFF]
Lloh40:
	ldr	x8, [x8]
	str	x8, [x22]
Lloh41:
	adrp	x0, _fcopy_send_work@GOTPAGE
Lloh42:
	ldr	x0, [x0, _fcopy_send_work@GOTPAGEOFF]
	bl	_schedule_work
Lloh43:
	adrp	x8, _HV_UTIL_TIMEOUT@GOTPAGE
Lloh44:
	ldr	x8, [x8, _HV_UTIL_TIMEOUT@GOTPAGEOFF]
Lloh45:
	ldr	w8, [x8]
Lloh46:
	adrp	x9, _HZ@GOTPAGE
Lloh47:
	ldr	x9, [x9, _HZ@GOTPAGEOFF]
Lloh48:
	ldr	w9, [x9]
	mul	w1, w9, w8
Lloh49:
	adrp	x0, _fcopy_timeout_work@GOTPAGE
Lloh50:
	ldr	x0, [x0, _fcopy_timeout_work@GOTPAGEOFF]
	bl	_schedule_delayed_work
LBB0_9:
	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
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGot	Lloh49, Lloh50
	.loh AdrpLdrGotLdr	Lloh46, Lloh47, Lloh48
	.loh AdrpLdrGotLdr	Lloh43, Lloh44, Lloh45
	.loh AdrpLdrGot	Lloh41, Lloh42
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh40
	.cfi_endproc
                                        ; -- End function
	.comm	_fcopy_transaction,32,3         ; @fcopy_transaction
	.comm	_HVUTIL_READY,8,3               ; @HVUTIL_READY
	.comm	_recv_buffer,8,3                ; @recv_buffer
	.comm	_PAGE_SIZE,4,2                  ; @PAGE_SIZE
	.comm	_ICMSGTYPE_NEGOTIATE,8,3        ; @ICMSGTYPE_NEGOTIATE
	.comm	_fw_versions,4,2                ; @fw_versions
	.comm	_FW_VER_COUNT,4,2               ; @FW_VER_COUNT
	.comm	_fcopy_versions,4,2             ; @fcopy_versions
	.comm	_FCOPY_VER_COUNT,4,2            ; @FCOPY_VER_COUNT
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"FCopy IC version %d.%d\n"

	.comm	_HV_E_FAIL,4,2                  ; @HV_E_FAIL
	.comm	_HVUTIL_HOSTMSG_RECEIVED,8,3    ; @HVUTIL_HOSTMSG_RECEIVED
	.comm	_fcopy_send_work,4,2            ; @fcopy_send_work
	.comm	_fcopy_timeout_work,4,2         ; @fcopy_timeout_work
	.comm	_HV_UTIL_TIMEOUT,4,2            ; @HV_UTIL_TIMEOUT
	.comm	_HZ,4,2                         ; @HZ
	.comm	_ICMSGHDRFLAG_TRANSACTION,4,2   ; @ICMSGHDRFLAG_TRANSACTION
	.comm	_ICMSGHDRFLAG_RESPONSE,4,2      ; @ICMSGHDRFLAG_RESPONSE
	.comm	_VM_PKT_DATA_INBAND,4,2         ; @VM_PKT_DATA_INBAND
.subsections_via_symbols
