	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sun4i_can_rx
_sun4i_can_rx:                          ## @sun4i_can_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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	callq	_netdev_priv
	movq	%rax, %r13
	leaq	-48(%rbp), %rsi
	movq	%r14, %rdi
	callq	_alloc_can_skb
	testq	%rax, %rax
	je	LBB0_9
## %bb.1:
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movq	_SUN4I_REG_BUF0_ADDR@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	(%r13), %rdi
	callq	_readl
	movl	%eax, %ebx
	movl	%eax, %edi
	andl	$15, %edi
	callq	_get_can_dlc
	movq	-48(%rbp), %rcx
	movl	%eax, (%rcx)
	movq	_SUN4I_MSG_EFF_FLAG@GOTPCREL(%rip), %rax
	movl	%ebx, -52(%rbp)                 ## 4-byte Spill
	testl	%ebx, (%rax)
	je	LBB0_3
## %bb.2:
	movq	_SUN4I_REG_BUF5_ADDR@GOTPCREL(%rip), %rax
	movq	(%rax), %r12
	movq	_SUN4I_REG_BUF1_ADDR@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	(%r13), %rdi
	callq	_readl
	movl	%eax, %ebx
	shll	$21, %ebx
	movq	_SUN4I_REG_BUF2_ADDR@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	(%r13), %rdi
	callq	_readl
	movq	%r14, -64(%rbp)                 ## 8-byte Spill
	movl	%eax, %r14d
	shll	$13, %r14d
	orl	%ebx, %r14d
	movq	_SUN4I_REG_BUF3_ADDR@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	(%r13), %rdi
	callq	_readl
	movl	%eax, %r15d
	shll	$5, %r15d
	orl	%r14d, %r15d
	movq	-64(%rbp), %r14                 ## 8-byte Reload
	movq	_SUN4I_REG_BUF4_ADDR@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	(%r13), %rdi
	callq	_readl
	shrl	$3, %eax
	andl	$31, %eax
	movq	_CAN_EFF_FLAG@GOTPCREL(%rip), %rcx
	orl	(%rcx), %r15d
	orl	%eax, %r15d
	jmp	LBB0_4
LBB0_3:
	movq	_SUN4I_REG_BUF3_ADDR@GOTPCREL(%rip), %rax
	movq	(%rax), %r12
	movq	_SUN4I_REG_BUF1_ADDR@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	(%r13), %rdi
	callq	_readl
	movl	%eax, %ebx
	movq	_SUN4I_REG_BUF2_ADDR@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	(%r13), %rdi
	callq	_readl
                                        ## kill: def $eax killed $eax def $rax
	shrl	$5, %eax
	andl	$7, %eax
	leal	(%rax,%rbx,8), %r15d
LBB0_4:
	movq	_SUN4I_MSG_RTR_FLAG@GOTPCREL(%rip), %rax
	movl	-52(%rbp), %ecx                 ## 4-byte Reload
	testl	%ecx, (%rax)
	je	LBB0_5
## %bb.10:
	movq	_CAN_RTR_FLAG@GOTPCREL(%rip), %rax
	orl	(%rax), %r15d
	movq	-48(%rbp), %rcx
	jmp	LBB0_8
LBB0_5:
	movq	-48(%rbp), %rcx
	cmpl	$0, (%rcx)
	jle	LBB0_8
## %bb.6:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r13), %rdi
	addq	%r12, %rdi
	callq	_readl
	movq	-48(%rbp), %rcx
	movq	8(%rcx), %rdx
	movl	%eax, (%rdx,%rbx,4)
	incq	%rbx
	movslq	(%rcx), %rax
	addq	$4, %r12
	cmpq	%rax, %rbx
	jl	LBB0_7
LBB0_8:
	movl	%r15d, 16(%rcx)
	movq	_SUN4I_CMD_RELEASE_RBUF@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_sun4i_can_write_cmdreg
	incl	4(%r14)
	movq	-48(%rbp), %rax
	movl	(%rax), %eax
	addl	%eax, (%r14)
	movq	-72(%rbp), %rdi                 ## 8-byte Reload
	callq	_netif_rx
	movq	_CAN_LED_EVENT_RX@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_can_led_event
