	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function at91_poll_rx
_at91_poll_rx:                          ## @at91_poll_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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r12d
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	callq	_netdev_priv
	movq	%rax, %r15
	movq	_AT91_SR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_at91_read
	movl	%eax, -44(%rbp)
	movl	(%r15), %edx
	movq	_AT91_MB_RX_LOW_LAST@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %edx
	jbe	LBB0_3
## %bb.1:
	movq	_AT91_MB_RX_LOW_MASK@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_3
## %bb.2:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	callq	_dev_info
	movl	(%r15), %edx
LBB0_3:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_6 Depth 2
	movq	_AT91_MB_RX_NUM@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	leaq	-44(%rbp), %rdi
	callq	_find_next_bit
	movl	%eax, %r13d
	testl	%r12d, %r12d
	setg	%cl
	cmpl	(%r14), %eax
	setb	%al
	jae	LBB0_13
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	testl	%r12d, %r12d
	jle	LBB0_13
	.p2align	4, 0x90
LBB0_6:                                 ##   Parent Loop BB0_4 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movl	%r13d, %esi
	callq	_at91_read_msg
	movq	_AT91_MB_RX_LOW_LAST@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r13d
	jne	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=2
	movq	%r15, %rdi
	callq	_at91_activate_rx_low
	jmp	LBB0_10
	.p2align	4, 0x90
LBB0_8:                                 ##   in Loop: Header=BB0_6 Depth=2
	jbe	LBB0_10
## %bb.9:                               ##   in Loop: Header=BB0_6 Depth=2
	movq	%r15, %rdi
	movl	%r13d, %esi
	callq	_at91_activate_rx_mb
LBB0_10:                                ##   in Loop: Header=BB0_6 Depth=2
	incl	%ebx
	leal	-1(%r12), %r14d
	movq	_AT91_SR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_at91_read
	movl	%eax, -44(%rbp)
	movq	_AT91_MB_RX_NUM@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	(%r15), %edx
	incl	%edx
	movl	%edx, (%r15)
	leaq	-44(%rbp), %rdi
	callq	_find_next_bit
	movl	%eax, %r13d
	cmpl	$2, %r12d
	setge	%cl
	movq	_AT91_MB_RX_NUM@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r13d
	setb	%al
	jae	LBB0_14
## %bb.11:                              ##   in Loop: Header=BB0_6 Depth=2
	cmpl	$1, %r12d
	movl	%r14d, %r12d
	jg	LBB0_6
	jmp	LBB0_14
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_4 Depth=1
	movl	%r12d, %r14d
LBB0_14:                                ##   in Loop: Header=BB0_4 Depth=1
	movl	(%r15), %edx
	movq	_AT91_MB_RX_LOW_LAST@GOTPCREL(%rip), %rsi
	cmpl	(%rsi), %edx
	jbe	LBB0_18
## %bb.15:                              ##   in Loop: Header=BB0_4 Depth=1
	testb	%cl, %cl
	je	LBB0_18
## %bb.16:                              ##   in Loop: Header=BB0_4 Depth=1
	testb	%al, %al
	jne	LBB0_18
## %bb.17:                              ##   in Loop: Header=BB0_4 Depth=1
	movl	$0, (%r15)
	xorl	%edx, %edx
	movl	%r14d, %r12d
	jmp	LBB0_4
LBB0_18:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AT91_SR,4,2                    ## @AT91_SR
	.comm	_AT91_MB_RX_LOW_LAST,4,2        ## @AT91_MB_RX_LOW_LAST
	.comm	_AT91_MB_RX_LOW_MASK,4,2        ## @AT91_MB_RX_LOW_MASK
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"order of incoming frames cannot be guaranteed\n"

	.comm	_AT91_MB_RX_NUM,4,2             ## @AT91_MB_RX_NUM
	.no_dead_strip	_at91_poll_rx
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function at91_poll_rx
_at91_poll_rx:                          ; @at91_poll_rx
	.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	x22, x1
	mov	x19, x0
	bl	_netdev_priv
	mov	x20, x0
Lloh0:
	adrp	x24, _AT91_SR@GOTPAGE
