	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_xenvif_map_frontend_data_rings ## -- Begin function xenvif_map_frontend_data_rings
	.p2align	4, 0x90
_xenvif_map_frontend_data_rings:        ## @xenvif_map_frontend_data_rings
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movl	%esi, -40(%rbp)
	movl	%edx, -36(%rbp)
	movl	4(%rdi), %edi
	callq	_xenvif_to_xenbus_device
	leaq	-40(%rbp), %rsi
	leaq	-32(%rbp), %rcx
	movl	%eax, %edi
	movl	$1, %edx
	callq	_xenbus_map_ring_valloc
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_3
## %bb.1:
	movq	-32(%rbp), %rsi
	leaq	8(%r14), %rdi
	movq	_XEN_PAGE_SIZE@GOTPCREL(%rip), %r15
	movl	(%r15), %edx
	callq	_BACK_RING_INIT
	movl	4(%r14), %edi
	callq	_xenvif_to_xenbus_device
	leaq	-36(%rbp), %rsi
	leaq	-32(%rbp), %rcx
	movl	%eax, %edi
	movl	$1, %edx
	callq	_xenbus_map_ring_valloc
	movl	%eax, %ebx
	testl	%eax, %eax
	je	LBB0_2
LBB0_3:
	movq	%r14, %rdi
	callq	_xenvif_unmap_frontend_data_rings
LBB0_4:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_2:
	movq	-32(%rbp), %rsi
	movl	(%r15), %edx
	movq	%r14, %rdi
	callq	_BACK_RING_INIT
	xorl	%ebx, %ebx
	jmp	LBB0_4
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_XEN_PAGE_SIZE,4,2              ## @XEN_PAGE_SIZE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_xenvif_map_frontend_data_rings ; -- Begin function xenvif_map_frontend_data_rings
	.p2align	2
_xenvif_map_frontend_data_rings:        ; @xenvif_map_frontend_data_rings
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	stp	w2, w1, [sp, #8]
	ldr	w0, [x0, #4]
	bl	_xenvif_to_xenbus_device
	add	x1, sp, #12
	mov	x3, sp
	mov	w2, #1
	bl	_xenbus_map_ring_valloc
	mov	x20, x0
	cbnz	w0, LBB0_2
; %bb.1:
	ldr	x1, [sp]
	add	x0, x19, #8
Lloh0:
	adrp	x21, _XEN_PAGE_SIZE@GOTPAGE
Lloh1:
	ldr	x21, [x21, _XEN_PAGE_SIZE@GOTPAGEOFF]
	ldr	w2, [x21]
	bl	_BACK_RING_INIT
	ldr	w0, [x19, #4]
	bl	_xenvif_to_xenbus_device
	add	x1, sp, #8
	mov	x3, sp
	mov	w2, #1
	bl	_xenbus_map_ring_valloc
	mov	x20, x0
	cbz	w0, LBB0_4
LBB0_2:
	mov	x0, x19
	bl	_xenvif_unmap_frontend_data_rings
LBB0_3:
	mov	x0, x20
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
LBB0_4:
	ldr	x1, [sp]
	ldr	w2, [x21]
	mov	x0, x19
	bl	_BACK_RING_INIT
	b	LBB0_3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_XEN_PAGE_SIZE,4,2              ; @XEN_PAGE_SIZE
.subsections_via_symbols