LBB0_9:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SUN4I_REG_BUF0_ADDR,8,3        ## @SUN4I_REG_BUF0_ADDR
	.comm	_SUN4I_MSG_EFF_FLAG,4,2         ## @SUN4I_MSG_EFF_FLAG
	.comm	_SUN4I_REG_BUF5_ADDR,8,3        ## @SUN4I_REG_BUF5_ADDR
	.comm	_SUN4I_REG_BUF1_ADDR,8,3        ## @SUN4I_REG_BUF1_ADDR
	.comm	_SUN4I_REG_BUF2_ADDR,8,3        ## @SUN4I_REG_BUF2_ADDR
	.comm	_SUN4I_REG_BUF3_ADDR,8,3        ## @SUN4I_REG_BUF3_ADDR
	.comm	_SUN4I_REG_BUF4_ADDR,8,3        ## @SUN4I_REG_BUF4_ADDR
	.comm	_CAN_EFF_FLAG,4,2               ## @CAN_EFF_FLAG
	.comm	_SUN4I_MSG_RTR_FLAG,4,2         ## @SUN4I_MSG_RTR_FLAG
	.comm	_CAN_RTR_FLAG,4,2               ## @CAN_RTR_FLAG
	.comm	_SUN4I_CMD_RELEASE_RBUF,4,2     ## @SUN4I_CMD_RELEASE_RBUF
	.comm	_CAN_LED_EVENT_RX,4,2           ## @CAN_LED_EVENT_RX
	.no_dead_strip	_sun4i_can_rx
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sun4i_can_rx
_sun4i_can_rx:                          ; @sun4i_can_rx
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x19, x0
	bl	_netdev_priv
	mov	x21, x0
	add	x1, sp, #8
	mov	x0, x19
	bl	_alloc_can_skb
	cbz	x0, LBB0_10
; %bb.1:
	mov	x20, x0
	ldr	x8, [x21]
Lloh0:
	adrp	x9, _SUN4I_REG_BUF0_ADDR@GOTPAGE
