	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function lan743x_rx_ring_init
_lan743x_rx_ring_init:                  ## @lan743x_rx_ring_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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	$0, -32(%rbp)
	movq	_LAN743X_RX_RING_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	%edi, (%r14)
	cmpl	$1, %edi
	jle	LBB0_1
## %bb.3:
	movq	_RX_CFG_B_RX_RING_LEN_MASK_@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	notl	%eax
	testl	%eax, %edi
	je	LBB0_4
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rax
LBB0_2:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_15:
	movq	%r14, %rdi
	callq	_lan743x_rx_ring_cleanup
LBB0_16:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	shll	$2, %edi
	movq	_PAGE_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_ALIGN
	movq	%rax, %rbx
	movq	$0, -32(%rbp)
	movq	40(%r14), %rax
	movl	(%rax), %edi
	leaq	-32(%rbp), %rdx
	movl	%ebx, %esi
	callq	_pci_zalloc_consistent
	testq	%rax, %rax
	je	LBB0_5
## %bb.6:
	movq	%rbx, 8(%r14)
	movq	%rax, 64(%r14)
	movq	-32(%rbp), %rax
	movq	%rax, 56(%r14)
	movl	(%r14), %edi
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	$4, %esi
	callq	_kcalloc
	testq	%rax, %rax
	je	LBB0_5
## %bb.7:
	movq	%rax, 48(%r14)
	movq	$0, -32(%rbp)
	movq	40(%r14), %rax
	movl	(%rax), %edi
	leaq	-32(%rbp), %rdx
	movl	$1, %esi
	callq	_pci_zalloc_consistent
	testq	%rax, %rax
	je	LBB0_5
## %bb.8:
	movq	%rax, 32(%r14)
	movl	-32(%rbp), %eax
	movl	%eax, 16(%r14)
	testb	$3, %al
	je	LBB0_9
LBB0_5:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	jmp	LBB0_2
LBB0_9:
	movq	$0, 24(%r14)
	cmpl	$0, (%r14)
	jle	LBB0_10
## %bb.11:
	xorl	%r15d, %r15d
LBB0_13:                                ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	callq	_lan743x_rx_allocate_skb
	movq	%r14, %rdi
	movl	%r15d, %esi
	movq	%rax, %rdx
	callq	_lan743x_rx_init_ring_element
	testl	%eax, %eax
	jne	LBB0_14
## %bb.12:                              ##   in Loop: Header=BB0_13 Depth=1
	incl	%r15d
	xorl	%ebx, %ebx
	cmpl	(%r14), %r15d
	jl	LBB0_13
	jmp	LBB0_16
LBB0_10:
	xorl	%ebx, %ebx
	jmp	LBB0_16
LBB0_14:
	movl	%eax, %ebx
	jmp	LBB0_15
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_LAN743X_RX_RING_SIZE,4,2       ## @LAN743X_RX_RING_SIZE
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_RX_CFG_B_RX_RING_LEN_MASK_,4,2 ## @RX_CFG_B_RX_RING_LEN_MASK_
	.comm	_PAGE_SIZE,4,2                  ## @PAGE_SIZE
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.no_dead_strip	_lan743x_rx_ring_init
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function lan743x_rx_ring_init
_lan743x_rx_ring_init:                  ; @lan743x_rx_ring_init
	.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
	str	xzr, [sp, #8]
Lloh0:
	adrp	x8, _LAN743X_RX_RING_SIZE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _LAN743X_RX_RING_SIZE@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	str	w8, [x0]
	cmp	w8, #1
	b.le	LBB0_2
; %bb.1:
Lloh3:
	adrp	x9, _RX_CFG_B_RX_RING_LEN_MASK_@GOTPAGE
Lloh4:
	ldr	x9, [x9, _RX_CFG_B_RX_RING_LEN_MASK_@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	bics	wzr, w8, w9
	b.eq	LBB0_6
LBB0_2:
Lloh6:
	adrp	x8, _EINVAL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_3:
	ldr	w8, [x8]
	neg	w20, w8
LBB0_4:
	mov	x0, x19
	bl	_lan743x_rx_ring_cleanup
LBB0_5:
	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_6:
	lsl	w0, w8, #2
Lloh8:
	adrp	x8, _PAGE_SIZE@GOTPAGE
Lloh9:
	ldr	x8, [x8, _PAGE_SIZE@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
	bl	_ALIGN
	mov	x20, x0
	str	xzr, [sp, #8]
	ldr	x8, [x19, #40]
	ldr	w0, [x8]
	add	x2, sp, #8
	mov	x1, x20
	bl	_pci_zalloc_consistent
	cbz	x0, LBB0_10
; %bb.7:
	str	x20, [x19, #8]
	ldr	x8, [sp, #8]
	stp	x8, x0, [x19, #56]
	ldr	w0, [x19]
Lloh11:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh12:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh13:
	ldr	w2, [x8]
	mov	w1, #4
	bl	_kcalloc
	cbz	x0, LBB0_10
; %bb.8:
	str	x0, [x19, #48]
	str	xzr, [sp, #8]
	ldr	x8, [x19, #40]
	ldr	w0, [x8]
	add	x2, sp, #8
	mov	w1, #1
	bl	_pci_zalloc_consistent
	cbz	x0, LBB0_10
; %bb.9:
	str	x0, [x19, #32]
	ldr	w8, [sp, #8]
	str	w8, [x19, #16]
	tst	w8, #0x3
	b.eq	LBB0_11
LBB0_10:
Lloh14:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_3
LBB0_11:
	str	xzr, [x19, #24]
	ldr	w8, [x19]
	cmp	w8, #1
	b.lt	LBB0_15
; %bb.12:
	mov	w21, #0
LBB0_13:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	bl	_lan743x_rx_allocate_skb
	mov	x2, x0
	mov	x0, x19
	mov	x1, x21
	bl	_lan743x_rx_init_ring_element
	mov	x20, x0
	cbnz	w0, LBB0_4
; %bb.14:                               ;   in Loop: Header=BB0_13 Depth=1
	add	w21, w21, #1
	ldr	w8, [x19]
	cmp	w21, w8
	b.lt	LBB0_13
	b	LBB0_5
LBB0_15:
	mov	w20, #0
	b	LBB0_5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_LAN743X_RX_RING_SIZE,4,2       ; @LAN743X_RX_RING_SIZE
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_RX_CFG_B_RX_RING_LEN_MASK_,4,2 ; @RX_CFG_B_RX_RING_LEN_MASK_
	.comm	_PAGE_SIZE,4,2                  ; @PAGE_SIZE
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.no_dead_strip	_lan743x_rx_ring_init
.subsections_via_symbols