Lloh1:
	ldr	x24, [x24, _AT91_SR@GOTPAGEOFF]
	ldr	w1, [x24]
	bl	_at91_read
	str	w0, [sp, #12]
	ldr	w2, [x20]
Lloh2:
	adrp	x25, _AT91_MB_RX_LOW_LAST@GOTPAGE
Lloh3:
	ldr	x25, [x25, _AT91_MB_RX_LOW_LAST@GOTPAGEOFF]
	ldr	w8, [x25]
	cmp	w2, w8
	b.ls	LBB0_3
; %bb.1:
Lloh4:
	adrp	x8, _AT91_MB_RX_LOW_MASK@GOTPAGE
Lloh5:
	ldr	x8, [x8, _AT91_MB_RX_LOW_MASK@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	tst	w8, w0
	b.eq	LBB0_3
; %bb.2:
	ldr	w0, [x19]
Lloh7:
	adrp	x1, l_.str@PAGE
Lloh8:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_info
	ldr	w2, [x20]
LBB0_3:
	mov	w21, #0
Lloh9:
	adrp	x26, _AT91_MB_RX_NUM@GOTPAGE
Lloh10:
	ldr	x26, [x26, _AT91_MB_RX_NUM@GOTPAGEOFF]
LBB0_4:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_11 Depth 2
	ldr	w1, [x26]
	add	x0, sp, #12
	bl	_find_next_bit
	ldr	w8, [x26]
	cmp	w22, #0
	cset	w9, gt
	cmp	w0, w8
	cset	w8, lo
	ccmp	w22, #1, #8, lo
	b.ge	LBB0_8
LBB0_5:                                 ;   in Loop: Header=BB0_4 Depth=1
	ldr	w10, [x20]
	ldr	w11, [x25]
	cmp	w10, w11
	ccmp	w9, #0, #4, hi
	b.eq	LBB0_14
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	tbnz	w8, #0, LBB0_14
; %bb.7:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	w2, #0
	str	wzr, [x20]
	b	LBB0_4
LBB0_8:                                 ;   in Loop: Header=BB0_4 Depth=1
	mov	x23, x0
	b	LBB0_11
LBB0_9:                                 ;   in Loop: Header=BB0_11 Depth=2
	mov	x0, x20
	bl	_at91_activate_rx_low
LBB0_10:                                ;   in Loop: Header=BB0_11 Depth=2
	add	w21, w21, #1
	ldr	w1, [x24]
	mov	x0, x20
	bl	_at91_read
	str	w0, [sp, #12]
	ldr	w1, [x26]
	ldr	w8, [x20]
	add	w2, w8, #1
	str	w2, [x20]
	add	x0, sp, #12
	bl	_find_next_bit
	mov	x23, x0
	subs	w22, w27, #1
	ldr	w8, [x26]
	cset	w9, gt
	cmp	w0, w8
	cset	w8, lo
	ccmp	w27, #1, #4, lo
	b.le	LBB0_5
LBB0_11:                                ;   Parent Loop BB0_4 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	mov	x27, x22
	mov	x0, x19
	mov	x1, x23
	bl	_at91_read_msg
	ldr	w8, [x25]
	cmp	w23, w8
	b.eq	LBB0_9
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=2
	b.ls	LBB0_10
; %bb.13:                               ;   in Loop: Header=BB0_11 Depth=2
	mov	x0, x20
	mov	x1, x23
	bl	_at91_activate_rx_mb
	b	LBB0_10
LBB0_14:
	mov	x0, x21
	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
	ret
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_AT91_SR,4,2                    ; @AT91_SR
	.comm	_AT91_MB_RX_LOW_LAST,4,2        ; @AT91_MB_RX_LOW_LAST
	.comm	_AT91_MB_RX_LOW_MASK,4,2        ; @AT91_MB_RX_LOW_MASK
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"order of incoming frames cannot be guaranteed\n"

	.comm	_AT91_MB_RX_NUM,4,2             ; @AT91_MB_RX_NUM
	.no_dead_strip	_at91_poll_rx
.subsections_via_symbols
