	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bba_start_rx
_bba_start_rx:                          ## @bba_start_rx
	.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	%rsi, %rbx
	movq	%rdi, -72(%rbp)                 ## 8-byte Spill
	leaq	L_.str(%rip), %rdi
	callq	_UIP_LOG
	movq	_BBA_RWP@GOTPCREL(%rip), %r13
	movl	(%r13), %edi
	callq	_bba_in12
	movl	%eax, %r15d
	movq	_BBA_RRP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_bba_in12
	movq	%rbx, -80(%rbp)                 ## 8-byte Spill
	testq	%rbx, %rbx
	jle	LBB0_15
## %bb.1:
	movl	%eax, %r14d
	cmpl	%r15d, %eax
	je	LBB0_15
## %bb.2:
	movq	_cur_descr@GOTPCREL(%rip), %rbx
	xorl	%eax, %eax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_4 Depth 2
                                        ##     Child Loop BB0_9 Depth 2
	shll	$8, %r14d
	movl	%r14d, %edi
	movq	%rbx, %rsi
	movl	$4, %edx
	callq	_bba_ins
	movq	%rbx, %rdi
	callq	_le32_to_cpus
	movq	(%rbx), %r15
	addq	$-4, %r15
	movq	_BBA_RX_MAX_PACKET_SIZE@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	addq	$4, %rax
	cmpq	%rax, %r15
	leaq	L_.str.1(%rip), %r12
	jle	LBB0_5
	.p2align	4, 0x90
LBB0_4:                                 ##   Parent Loop BB0_3 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	%r12, %rdi
	callq	_UIP_LOG
	movl	%r14d, %edi
	movq	%rbx, %rsi
	movl	$4, %edx
	callq	_bba_ins
	movq	%rbx, %rdi
	callq	_le32_to_cpus
	movq	(%rbx), %r15
	addq	$-4, %r15
	movq	_BBA_RX_MAX_PACKET_SIZE@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	addq	$4, %rax
	cmpq	%rax, %r15
	jg	LBB0_4
LBB0_5:                                 ##   in Loop: Header=BB0_3 Depth=1
	movq	_BBA_RX_STATUS_FAE@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_BBA_RX_STATUS_RERR@GOTPCREL(%rip), %rcx
	orq	(%rcx), %rax
	testq	%rax, 8(%rbx)
	je	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_3 Depth=1
	leaq	L_.str.2(%rip), %rdi
	callq	_UIP_LOG
	movl	(%r13), %edi
	callq	_bba_in12
	movl	%eax, %r15d
	movq	_BBA_RRP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_bba_in12
	movl	%eax, %r14d
	cmpl	%r15d, %eax
	jne	LBB0_3
	jmp	LBB0_15
LBB0_7:                                 ##   in Loop: Header=BB0_3 Depth=1
	movq	_BBA_INIT_RHBP@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	movq	_UIP_PBUF_RAW@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_UIP_PBUF_POOL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r15, %rsi
	callq	_uip_pbuf_alloc
	testq	%rax, %rax
	je	LBB0_15
## %bb.8:                               ##   in Loop: Header=BB0_3 Depth=1
	shll	$8, %r12d
	addl	$256, %r12d                     ## imm = 0x100
	orl	$4, %r14d
	movl	%r12d, -44(%rbp)                ## 4-byte Spill
	movslq	%r12d, %rcx
	movq	%rcx, -88(%rbp)                 ## 8-byte Spill
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movq	%rax, %r12
	jmp	LBB0_9
	.p2align	4, 0x90
LBB0_11:                                ##   in Loop: Header=BB0_9 Depth=2
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	subl	%r14d, %eax
	movslq	%eax, %r13
	subq	%r13, %r15
	movq	_BBA_INIT_RRP@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	shll	$8, %r14d
	movq	(%r12), %rdi
	movq	%r13, %rsi
	callq	_bba_insdata
	xorl	%eax, %eax
	callq	_bba_deselect
	xorl	%eax, %eax
	callq	_bba_select
	movl	%r14d, %edi
	callq	_bba_insregister
	addq	(%r12), %r13
	movq	%r13, %rdi
	movq	_BBA_RWP@GOTPCREL(%rip), %r13
LBB0_12:                                ##   in Loop: Header=BB0_9 Depth=2
	movq	%r15, %rsi
	callq	_bba_insdata
	xorl	%eax, %eax
	callq	_bba_deselect
	addl	%r15d, %r14d
	movq	8(%r12), %r12
	testq	%r12, %r12
	je	LBB0_13
