	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ucan_rx_can_msg
_ucan_rx_can_msg:                       ## @ucan_rx_can_msg
	.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
	movq	%rsi, %r15
	movq	%rdi, %rbx
	movq	(%rdi), %r13
	movl	8(%rsi), %edi
	callq	_le16_to_cpu
	movl	%eax, %r14d
	cltq
	movq	_UCAN_IN_HDR_SIZE@GOTPCREL(%rip), %rcx
	movslq	(%rcx), %rcx
	addq	$4, %rcx
	cmpq	%rax, %rcx
	jbe	LBB0_1
## %bb.15:
	movq	(%rbx), %rdi
	leaq	L_.str(%rip), %rsi
	movl	%r14d, %edx
	xorl	%eax, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_netdev_warn                    ## TAILCALL
LBB0_1:
	movl	4(%r15), %edi
	callq	_le32_to_cpu
	movl	%eax, %r12d
	movq	_CAN_ERR_FLAG@GOTPCREL(%rip), %rax
	testl	%r12d, (%rax)
	je	LBB0_3
## %bb.2:
	movq	%rbx, %rdi
	movq	%r15, %rsi
	movl	%r12d, %edx
	callq	_ucan_handle_error_frame
	movq	_CAN_CTRLMODE_BERR_REPORTING@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	andl	8(%rbx), %ecx
	orl	%eax, %ecx
	jne	LBB0_9
	jmp	LBB0_14
LBB0_3:
	movq	%r13, -56(%rbp)                 ## 8-byte Spill
	movq	_CAN_RTR_FLAG@GOTPCREL(%rip), %rax
	movq	_CAN_EFF_FLAG@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r13d
	testl	%r12d, %r13d
	jne	LBB0_4
## %bb.5:
	movq	_CAN_SFF_MASK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r13d
	jmp	LBB0_6
LBB0_4:
	movq	_CAN_EFF_MASK@GOTPCREL(%rip), %rcx
	orl	(%rcx), %r13d
LBB0_6:
	orl	(%rax), %r13d
	movl	%r13d, %eax
	notl	%eax
	testl	%eax, %r12d
	je	LBB0_8
## %bb.7:
	movq	(%rbx), %rdi
	leaq	L_.str.1(%rip), %rsi
	movl	%r12d, %edx
	movl	%r13d, %ecx
	xorl	%eax, %eax
	callq	_netdev_warn
LBB0_8:
	andl	%r13d, %r12d
	movq	-56(%rbp), %r13                 ## 8-byte Reload
LBB0_9:
	movq	(%rbx), %rdi
	leaq	-48(%rbp), %rsi
	callq	_alloc_can_skb
	testq	%rax, %rax
	je	LBB0_14
## %bb.10:
	movq	%rax, %rbx
	movq	-48(%rbp), %rax
	movl	%r12d, (%rax)
	movq	%r15, %rdi
	movl	%r14d, %esi
	callq	_ucan_get_can_dlc
	movq	-48(%rbp), %rcx
	movq	%rax, 8(%rcx)
	movl	(%rcx), %edx
	movq	_CAN_RTR_FLAG@GOTPCREL(%rip), %rsi
	testl	%edx, (%rsi)
	je	LBB0_12
## %bb.11:
	movq	_CAN_ERR_FLAG@GOTPCREL(%rip), %rsi
	testl	%edx, (%rsi)
	je	LBB0_13
LBB0_12:
	movl	16(%rcx), %edi
	movl	(%r15), %esi
	movq	%rax, %rdx
	callq	_memcpy
	movq	-48(%rbp), %rax
	movq	8(%rax), %rax
LBB0_13:
	incl	4(%r13)
	addl	%eax, (%r13)
	movq	%rbx, %rdi
	callq	_netif_rx
LBB0_14:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_UCAN_IN_HDR_SIZE,4,2           ## @UCAN_IN_HDR_SIZE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"invalid input message len: %d\n"

	.comm	_CAN_ERR_FLAG,4,2               ## @CAN_ERR_FLAG
	.comm	_CAN_CTRLMODE_BERR_REPORTING,4,2 ## @CAN_CTRLMODE_BERR_REPORTING
	.comm	_CAN_RTR_FLAG,4,2               ## @CAN_RTR_FLAG
	.comm	_CAN_EFF_FLAG,4,2               ## @CAN_EFF_FLAG
	.comm	_CAN_EFF_MASK,4,2               ## @CAN_EFF_MASK
	.comm	_CAN_SFF_MASK,4,2               ## @CAN_SFF_MASK
L_.str.1:                               ## @.str.1
	.asciz	"unexpected bits set (canid %x, mask %x)"

	.no_dead_strip	_ucan_rx_can_msg
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ucan_rx_can_msg
_ucan_rx_can_msg:                       ; @ucan_rx_can_msg
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	mov	x19, x1
	mov	x21, x0
	ldr	x23, [x0]
	ldr	w0, [x1, #8]
	bl	_le16_to_cpu
	mov	x20, x0
Lloh0:
	adrp	x8, _UCAN_IN_HDR_SIZE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _UCAN_IN_HDR_SIZE@GOTPAGEOFF]
