	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function netvsc_destroy_recv_buf
_netvsc_destroy_recv_buf:               ## @netvsc_destroy_recv_buf
	.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	%rdi, %rbx
	movq	56(%rdi), %r14
	cmpq	$0, 8(%rdi)
	je	LBB0_4
## %bb.1:
	leaq	48(%rbx), %r15
	movq	%r15, %rdi
	xorl	%esi, %esi
	movl	$8, %edx
	callq	_memset
	movq	_NVSP_MSG1_TYPE_REVOKE_RECV_BUF@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 52(%rbx)
	movq	_NETVSC_RECEIVE_BUFFER_ID@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 48(%rbx)
	movq	40(%rbx), %rax
	movl	(%rax), %edi
	movq	_VM_PKT_DATA_INBAND@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	movq	%r15, %rsi
	movl	$8, %edx
	movq	%r15, %rcx
	xorl	%r9d, %r9d
	callq	_vmbus_sendpacket
	testl	%eax, %eax
	je	LBB0_4
## %bb.2:
	movl	%eax, %r15d
	leaq	L_.str(%rip), %rsi
	jmp	LBB0_3
LBB0_4:
	movq	32(%rbx), %rsi
	testq	%rsi, %rsi
	je	LBB0_8
## %bb.5:
	movq	40(%rbx), %rax
	movl	(%rax), %edi
	callq	_vmbus_teardown_gpadl
	testl	%eax, %eax
	je	LBB0_7
## %bb.6:
	movl	%eax, %r15d
	leaq	L_.str.1(%rip), %rsi
LBB0_3:
	movq	%r14, %rdi
	callq	_netdev_err
	jmp	LBB0_12
LBB0_7:
	movq	$0, 32(%rbx)
LBB0_8:
	movq	16(%rbx), %r14
	testq	%r14, %r14
	je	LBB0_10
## %bb.9:
	movl	24(%rbx), %edi
	callq	_get_order
	movq	%r14, %rdi
	movl	%eax, %esi
	callq	_free_pages
	movq	$0, 16(%rbx)
LBB0_10:
	movq	(%rbx), %rdi
	xorl	%r15d, %r15d
	testq	%rdi, %rdi
	je	LBB0_12
## %bb.11:
	movq	$0, 8(%rbx)
	callq	_kfree
	movq	$0, (%rbx)
LBB0_12:
	movl	%r15d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_NVSP_MSG1_TYPE_REVOKE_RECV_BUF,4,2 ## @NVSP_MSG1_TYPE_REVOKE_RECV_BUF
	.comm	_NETVSC_RECEIVE_BUFFER_ID,4,2   ## @NETVSC_RECEIVE_BUFFER_ID
	.comm	_VM_PKT_DATA_INBAND,4,2         ## @VM_PKT_DATA_INBAND
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"unable to send revoke receive buffer to netvsp\n"

L_.str.1:                               ## @.str.1
	.asciz	"unable to teardown receive buffer's gpadl\n"

	.no_dead_strip	_netvsc_destroy_recv_buf
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function netvsc_destroy_recv_buf
_netvsc_destroy_recv_buf:               ; @netvsc_destroy_recv_buf
	.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
	ldr	x20, [x0, #56]
	ldr	x8, [x0, #8]
	cbz	x8, LBB0_3
; %bb.1:
	add	x21, x19, #48
	mov	x0, x21
	mov	w1, #0
	mov	w2, #8
	bl	_memset
Lloh0:
	adrp	x8, _NVSP_MSG1_TYPE_REVOKE_RECV_BUF@GOTPAGE
Lloh1:
	ldr	x8, [x8, _NVSP_MSG1_TYPE_REVOKE_RECV_BUF@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, _NETVSC_RECEIVE_BUFFER_ID@GOTPAGE
Lloh4:
	ldr	x9, [x9, _NETVSC_RECEIVE_BUFFER_ID@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	stp	w9, w8, [x19, #48]
	ldr	x8, [x19, #40]
	ldr	w0, [x8]
Lloh6:
	adrp	x8, _VM_PKT_DATA_INBAND@GOTPAGE
Lloh7:
	ldr	x8, [x8, _VM_PKT_DATA_INBAND@GOTPAGEOFF]
Lloh8:
	ldr	w4, [x8]
	mov	x1, x21
	mov	w2, #8
	mov	x3, x21
	mov	w5, #0
	bl	_vmbus_sendpacket
	cbz	w0, LBB0_3
; %bb.2:
	mov	x21, x0
Lloh9:
	adrp	x1, l_.str@PAGE
Lloh10:
	add	x1, x1, l_.str@PAGEOFF
	b	LBB0_6
LBB0_3:
	ldr	x1, [x19, #32]
	cbz	x1, LBB0_8
; %bb.4:
	ldr	x8, [x19, #40]
	ldr	w0, [x8]
	bl	_vmbus_teardown_gpadl
	cbz	w0, LBB0_7
; %bb.5:
	mov	x21, x0
Lloh11:
	adrp	x1, l_.str.1@PAGE
Lloh12:
	add	x1, x1, l_.str.1@PAGEOFF
LBB0_6:
	mov	x0, x20
	bl	_netdev_err
	b	LBB0_13
LBB0_7:
	str	xzr, [x19, #32]
LBB0_8:
	ldr	x20, [x19, #16]
	cbz	x20, LBB0_10
; %bb.9:
	ldr	w0, [x19, #24]
	bl	_get_order
	mov	x1, x0
	mov	x0, x20
	bl	_free_pages
	str	xzr, [x19, #16]
LBB0_10:
	ldr	x0, [x19]
	cbz	x0, LBB0_12
; %bb.11:
	str	xzr, [x19, #8]
	bl	_kfree
	mov	w21, #0
	str	xzr, [x19]
	b	LBB0_13
LBB0_12:
	mov	w21, #0
LBB0_13:
	mov	x0, x21
	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 AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_NVSP_MSG1_TYPE_REVOKE_RECV_BUF,4,2 ; @NVSP_MSG1_TYPE_REVOKE_RECV_BUF
	.comm	_NETVSC_RECEIVE_BUFFER_ID,4,2   ; @NETVSC_RECEIVE_BUFFER_ID
	.comm	_VM_PKT_DATA_INBAND,4,2         ; @VM_PKT_DATA_INBAND
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"unable to send revoke receive buffer to netvsp\n"

l_.str.1:                               ; @.str.1
	.asciz	"unable to teardown receive buffer's gpadl\n"

	.no_dead_strip	_netvsc_destroy_recv_buf
.subsections_via_symbols
