	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function vmbus_bus_init
_vmbus_bus_init:                        ## @vmbus_bus_init
	.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	%edi, %r14d
	xorl	%eax, %eax
	callq	_hv_init
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	movl	%eax, %ebx
	leaq	L_.str(%rip), %rdi
	movl	%eax, %esi
	callq	_pr_err
	jmp	LBB0_11
LBB0_2:
	movq	_vmbus_on_msg_dpc@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_msg_dpc@GOTPCREL(%rip), %rdi
	xorl	%edx, %edx
	callq	_tasklet_init
	movq	_hv_bus@GOTPCREL(%rip), %rdi
	callq	_bus_register
	movl	%eax, %r15d
	testl	%eax, %eax
	jne	LBB0_10
## %bb.3:
	movq	_vmbus_isr@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	movq	_driver_name@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	_hv_acpi_dev@GOTPCREL(%rip), %r12
	movl	(%r12), %r8d
	movl	%r14d, %edi
	xorl	%edx, %edx
	callq	_request_irq
	testl	%eax, %eax
	je	LBB0_5
## %bb.4:
	movl	%eax, %r15d
	leaq	L_.str.1(%rip), %rdi
	movl	%r14d, %esi
	callq	_pr_err
	jmp	LBB0_9
LBB0_5:
	movq	_vmbus_flow_handler@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%r14d, %edi
	callq	_set_irq_handler
	movl	(%rbx), %esi
	movl	%r14d, %edi
	callq	_hv_register_vmbus_handler
	xorl	%eax, %eax
	callq	_hv_synic_alloc
	movl	%eax, %r15d
	testl	%eax, %eax
	jne	LBB0_8
## %bb.6:
	movq	_hv_synic_init@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	xorl	%ebx, %ebx
	xorl	%esi, %esi
	movl	$1, %edx
	callq	_on_each_cpu
	xorl	%eax, %eax
	callq	_vmbus_connect
	movl	%eax, %r15d
	testl	%eax, %eax
	je	LBB0_7
LBB0_8:
	xorl	%eax, %eax
	callq	_hv_synic_free
	movl	(%r12), %esi
	movl	%r14d, %edi
	callq	_free_irq
LBB0_9:
	movq	_hv_bus@GOTPCREL(%rip), %rdi
	callq	_bus_unregister
LBB0_10:
	xorl	%eax, %eax
	callq	_hv_cleanup
	movl	%r15d, %ebx
LBB0_11:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	xorl	%eax, %eax
	callq	_vmbus_request_offers
	jmp	LBB0_11
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Unable to initialize the hypervisor - 0x%x\n"

	.comm	_msg_dpc,4,2                    ## @msg_dpc
	.comm	_vmbus_on_msg_dpc,4,2           ## @vmbus_on_msg_dpc
	.comm	_hv_bus,4,2                     ## @hv_bus
	.comm	_vmbus_isr,4,2                  ## @vmbus_isr
	.comm	_driver_name,4,2                ## @driver_name
	.comm	_hv_acpi_dev,4,2                ## @hv_acpi_dev
L_.str.1:                               ## @.str.1
	.asciz	"Unable to request IRQ %d\n"

	.comm	_vmbus_flow_handler,4,2         ## @vmbus_flow_handler
	.comm	_hv_synic_init,4,2              ## @hv_synic_init
	.no_dead_strip	_vmbus_bus_init
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function vmbus_bus_init
_vmbus_bus_init:                        ; @vmbus_bus_init
	.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, x0
	bl	_hv_init
	cbz	w0, LBB0_2
; %bb.1:
	mov	x20, x0
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x20
	bl	_pr_err
	b	LBB0_10
LBB0_2:
Lloh2:
	adrp	x8, _vmbus_on_msg_dpc@GOTPAGE
Lloh3:
	ldr	x8, [x8, _vmbus_on_msg_dpc@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
Lloh5:
	adrp	x0, _msg_dpc@GOTPAGE
Lloh6:
	ldr	x0, [x0, _msg_dpc@GOTPAGEOFF]
	mov	w2, #0
	bl	_tasklet_init
Lloh7:
	adrp	x0, _hv_bus@GOTPAGE
Lloh8:
	ldr	x0, [x0, _hv_bus@GOTPAGEOFF]
	bl	_bus_register
	mov	x20, x0
	cbnz	w0, LBB0_9
; %bb.3:
Lloh9:
	adrp	x22, _vmbus_isr@GOTPAGE
Lloh10:
	ldr	x22, [x22, _vmbus_isr@GOTPAGEOFF]
	ldr	w1, [x22]
Lloh11:
	adrp	x8, _driver_name@GOTPAGE
Lloh12:
	ldr	x8, [x8, _driver_name@GOTPAGEOFF]
Lloh13:
	ldr	w3, [x8]
Lloh14:
	adrp	x21, _hv_acpi_dev@GOTPAGE
Lloh15:
	ldr	x21, [x21, _hv_acpi_dev@GOTPAGEOFF]
	ldr	w4, [x21]
	mov	x0, x19
	mov	w2, #0
	bl	_request_irq
	cbz	w0, LBB0_5
; %bb.4:
	mov	x20, x0
Lloh16:
	adrp	x0, l_.str.1@PAGE
Lloh17:
	add	x0, x0, l_.str.1@PAGEOFF
	mov	x1, x19
	bl	_pr_err
	b	LBB0_8
LBB0_5:
Lloh18:
	adrp	x8, _vmbus_flow_handler@GOTPAGE
Lloh19:
	ldr	x8, [x8, _vmbus_flow_handler@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_set_irq_handler
	ldr	w1, [x22]
	mov	x0, x19
	bl	_hv_register_vmbus_handler
	bl	_hv_synic_alloc
	mov	x20, x0
	cbnz	w0, LBB0_7
; %bb.6:
Lloh21:
	adrp	x8, _hv_synic_init@GOTPAGE
Lloh22:
	ldr	x8, [x8, _hv_synic_init@GOTPAGEOFF]
Lloh23:
	ldr	w0, [x8]
	mov	x1, #0
	mov	w2, #1
	bl	_on_each_cpu
	bl	_vmbus_connect
	mov	x20, x0
	cbz	w0, LBB0_11
LBB0_7:
	bl	_hv_synic_free
	ldr	w1, [x21]
	mov	x0, x19
	bl	_free_irq
LBB0_8:
Lloh24:
	adrp	x0, _hv_bus@GOTPAGE
Lloh25:
	ldr	x0, [x0, _hv_bus@GOTPAGEOFF]
	bl	_bus_unregister
LBB0_9:
	bl	_hv_cleanup
LBB0_10:
	mov	x0, x20
	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:
	bl	_vmbus_request_offers
	b	LBB0_10
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh24, Lloh25
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Unable to initialize the hypervisor - 0x%x\n"

	.comm	_msg_dpc,4,2                    ; @msg_dpc
	.comm	_vmbus_on_msg_dpc,4,2           ; @vmbus_on_msg_dpc
	.comm	_hv_bus,4,2                     ; @hv_bus
	.comm	_vmbus_isr,4,2                  ; @vmbus_isr
	.comm	_driver_name,4,2                ; @driver_name
	.comm	_hv_acpi_dev,4,2                ; @hv_acpi_dev
l_.str.1:                               ; @.str.1
	.asciz	"Unable to request IRQ %d\n"

	.comm	_vmbus_flow_handler,4,2         ; @vmbus_flow_handler
	.comm	_hv_synic_init,4,2              ; @hv_synic_init
	.no_dead_strip	_vmbus_bus_init
.subsections_via_symbols