LBB0_9:                                 ##   Parent Loop BB0_3 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	xorl	%eax, %eax
	callq	_bba_select
	movl	%r14d, %edi
	callq	_bba_insregister
	movslq	%r14d, %rax
	addq	%r15, %rax
	cmpq	-88(%rbp), %rax                 ## 8-byte Folded Reload
	jge	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_9 Depth=2
	movq	(%r12), %rdi
	jmp	LBB0_12
LBB0_13:                                ##   in Loop: Header=BB0_3 Depth=1
	movq	_EXI_CHANNEL_0@GOTPCREL(%rip), %r14
	movl	(%r14), %edi
	callq	_EXI_Unlock
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movq	-72(%rbp), %rsi                 ## 8-byte Reload
	callq	_bba_process
	movl	(%r14), %edi
	movq	_EXI_DEVICE_2@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%edx, %edx
	callq	_EXI_Lock
	movq	-56(%rbp), %r15                 ## 8-byte Reload
	incq	%r15
	movq	_BBA_RRP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	16(%rbx), %r14d
	movl	%r14d, %esi
	callq	_bba_out12
	movl	(%r13), %edi
	callq	_bba_in12
	movq	%r15, %rcx
	movq	%r15, -56(%rbp)                 ## 8-byte Spill
	cmpq	-80(%rbp), %r15                 ## 8-byte Folded Reload
	jge	LBB0_15
## %bb.14:                              ##   in Loop: Header=BB0_3 Depth=1
	cmpl	%eax, %r14d
	jne	LBB0_3
LBB0_15:
	movq	_UIP_ERR_OK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"bba_start_rx()\n"

	.comm	_BBA_RWP,4,2                    ## @BBA_RWP
	.comm	_BBA_RRP,4,2                    ## @BBA_RRP
	.comm	_cur_descr,24,3                 ## @cur_descr
	.comm	_BBA_RX_MAX_PACKET_SIZE,8,3     ## @BBA_RX_MAX_PACKET_SIZE
L_.str.1:                               ## @.str.1
	.asciz	"bba_start_rx: packet dropped due to big buffer.\n"

	.comm	_BBA_RX_STATUS_RERR,8,3         ## @BBA_RX_STATUS_RERR
	.comm	_BBA_RX_STATUS_FAE,8,3          ## @BBA_RX_STATUS_FAE
L_.str.2:                               ## @.str.2
	.asciz	"bba_start_rx: packet dropped due to receive errors.\n"

	.comm	_BBA_INIT_RHBP,4,2              ## @BBA_INIT_RHBP
	.comm	_UIP_PBUF_RAW,4,2               ## @UIP_PBUF_RAW
	.comm	_UIP_PBUF_POOL,4,2              ## @UIP_PBUF_POOL
	.comm	_BBA_INIT_RRP,4,2               ## @BBA_INIT_RRP
	.comm	_EXI_CHANNEL_0,4,2              ## @EXI_CHANNEL_0
	.comm	_EXI_DEVICE_2,4,2               ## @EXI_DEVICE_2
	.comm	_UIP_ERR_OK,4,2                 ## @UIP_ERR_OK
	.no_dead_strip	_bba_start_rx
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bba_start_rx
_bba_start_rx:                          ; @bba_start_rx
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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	x27, x1
	mov	x28, x0
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_UIP_LOG
Lloh2:
	adrp	x8, _BBA_RWP@GOTPAGE
Lloh3:
	ldr	x8, [x8, _BBA_RWP@GOTPAGEOFF]
Lloh4:
	ldr	w0, [x8]
	bl	_bba_in12
	mov	x21, x0
Lloh5:
	adrp	x8, _BBA_RRP@GOTPAGE
Lloh6:
	ldr	x8, [x8, _BBA_RRP@GOTPAGEOFF]
Lloh7:
	ldr	w0, [x8]
	bl	_bba_in12
	cmp	x27, #1
	b.lt	LBB0_16
; %bb.1:
	mov	x24, x0
	cmp	w0, w21
	b.eq	LBB0_16