Lloh2:
	ldrsw	x8, [x8]
	add	x8, x8, #4
	cmp	x8, w0, sxtw
	b.ls	LBB0_2
; %bb.1:
	ldr	x0, [x21]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x20
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	b	_netdev_warn
LBB0_2:
	ldr	w0, [x19, #4]
	bl	_le32_to_cpu
	mov	x22, x0
Lloh5:
	adrp	x24, _CAN_ERR_FLAG@GOTPAGE
Lloh6:
	ldr	x24, [x24, _CAN_ERR_FLAG@GOTPAGEOFF]
	ldr	w8, [x24]
	tst	w8, w0
	b.eq	LBB0_4
; %bb.3:
	mov	x0, x21
	mov	x1, x19
	mov	x2, x22
	bl	_ucan_handle_error_frame
	ldr	w8, [x21, #8]
Lloh7:
	adrp	x9, _CAN_CTRLMODE_BERR_REPORTING@GOTPAGE
Lloh8:
	ldr	x9, [x9, _CAN_CTRLMODE_BERR_REPORTING@GOTPAGEOFF]
Lloh9:
	ldr	w9, [x9]
	and	w8, w9, w8
	orr	w8, w8, w0
	cbnz	w8, LBB0_7
	b	LBB0_12
LBB0_4:
Lloh10:
	adrp	x8, _CAN_RTR_FLAG@GOTPAGE
Lloh11:
	ldr	x8, [x8, _CAN_RTR_FLAG@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
Lloh13:
	adrp	x9, _CAN_EFF_FLAG@GOTPAGE
Lloh14:
	ldr	x9, [x9, _CAN_EFF_FLAG@GOTPAGEOFF]
Lloh15:
	ldr	w9, [x9]
Lloh16:
	adrp	x10, _CAN_EFF_MASK@GOTPAGE
Lloh17:
	ldr	x10, [x10, _CAN_EFF_MASK@GOTPAGEOFF]
Lloh18:
	ldr	w10, [x10]
Lloh19:
	adrp	x11, _CAN_SFF_MASK@GOTPAGE
Lloh20:
	ldr	x11, [x11, _CAN_SFF_MASK@GOTPAGEOFF]
	orr	w10, w10, w9
Lloh21:
	ldr	w11, [x11]
	tst	w9, w22
	csel	w9, w11, w10, eq
	orr	w25, w9, w8
	bics	wzr, w22, w25
	b.eq	LBB0_6
; %bb.5:
	ldr	x0, [x21]
	str	x25, [sp]
Lloh22:
	adrp	x1, l_.str.1@PAGE
Lloh23:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x2, x22
	bl	_netdev_warn
LBB0_6:
	and	w22, w25, w22
LBB0_7:
	ldr	x0, [x21]
	add	x1, sp, #8
	bl	_alloc_can_skb
	cbz	x0, LBB0_12
; %bb.8:
	mov	x21, x0
	ldr	x8, [sp, #8]
	str	w22, [x8]
	mov	x0, x19
	mov	x1, x20
	bl	_ucan_get_can_dlc
	mov	x2, x0
	ldr	x8, [sp, #8]
	str	x0, [x8, #8]
	ldr	w9, [x8]
Lloh24:
	adrp	x10, _CAN_RTR_FLAG@GOTPAGE
Lloh25:
	ldr	x10, [x10, _CAN_RTR_FLAG@GOTPAGEOFF]
Lloh26:
	ldr	w10, [x10]
	tst	w10, w9
	b.eq	LBB0_10
; %bb.9:
	ldr	w10, [x24]
	tst	w10, w9
	b.eq	LBB0_11
LBB0_10:
	ldr	w0, [x8, #16]
	ldr	w1, [x19]
	bl	_memcpy
	ldr	x8, [sp, #8]
	ldr	x2, [x8, #8]
LBB0_11:
	ldr	d0, [x23]
	movi.2s	v1, #1
	mov.s	v1[0], w2
	add.2s	v0, v0, v1
	str	d0, [x23]
	mov	x0, x21
	bl	_netif_rx
LBB0_12:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.cfi_endproc
                                        ; -- End function
	.comm	_UCAN_IN_HDR_SIZE,4,2           ; @UCAN_IN_HDR_SIZE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"invalid input message len: %d\n"

	.comm	_CAN_ERR_FLAG,4,2               ; @CAN_ERR_FLAG
	.comm	_CAN_CTRLMODE_BERR_REPORTING,4,2 ; @CAN_CTRLMODE_BERR_REPORTING
	.comm	_CAN_RTR_FLAG,4,2               ; @CAN_RTR_FLAG
	.comm	_CAN_EFF_FLAG,4,2               ; @CAN_EFF_FLAG
	.comm	_CAN_EFF_MASK,4,2               ; @CAN_EFF_MASK
	.comm	_CAN_SFF_MASK,4,2               ; @CAN_SFF_MASK
l_.str.1:                               ; @.str.1
	.asciz	"unexpected bits set (canid %x, mask %x)"

	.no_dead_strip	_ucan_rx_can_msg
.subsections_via_symbols
