	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function receive_packets
_receive_packets:                       ## @receive_packets
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	addq	$4, %rdi
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	callq	_spin_lock_irqsave
	cmpl	$0, (%r14)
	jle	LBB0_12
## %bb.1:
	leaq	8(%r14), %rax
	movq	%rax, -80(%rbp)                 ## 8-byte Spill
	xorl	%ebx, %ebx
	xorl	%r13d, %r13d
	movq	%r14, -64(%rbp)                 ## 8-byte Spill
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_11:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	-72(%rbp), %rbx                 ## 8-byte Reload
	incq	%rbx
	movq	-64(%rbp), %r14                 ## 8-byte Reload
	movslq	(%r14), %rax
	cmpq	%rax, %rbx
	jge	LBB0_12
LBB0_2:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_8 Depth 2
	testq	%rbx, %rbx
	je	LBB0_6
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	testq	%r13, %r13
	je	LBB0_6
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	cmpq	$0, 8(%r13)
	je	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	16(%r14), %rax
	movq	(%rax,%rbx,8), %rax
	movl	(%rax), %edi
	orl	$1, %edi
	callq	_cpu_to_le32
	movq	8(%r13), %rcx
	movq	%rax, (%rcx)
LBB0_6:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	16(%r14), %rax
	movq	%rbx, -72(%rbp)                 ## 8-byte Spill
	movq	(%rax,%rbx,8), %r13
	movq	_MAX_PACKETS@GOTPCREL(%rip), %r14
	movl	(%r14), %eax
	testl	%eax, %eax
	jle	LBB0_11
## %bb.7:                               ##   in Loop: Header=BB0_2 Depth=1
	xorl	%r12d, %r12d
	xorl	%r15d, %r15d
	xorl	%ebx, %ebx
	movq	%r13, -88(%rbp)                 ## 8-byte Spill
	jmp	LBB0_8
	.p2align	4, 0x90
LBB0_10:                                ##   in Loop: Header=BB0_8 Depth=2
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax,%r15), %rax
	addq	$16, %rax
	movq	-88(%rbp), %r13                 ## 8-byte Reload
	movq	%rax, 8(%r13)
	incq	%rbx
	movq	_MAX_PACKETS@GOTPCREL(%rip), %r14
	movslq	(%r14), %rax
	addq	$8, %r15
	addq	$4, %r12
	cmpq	%rax, %rbx
	jge	LBB0_11
LBB0_8:                                 ##   Parent Loop BB0_2 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	16(%r13), %rcx
	movq	%rcx, -48(%rbp)                 ## 8-byte Spill
	movl	(%r13), %ecx
	movq	%rcx, -96(%rbp)                 ## 8-byte Spill
	movslq	4(%r13), %rcx
	cltq
	imulq	%rcx, %rax
	leaq	(%r12,%rax,4), %rsi
	movq	-80(%rbp), %rdi                 ## 8-byte Reload
	callq	_dma_region_offset_to_bus
	movl	%eax, %ecx
	movl	(%r14), %esi
	movl	%esi, %edi
	shrl	$31, %edi
	addl	%esi, %edi
	sarl	%edi
	movl	%ebx, %eax
	cltd
	idivl	%edi
	testl	%edx, %edx
	sete	%al
	decl	%esi
	cmpq	%rsi, %rbx
	sete	%dl
	orb	%al, %dl
	movzbl	%dl, %esi
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	leaq	(%rax,%r15), %rdi
	movl	$512, %edx                      ## imm = 0x200
	callq	_fill_input_last
	movq	8(%r13), %r14
	testq	%r14, %r14
	je	LBB0_10
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=2
	movq	-96(%rbp), %rdi                 ## 8-byte Reload
	addl	%r15d, %edi
	orl	$1, %edi
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_cpu_to_le32
	movq	%rax, (%r14)
	jmp	LBB0_10
LBB0_12:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_spin_unlock_irqrestore         ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_MAX_PACKETS,4,2                ## @MAX_PACKETS
	.no_dead_strip	_receive_packets
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function receive_packets
_receive_packets:                       ; @receive_packets
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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	x19, x0
	add	x0, x0, #4
	str	x0, [sp]                        ; 8-byte Folded Spill
	bl	_spin_lock_irqsave
	ldr	w8, [x19]
	cmp	w8, #1
	b.lt	LBB0_12
; %bb.1:
	mov	x22, #0
	mov	x23, #0
	add	x21, x19, #8
Lloh0:
	adrp	x24, _MAX_PACKETS@GOTPAGE
Lloh1:
	ldr	x24, [x24, _MAX_PACKETS@GOTPAGEOFF]
	str	x19, [sp, #8]                   ; 8-byte Folded Spill
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x22, x22, #1
	ldr	x19, [sp, #8]                   ; 8-byte Folded Reload
	ldrsw	x8, [x19]
	cmp	x22, x8
	b.ge	LBB0_12
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_10 Depth 2
	cbz	x22, LBB0_7
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	cbz	x23, LBB0_7
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	x8, [x23, #8]
	cbz	x8, LBB0_7
; %bb.6:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	x8, [x19, #16]
	ldr	x8, [x8, x22, lsl #3]
	ldr	w8, [x8]
	orr	w0, w8, #0x1
	bl	_cpu_to_le32
	ldr	x8, [x23, #8]
	str	x0, [x8]
LBB0_7:                                 ;   in Loop: Header=BB0_3 Depth=1
	ldr	x8, [x19, #16]
	ldr	x23, [x8, x22, lsl #3]
	ldr	w8, [x24]
	cmp	w8, #1
	b.lt	LBB0_2
; %bb.8:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x25, #0
	mov	x26, #0
	mov	x27, #0
	b	LBB0_10
LBB0_9:                                 ;   in Loop: Header=BB0_10 Depth=2
	ldr	x8, [x28, x26]
	add	x8, x8, #16
	str	x8, [x23, #8]
	add	x27, x27, #1
	ldrsw	x8, [x24]
	add	x26, x26, #8
	add	x25, x25, #4
	cmp	x27, x8
	b.ge	LBB0_2
LBB0_10:                                ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	x28, [x23, #16]
	ldp	w19, w9, [x23]
	mul	w8, w9, w8
	add	x1, x25, w8, sxtw #2
	mov	x0, x21
	bl	_dma_region_offset_to_bus
	mov	x3, x0
	ldr	w8, [x24]
	cmp	w8, #0
	cinc	w9, w8, lt
	asr	w9, w9, #1
	sdiv	w10, w27, w9
	msub	w9, w10, w9, w27
	sub	w8, w8, #1
	cmp	w9, #0
	ccmp	x27, x8, #4, ne
	cset	w1, eq
	add	x0, x28, x26
	mov	w2, #512
	bl	_fill_input_last
	ldr	x20, [x23, #8]
	cbz	x20, LBB0_9
; %bb.11:                               ;   in Loop: Header=BB0_10 Depth=2
	add	w8, w26, w19
	orr	w0, w8, #0x1
	bl	_cpu_to_le32
	str	x0, [x20]
	b	LBB0_9
LBB0_12:
	ldr	x0, [sp]                        ; 8-byte Folded Reload
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	b	_spin_unlock_irqrestore
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_MAX_PACKETS,4,2                ; @MAX_PACKETS
	.no_dead_strip	_receive_packets
.subsections_via_symbols