; %bb.2:
	str	xzr, [sp, #24]                  ; 8-byte Folded Spill
Lloh8:
	adrp	x21, _cur_descr@GOTPAGE
Lloh9:
	ldr	x21, [x21, _cur_descr@GOTPAGEOFF]
Lloh10:
	adrp	x19, _BBA_RX_MAX_PACKET_SIZE@GOTPAGE
Lloh11:
	ldr	x19, [x19, _BBA_RX_MAX_PACKET_SIZE@GOTPAGEOFF]
Lloh12:
	adrp	x22, l_.str.1@PAGE
Lloh13:
	add	x22, x22, l_.str.1@PAGEOFF
Lloh14:
	adrp	x23, l_.str.2@PAGE
Lloh15:
	add	x23, x23, l_.str.2@PAGEOFF
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_4 Depth 2
                                        ;     Child Loop BB0_12 Depth 2
	lsl	w26, w24, #8
LBB0_4:                                 ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	mov	x0, x26
	mov	x1, x21
	mov	w2, #4
	bl	_bba_ins
	mov	x0, x21
	bl	_le32_to_cpus
	ldr	x8, [x21]
	sub	x24, x8, #4
	ldr	x8, [x19]
	add	x8, x8, #4
	cmp	x24, x8
	b.le	LBB0_6
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=2
	mov	x0, x22
	bl	_UIP_LOG
	b	LBB0_4
LBB0_6:                                 ;   in Loop: Header=BB0_3 Depth=1
	ldr	x8, [x21, #8]
Lloh16:
	adrp	x9, _BBA_RX_STATUS_RERR@GOTPAGE
Lloh17:
	ldr	x9, [x9, _BBA_RX_STATUS_RERR@GOTPAGEOFF]
Lloh18:
	ldr	x9, [x9]
Lloh19:
	adrp	x10, _BBA_RX_STATUS_FAE@GOTPAGE
Lloh20:
	ldr	x10, [x10, _BBA_RX_STATUS_FAE@GOTPAGEOFF]
Lloh21:
	ldr	x10, [x10]
	orr	x9, x10, x9
	tst	x9, x8
	b.eq	LBB0_8
; %bb.7:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x0, x23
	bl	_UIP_LOG
Lloh22:
	adrp	x8, _BBA_RWP@GOTPAGE
Lloh23:
	ldr	x8, [x8, _BBA_RWP@GOTPAGEOFF]
Lloh24:
	ldr	w0, [x8]
	bl	_bba_in12
	mov	x25, x0
Lloh25:
	adrp	x8, _BBA_RRP@GOTPAGE
Lloh26:
	ldr	x8, [x8, _BBA_RRP@GOTPAGEOFF]
Lloh27:
	ldr	w0, [x8]
	bl	_bba_in12
	mov	x24, x0
	cmp	w0, w25
	b.ne	LBB0_3
	b	LBB0_16
LBB0_8:                                 ;   in Loop: Header=BB0_3 Depth=1
Lloh28:
	adrp	x8, _BBA_INIT_RHBP@GOTPAGE
Lloh29:
	ldr	x8, [x8, _BBA_INIT_RHBP@GOTPAGEOFF]
Lloh30:
	ldr	w20, [x8]
Lloh31:
	adrp	x8, _UIP_PBUF_RAW@GOTPAGE
Lloh32:
	ldr	x8, [x8, _UIP_PBUF_RAW@GOTPAGEOFF]
Lloh33:
	ldr	w0, [x8]
Lloh34:
	adrp	x8, _UIP_PBUF_POOL@GOTPAGE
Lloh35:
	ldr	x8, [x8, _UIP_PBUF_POOL@GOTPAGEOFF]
Lloh36:
	ldr	w2, [x8]
	mov	x1, x24
	bl	_uip_pbuf_alloc
	cbz	x0, LBB0_16
; %bb.9:                                ;   in Loop: Header=BB0_3 Depth=1
	stp	x28, x27, [sp, #8]              ; 16-byte Folded Spill
	lsl	w8, w20, #8
	add	w25, w8, #256
	orr	w26, w26, #0x4
	sxtw	x28, w25
	str	x0, [sp]                        ; 8-byte Folded Spill
	mov	x20, x0
	b	LBB0_12
LBB0_10:                                ;   in Loop: Header=BB0_12 Depth=2
	sub	w8, w25, w26
	sxtw	x27, w8
	sub	x24, x24, x27
Lloh37:
	adrp	x8, _BBA_INIT_RRP@GOTPAGE
Lloh38:
	ldr	x8, [x8, _BBA_INIT_RRP@GOTPAGEOFF]
Lloh39:
	ldr	w8, [x8]
	lsl	w26, w8, #8
	ldr	x0, [x20]
	mov	x1, x27
	bl	_bba_insdata
	bl	_bba_deselect
	bl	_bba_select
	mov	x0, x26
	bl	_bba_insregister
	ldr	x8, [x20]
	add	x0, x8, x27
LBB0_11:                                ;   in Loop: Header=BB0_12 Depth=2
	mov	x1, x24
	bl	_bba_insdata
	bl	_bba_deselect
	add	w26, w26, w24
	ldr	x20, [x20, #8]
	cbz	x20, LBB0_14
LBB0_12:                                ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	bl	_bba_select
	mov	x0, x26
	bl	_bba_insregister
	add	x8, x24, w26, sxtw
	cmp	x8, x28
	b.ge	LBB0_10
; %bb.13:                               ;   in Loop: Header=BB0_12 Depth=2
	ldr	x0, [x20]
	b	LBB0_11
LBB0_14:                                ;   in Loop: Header=BB0_3 Depth=1
Lloh40:
	adrp	x20, _EXI_CHANNEL_0@GOTPAGE
Lloh41:
	ldr	x20, [x20, _EXI_CHANNEL_0@GOTPAGEOFF]
	ldr	w0, [x20]
	bl	_EXI_Unlock
	ldp	x0, x28, [sp]                   ; 16-byte Folded Reload
	mov	x1, x28
	bl	_bba_process
	ldr	w0, [x20]
Lloh42:
	adrp	x8, _EXI_DEVICE_2@GOTPAGE
Lloh43:
	ldr	x8, [x8, _EXI_DEVICE_2@GOTPAGEOFF]
Lloh44:
	ldr	w1, [x8]
	mov	x2, #0
	bl	_EXI_Lock
	ldr	x20, [sp, #24]                  ; 8-byte Folded Reload
	add	x20, x20, #1
Lloh45:
	adrp	x8, _BBA_RRP@GOTPAGE
Lloh46:
	ldr	x8, [x8, _BBA_RRP@GOTPAGEOFF]
Lloh47:
	ldr	w0, [x8]
	ldr	w24, [x21, #16]
	mov	x1, x24
	bl	_bba_out12
Lloh48:
	adrp	x8, _BBA_RWP@GOTPAGE
Lloh49:
	ldr	x8, [x8, _BBA_RWP@GOTPAGEOFF]
Lloh50:
	ldr	w0, [x8]
	bl	_bba_in12
	ldr	x27, [sp, #16]                  ; 8-byte Folded Reload
	str	x20, [sp, #24]                  ; 8-byte Folded Spill
	cmp	x20, x27
	b.ge	LBB0_16
; %bb.15:                               ;   in Loop: Header=BB0_3 Depth=1
	cmp	w24, w0
	b.ne	LBB0_3
LBB0_16:
Lloh51:
	adrp	x8, _UIP_ERR_OK@GOTPAGE
Lloh52:
	ldr	x8, [x8, _UIP_ERR_OK@GOTPAGEOFF]
Lloh53:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh48, Lloh49, Lloh50
	.loh AdrpLdrGotLdr	Lloh45, Lloh46, Lloh47
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh44
	.loh AdrpLdrGot	Lloh40, Lloh41
	.loh AdrpLdrGotLdr	Lloh51, Lloh52, Lloh53
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"bba_start_rx()\n"

	.comm	_BBA_RWP,4,2                    ; @BBA_RWP
	.comm	_BBA_RRP,4,2                    ; @BBA_RRP
	.comm	_cur_descr,24,3                 ; @cur_descr
	.comm	_BBA_RX_MAX_PACKET_SIZE,8,3     ; @BBA_RX_MAX_PACKET_SIZE
l_.str.1:                               ; @.str.1
	.asciz	"bba_start_rx: packet dropped due to big buffer.\n"

	.comm	_BBA_RX_STATUS_RERR,8,3         ; @BBA_RX_STATUS_RERR
	.comm	_BBA_RX_STATUS_FAE,8,3          ; @BBA_RX_STATUS_FAE
l_.str.2:                               ; @.str.2
	.asciz	"bba_start_rx: packet dropped due to receive errors.\n"

	.comm	_BBA_INIT_RHBP,4,2              ; @BBA_INIT_RHBP
	.comm	_UIP_PBUF_RAW,4,2               ; @UIP_PBUF_RAW
	.comm	_UIP_PBUF_POOL,4,2              ; @UIP_PBUF_POOL
	.comm	_BBA_INIT_RRP,4,2               ; @BBA_INIT_RRP
	.comm	_EXI_CHANNEL_0,4,2              ; @EXI_CHANNEL_0
	.comm	_EXI_DEVICE_2,4,2               ; @EXI_DEVICE_2
	.comm	_UIP_ERR_OK,4,2                 ; @UIP_ERR_OK
	.no_dead_strip	_bba_start_rx
.subsections_via_symbols