Lloh1:
	ldr	x9, [x9, _SUN4I_REG_BUF0_ADDR@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	add	x0, x9, x8
	bl	_readl
	mov	x22, x0
	and	w0, w0, #0xf
	bl	_get_can_dlc
	ldr	x8, [sp, #8]
	str	w0, [x8]
Lloh3:
	adrp	x8, _SUN4I_MSG_EFF_FLAG@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SUN4I_MSG_EFF_FLAG@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	tst	w8, w22
	b.eq	LBB0_3
; %bb.2:
Lloh6:
	adrp	x8, _SUN4I_REG_BUF5_ADDR@GOTPAGE
Lloh7:
	ldr	x8, [x8, _SUN4I_REG_BUF5_ADDR@GOTPAGEOFF]
Lloh8:
	ldr	x24, [x8]
	ldr	x8, [x21]
Lloh9:
	adrp	x9, _SUN4I_REG_BUF1_ADDR@GOTPAGE
Lloh10:
	ldr	x9, [x9, _SUN4I_REG_BUF1_ADDR@GOTPAGEOFF]
Lloh11:
	ldr	x9, [x9]
	add	x0, x9, x8
	bl	_readl
	mov	x23, x0
	ldr	x8, [x21]
Lloh12:
	adrp	x9, _SUN4I_REG_BUF2_ADDR@GOTPAGE
Lloh13:
	ldr	x9, [x9, _SUN4I_REG_BUF2_ADDR@GOTPAGEOFF]
Lloh14:
	ldr	x9, [x9]
	add	x0, x9, x8
	bl	_readl
	lsl	w8, w0, #13
	orr	w23, w8, w23, lsl #21
	ldr	x8, [x21]
Lloh15:
	adrp	x9, _SUN4I_REG_BUF3_ADDR@GOTPAGE
Lloh16:
	ldr	x9, [x9, _SUN4I_REG_BUF3_ADDR@GOTPAGEOFF]
Lloh17:
	ldr	x9, [x9]
	add	x0, x9, x8
	bl	_readl
	orr	w23, w23, w0, lsl #5
	ldr	x8, [x21]
Lloh18:
	adrp	x9, _SUN4I_REG_BUF4_ADDR@GOTPAGE
Lloh19:
	ldr	x9, [x9, _SUN4I_REG_BUF4_ADDR@GOTPAGEOFF]
Lloh20:
	ldr	x9, [x9]
	add	x0, x9, x8
	bl	_readl
	ubfx	w8, w0, #3, #5
Lloh21:
	adrp	x9, _CAN_EFF_FLAG@GOTPAGE
Lloh22:
	ldr	x9, [x9, _CAN_EFF_FLAG@GOTPAGEOFF]
Lloh23:
	ldr	w9, [x9]
	orr	w9, w23, w9
	orr	w23, w9, w8
	b	LBB0_4
LBB0_3:
Lloh24:
	adrp	x8, _SUN4I_REG_BUF3_ADDR@GOTPAGE
Lloh25:
	ldr	x8, [x8, _SUN4I_REG_BUF3_ADDR@GOTPAGEOFF]
Lloh26:
	ldr	x24, [x8]
	ldr	x8, [x21]
Lloh27:
	adrp	x9, _SUN4I_REG_BUF1_ADDR@GOTPAGE
Lloh28:
	ldr	x9, [x9, _SUN4I_REG_BUF1_ADDR@GOTPAGEOFF]
Lloh29:
	ldr	x9, [x9]
	add	x0, x9, x8
	bl	_readl
	lsl	w23, w0, #3
	ldr	x8, [x21]
Lloh30:
	adrp	x9, _SUN4I_REG_BUF2_ADDR@GOTPAGE
Lloh31:
	ldr	x9, [x9, _SUN4I_REG_BUF2_ADDR@GOTPAGEOFF]
Lloh32:
	ldr	x9, [x9]
	add	x0, x9, x8
	bl	_readl
	bfxil	w23, w0, #5, #3
LBB0_4:
Lloh33:
	adrp	x8, _SUN4I_MSG_RTR_FLAG@GOTPAGE
Lloh34:
	ldr	x8, [x8, _SUN4I_MSG_RTR_FLAG@GOTPAGEOFF]
Lloh35:
	ldr	w8, [x8]
	tst	w8, w22
	b.eq	LBB0_6
; %bb.5:
Lloh36:
	adrp	x8, _CAN_RTR_FLAG@GOTPAGE
Lloh37:
	ldr	x8, [x8, _CAN_RTR_FLAG@GOTPAGEOFF]
Lloh38:
	ldr	w8, [x8]
	orr	w23, w8, w23
	ldr	x8, [sp, #8]
	b	LBB0_9
LBB0_6:
	ldr	x8, [sp, #8]
	ldr	w9, [x8]
	cmp	w9, #1
	b.lt	LBB0_9
; %bb.7:
	mov	x22, #0
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x21]
	add	x0, x24, x8
	bl	_readl
	ldr	x8, [sp, #8]
	ldr	x9, [x8, #8]
	str	w0, [x9, x22, lsl #2]
	add	x22, x22, #1
	ldrsw	x9, [x8]
	add	x24, x24, #4
	cmp	x22, x9
	b.lt	LBB0_8
LBB0_9:
	str	w23, [x8, #16]
Lloh39:
	adrp	x8, _SUN4I_CMD_RELEASE_RBUF@GOTPAGE
Lloh40:
	ldr	x8, [x8, _SUN4I_CMD_RELEASE_RBUF@GOTPAGEOFF]
Lloh41:
	ldr	w1, [x8]
	mov	x0, x21
	bl	_sun4i_can_write_cmdreg
	ldr	x8, [sp, #8]
	ldr	d0, [x19]
	movi.2s	v1, #1
	ld1.s	{ v1 }[0], [x8]
	add.2s	v0, v0, v1
	str	d0, [x19]
	mov	x0, x20
	bl	_netif_rx
Lloh42:
	adrp	x8, _CAN_LED_EVENT_RX@GOTPAGE
Lloh43:
	ldr	x8, [x8, _CAN_LED_EVENT_RX@GOTPAGEOFF]
Lloh44:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_can_led_event
LBB0_10:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.cfi_endproc
                                        ; -- End function
	.comm	_SUN4I_REG_BUF0_ADDR,8,3        ; @SUN4I_REG_BUF0_ADDR
	.comm	_SUN4I_MSG_EFF_FLAG,4,2         ; @SUN4I_MSG_EFF_FLAG
	.comm	_SUN4I_REG_BUF5_ADDR,8,3        ; @SUN4I_REG_BUF5_ADDR
	.comm	_SUN4I_REG_BUF1_ADDR,8,3        ; @SUN4I_REG_BUF1_ADDR
	.comm	_SUN4I_REG_BUF2_ADDR,8,3        ; @SUN4I_REG_BUF2_ADDR
	.comm	_SUN4I_REG_BUF3_ADDR,8,3        ; @SUN4I_REG_BUF3_ADDR
	.comm	_SUN4I_REG_BUF4_ADDR,8,3        ; @SUN4I_REG_BUF4_ADDR
	.comm	_CAN_EFF_FLAG,4,2               ; @CAN_EFF_FLAG
	.comm	_SUN4I_MSG_RTR_FLAG,4,2         ; @SUN4I_MSG_RTR_FLAG
	.comm	_CAN_RTR_FLAG,4,2               ; @CAN_RTR_FLAG
	.comm	_SUN4I_CMD_RELEASE_RBUF,4,2     ; @SUN4I_CMD_RELEASE_RBUF
	.comm	_CAN_LED_EVENT_RX,4,2           ; @CAN_LED_EVENT_RX
	.no_dead_strip	_sun4i_can_rx
.subsections_via_symbols
