	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function xgbe_alloc_pages
_xgbe_alloc_pages:                      ## @xgbe_alloc_pages
	.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
	movl	%ecx, %r13d
	movl	%edx, %r12d
	movq	%rsi, -48(%rbp)                 ## 8-byte Spill
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	jmp	LBB0_1
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_1 Depth=1
	movq	_NUMA_NO_NODE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	cmpl	%eax, %r13d
	movl	%eax, %r13d
	je	LBB0_6
LBB0_1:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_3 Depth 2
	testl	%r12d, %r12d
	js	LBB0_5
## %bb.2:                               ##   in Loop: Header=BB0_1 Depth=1
	movq	___GFP_COMP@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movq	_GFP_ATOMIC@GOTPCREL(%rip), %rax
	orl	(%rax), %r15d
	movq	___GFP_NOWARN@GOTPCREL(%rip), %rax
	orl	(%rax), %r15d
	movl	%r12d, %ebx
	.p2align	4, 0x90
LBB0_3:                                 ##   Parent Loop BB0_1 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	%r13d, %edi
	movl	%r15d, %esi
	movl	%ebx, %edx
	callq	_alloc_pages_node
	testq	%rax, %rax
	jne	LBB0_7
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=2
	leal	-1(%rbx), %eax
	testl	%ebx, %ebx
	movl	%eax, %ebx
	jg	LBB0_3
	jmp	LBB0_5
LBB0_7:
	movq	%rax, %r14
	movq	_PAGE_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%ebx, %ecx
	shll	%cl, %eax
	movq	-56(%rbp), %r13                 ## 8-byte Reload
	movl	(%r13), %edi
	movq	_DMA_FROM_DEVICE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r8d
	xorl	%r12d, %r12d
	movq	%r14, %rsi
	xorl	%edx, %edx
	movl	%eax, %ecx
	callq	_dma_map_page
	movl	%eax, %r15d
	movl	(%r13), %edi
	movl	%eax, %esi
	callq	_dma_mapping_error
	testq	%rax, %rax
	je	LBB0_9
## %bb.8:
	movq	%r14, %rdi
	callq	_put_page
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	subl	(%rax), %r12d
	jmp	LBB0_10
LBB0_9:
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	movq	%r14, 16(%rdx)
	movq	_PAGE_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%ebx, %ecx
	shll	%cl, %eax
	movl	%eax, (%rdx)
	movq	$0, 8(%rdx)
	movl	%r15d, 4(%rdx)
LBB0_10:
	movl	%r12d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r12d, %r12d
	subl	(%rax), %r12d
	jmp	LBB0_10
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_ATOMIC,4,2                 ## @GFP_ATOMIC
	.comm	___GFP_COMP,4,2                 ## @__GFP_COMP
	.comm	___GFP_NOWARN,4,2               ## @__GFP_NOWARN
	.comm	_NUMA_NO_NODE,4,2               ## @NUMA_NO_NODE
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_PAGE_SIZE,4,2                  ## @PAGE_SIZE
	.comm	_DMA_FROM_DEVICE,4,2            ## @DMA_FROM_DEVICE
	.no_dead_strip	_xgbe_alloc_pages
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function xgbe_alloc_pages
_xgbe_alloc_pages:                      ; @xgbe_alloc_pages
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x23, x3
	mov	x22, x2
	mov	x19, x1
	mov	x20, x0
Lloh0:
	adrp	x27, ___GFP_COMP@GOTPAGE
Lloh1:
	ldr	x27, [x27, ___GFP_COMP@GOTPAGEOFF]
Lloh2:
	adrp	x28, ___GFP_NOWARN@GOTPAGE
Lloh3:
	ldr	x28, [x28, ___GFP_NOWARN@GOTPAGEOFF]
Lloh4:
	adrp	x26, _NUMA_NO_NODE@GOTPAGE
Lloh5:
	ldr	x26, [x26, _NUMA_NO_NODE@GOTPAGEOFF]
	b	LBB0_2
LBB0_1:                                 ;   in Loop: Header=BB0_2 Depth=1
	ldr	w8, [x26]
	cmp	w23, w8
	mov	x23, x8
	b.eq	LBB0_8
LBB0_2:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_4 Depth 2
	tbnz	w22, #31, LBB0_1
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
Lloh6:
	adrp	x8, _GFP_ATOMIC@GOTPAGE
Lloh7:
	ldr	x8, [x8, _GFP_ATOMIC@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	ldr	w9, [x27]
	orr	w8, w9, w8
	ldr	w9, [x28]
	orr	w25, w8, w9
	mov	x21, x22
LBB0_4:                                 ;   Parent Loop BB0_2 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	mov	x0, x23
	mov	x1, x25
	mov	x2, x21
	bl	_alloc_pages_node
	cbnz	x0, LBB0_6
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=2
	sub	w8, w21, #1
	cmp	w21, #0
	mov	x21, x8
	b.gt	LBB0_4
	b	LBB0_1
LBB0_6:
	mov	x24, x0
Lloh9:
	adrp	x23, _PAGE_SIZE@GOTPAGE
Lloh10:
	ldr	x23, [x23, _PAGE_SIZE@GOTPAGEOFF]
	ldr	w0, [x20]
	ldr	w8, [x23]
	lsl	w3, w8, w21
Lloh11:
	adrp	x8, _DMA_FROM_DEVICE@GOTPAGE
Lloh12:
	ldr	x8, [x8, _DMA_FROM_DEVICE@GOTPAGEOFF]
Lloh13:
	ldr	w4, [x8]
	mov	x1, x24
	mov	w2, #0
	bl	_dma_map_page
	mov	x22, x0
	ldr	w0, [x20]
	mov	x1, x22
	bl	_dma_mapping_error
	cbz	x0, LBB0_9
; %bb.7:
	mov	x0, x24
	bl	_put_page
LBB0_8:
Lloh14:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_10
LBB0_9:
	ldr	w8, [x23]
	lsl	w8, w8, w21
	stp	xzr, x24, [x19, #8]
	stp	w8, w22, [x19]
LBB0_10:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_ATOMIC,4,2                 ; @GFP_ATOMIC
	.comm	___GFP_COMP,4,2                 ; @__GFP_COMP
	.comm	___GFP_NOWARN,4,2               ; @__GFP_NOWARN
	.comm	_NUMA_NO_NODE,4,2               ; @NUMA_NO_NODE
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_PAGE_SIZE,4,2                  ; @PAGE_SIZE
	.comm	_DMA_FROM_DEVICE,4,2            ; @DMA_FROM_DEVICE
	.no_dead_strip	_xgbe_alloc_pages
.subsections_via_symbols
