	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mcp251x_hw_rx_frame
_mcp251x_hw_rx_frame:                   ## @mcp251x_hw_rx_frame
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r14d
	movq	%rsi, %r15
	movq	%rdi, %rbx
	callq	_spi_get_drvdata
	movq	%rax, %r13
	movq	%rbx, %rdi
	callq	_mcp251x_is_2510
	testq	%rax, %rax
	je	LBB0_8
## %bb.1:
	movq	_RXBDAT_OFF@GOTPCREL(%rip), %r12
	movl	$1, %r13d
	cmpl	$2, (%r12)
	jl	LBB0_4
## %bb.2:
	movl	$1, %r13d
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movl	%r14d, %edi
	callq	_RXBCTRL
	leaq	(%rax,%r13), %rsi
	movq	%rbx, %rdi
	callq	_mcp251x_read_reg
	movl	%eax, (%r15,%r13,4)
	incq	%r13
	movslq	(%r12), %rax
	cmpq	%rax, %r13
	jl	LBB0_3
LBB0_4:
	movq	_RXBDLC_OFF@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_RXBDLC_LEN_MASK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	andl	(%r15,%rax,4), %edi
	callq	_get_can_dlc
	movq	%r12, %rdx
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	movl	%r14d, %r12d
	movl	%eax, %r14d
	movl	(%rdx), %eax
	addl	%r14d, %eax
	cmpl	%eax, %r13d
	jge	LBB0_7
## %bb.5:
	movl	%r13d, %ebx
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movl	%r12d, %edi
	movq	%r15, %r13
	movq	%rdx, %r15
	callq	_RXBCTRL
	leaq	(%rax,%rbx), %rsi
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_mcp251x_read_reg
	movq	%r15, %rdx
	movq	%r13, %r15
	movl	%eax, (%r13,%rbx,4)
	incq	%rbx
	movl	(%rdx), %eax
	addl	%r14d, %eax
	cmpl	%ebx, %eax
	jg	LBB0_6
LBB0_7:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_8:
	movl	%r14d, %edi
	callq	_INSTRUCTION_READ_RXB
	movq	8(%r13), %rcx
	movq	_RXBCTRL_OFF@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	movl	%eax, (%rcx,%rdx,4)
	movq	_SPI_TRANSFER_BUF_LEN@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	movq	%rbx, %rdi
	callq	_mcp251x_spi_trans
	movl	(%r13), %esi
	movl	(%r14), %edx
	movq	%r15, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_memcpy                         ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_RXBDAT_OFF,4,2                 ## @RXBDAT_OFF
	.comm	_RXBDLC_OFF,8,3                 ## @RXBDLC_OFF
	.comm	_RXBDLC_LEN_MASK,4,2            ## @RXBDLC_LEN_MASK
	.comm	_RXBCTRL_OFF,8,3                ## @RXBCTRL_OFF
	.comm	_SPI_TRANSFER_BUF_LEN,4,2       ## @SPI_TRANSFER_BUF_LEN
	.no_dead_strip	_mcp251x_hw_rx_frame
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mcp251x_hw_rx_frame
_mcp251x_hw_rx_frame:                   ; @mcp251x_hw_rx_frame
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x21, x2
	mov	x19, x1
	mov	x20, x0
	bl	_spi_get_drvdata
	mov	x22, x0
	mov	x0, x20
	bl	_mcp251x_is_2510
	cbz	x0, LBB0_7
; %bb.1:
Lloh0:
	adrp	x23, _RXBDAT_OFF@GOTPAGE
Lloh1:
	ldr	x23, [x23, _RXBDAT_OFF@GOTPAGEOFF]
	ldr	w8, [x23]
	mov	w24, #1
	cmp	w8, #2
	b.lt	LBB0_3
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x21
	bl	_RXBCTRL
	add	x1, x0, x24
	mov	x0, x20
	bl	_mcp251x_read_reg
	str	w0, [x19, x24, lsl #2]
	add	x24, x24, #1
	ldrsw	x8, [x23]
	cmp	x24, x8
	b.lt	LBB0_2
LBB0_3:
Lloh2:
	adrp	x8, _RXBDLC_OFF@GOTPAGE
Lloh3:
	ldr	x8, [x8, _RXBDLC_OFF@GOTPAGEOFF]
Lloh4:
	ldr	x8, [x8]
	ldr	w8, [x19, x8, lsl #2]
Lloh5:
	adrp	x9, _RXBDLC_LEN_MASK@GOTPAGE
Lloh6:
	ldr	x9, [x9, _RXBDLC_LEN_MASK@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	and	w0, w9, w8
	bl	_get_can_dlc
	ldr	w8, [x23]
	add	w8, w8, w0
	cmp	w24, w8
	b.ge	LBB0_6
; %bb.4:
	mov	x22, x0
	mov	w24, w24
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x21
	bl	_RXBCTRL
	add	x1, x0, x24
	mov	x0, x20
	bl	_mcp251x_read_reg
	str	w0, [x19, x24, lsl #2]
	add	x24, x24, #1
	ldr	w8, [x23]
	add	w8, w8, w22
	cmp	w8, w24
	b.gt	LBB0_5
LBB0_6:
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_7:
	mov	x0, x21
	bl	_INSTRUCTION_READ_RXB
	ldr	x8, [x22, #8]
Lloh8:
	adrp	x9, _RXBCTRL_OFF@GOTPAGE
Lloh9:
	ldr	x9, [x9, _RXBCTRL_OFF@GOTPAGEOFF]
Lloh10:
	ldr	x9, [x9]
	str	w0, [x8, x9, lsl #2]
Lloh11:
	adrp	x21, _SPI_TRANSFER_BUF_LEN@GOTPAGE
Lloh12:
	ldr	x21, [x21, _SPI_TRANSFER_BUF_LEN@GOTPAGEOFF]
	ldr	w1, [x21]
	mov	x0, x20
	bl	_mcp251x_spi_trans
	ldr	w1, [x22]
	ldr	w2, [x21]
	mov	x0, x19
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_memcpy
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_RXBDAT_OFF,4,2                 ; @RXBDAT_OFF
	.comm	_RXBDLC_OFF,8,3                 ; @RXBDLC_OFF
	.comm	_RXBDLC_LEN_MASK,4,2            ; @RXBDLC_LEN_MASK
	.comm	_RXBCTRL_OFF,8,3                ; @RXBCTRL_OFF
	.comm	_SPI_TRANSFER_BUF_LEN,4,2       ; @SPI_TRANSFER_BUF_LEN
	.no_dead_strip	_mcp251x_hw_rx_frame
.subsections_via_symbols
