	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_tipc_link_send_long_buf        ## -- Begin function tipc_link_send_long_buf
	.p2align	4, 0x90
_tipc_link_send_long_buf:               ## @tipc_link_send_long_buf
	.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, %r14
	movq	%rdi, %r12
	movq	%rsi, %rdi
	callq	_buf_msg
	movq	%rax, %r15
	movq	%rax, %rdi
	callq	_msg_size
	movq	%rax, %r13
	movq	%r15, %rdi
	callq	_msg_data_sz
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movq	%r14, -64(%rbp)                 ## 8-byte Spill
	movq	(%r14), %rax
	movq	%rax, -88(%rbp)                 ## 8-byte Spill
	movq	%r12, %rdi
	callq	_link_max_pkt
	movq	_INT_H_SIZE@GOTPCREL(%rip), %r14
	subq	(%r14), %rax
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movq	%r15, %rdi
	callq	_msg_short
	testq	%rax, %rax
	movq	%r12, -80(%rbp)                 ## 8-byte Spill
	je	LBB0_2
## %bb.1:
	movq	(%r12), %rbx
	jmp	LBB0_3
LBB0_2:
	movq	%r15, %rdi
	callq	_msg_destnode
	movq	%rax, %rbx
LBB0_3:
	movq	%r15, %rdi
	callq	_msg_routed
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	movq	_tipc_own_addr@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_msg_set_prevnode
LBB0_5:
	movq	_MSG_FRAGMENTER@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_FIRST_FRAGMENT@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	(%r14), %rcx
	leaq	-48(%rbp), %r12
	movq	%r12, %rdi
	movq	%rbx, %r8
	callq	_msg_init
	movq	%r15, %rdi
	callq	_msg_link_selector
	movq	%r12, %rdi
	movl	%eax, %esi
	callq	_msg_set_link_selector
	movq	-80(%rbp), %r15                 ## 8-byte Reload
	movl	16(%r15), %edi
	leal	1(%rdi), %eax
	movl	%eax, 16(%r15)
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_mod
	movq	%r12, %rdi
	movl	%eax, %esi
	callq	_msg_set_long_msgno
	movl	$1, %esi
	movq	%r12, %rdi
	callq	_msg_set_fragm_no
	incl	12(%r15)
	testq	%r13, %r13
	jle	LBB0_14
## %bb.6:
	movl	$2, %ebx
	movq	-72(%rbp), %r15                 ## 8-byte Reload
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movq	%rbx, -96(%rbp)                 ## 8-byte Spill
	cmpq	%r15, %r13
	jg	LBB0_9
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	movq	_LAST_FRAGMENT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-48(%rbp), %rdi
	callq	_msg_set_type
	movq	%r13, %r15
LBB0_9:                                 ##   in Loop: Header=BB0_7 Depth=1
	movq	%r13, -72(%rbp)                 ## 8-byte Spill
	movq	(%r14), %rdi
	addq	%r15, %rdi
	callq	_buf_acquire
	testq	%rax, %rax
	je	LBB0_10
## %bb.11:                              ##   in Loop: Header=BB0_7 Depth=1
	movq	%rax, %r12
	movq	(%r14), %rsi
	addq	%r15, %rsi
	leaq	-48(%rbp), %r13
	movq	%r13, %rdi
	callq	_msg_set_size
	movq	(%r14), %rdx
	movq	%r12, %rdi
	movq	%r13, %rbx
	movq	%r13, %rsi
	callq	_skb_copy_to_linear_data
	movq	(%r14), %rsi
	movq	%r12, %rdi
	movq	-88(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rdx
	movq	%r15, %rcx
	callq	_skb_copy_to_linear_data_offset
	movq	-80(%rbp), %r13                 ## 8-byte Reload
	incl	8(%r13)
	movq	%r13, %rdi
	movq	%r12, %rsi
	callq	_tipc_link_send_buf
	movq	%r13, %rdi
	callq	_tipc_link_is_up
	testl	%eax, %eax
	je	LBB0_12
## %bb.13:                              ##   in Loop: Header=BB0_7 Depth=1
	movq	%rbx, %r12
	movq	%rbx, %rdi
	movq	-96(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rsi
	callq	_msg_set_fragm_no
	movq	_FRAGMENT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_msg_set_type
	incq	%rbx
	leaq	(%r14,%r15,4), %r14
	movq	%r14, -88(%rbp)                 ## 8-byte Spill
	movq	-72(%rbp), %r13                 ## 8-byte Reload
	subq	%r15, %r13
	movq	_INT_H_SIZE@GOTPCREL(%rip), %r14
	jg	LBB0_7
LBB0_14:
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	jmp	LBB0_15
LBB0_10:
	leaq	L_.str(%rip), %rdi
	callq	_warn
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subq	(%rax), %rbx
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
LBB0_15:
	callq	_buf_discard
	jmp	LBB0_16
LBB0_12:
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
LBB0_16:
	movl	%ebx, %eax
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_INT_H_SIZE,8,3                 ## @INT_H_SIZE
	.comm	_tipc_own_addr,4,2              ## @tipc_own_addr
	.comm	_MSG_FRAGMENTER,4,2             ## @MSG_FRAGMENTER
	.comm	_FIRST_FRAGMENT,4,2             ## @FIRST_FRAGMENT
	.comm	_LAST_FRAGMENT,4,2              ## @LAST_FRAGMENT
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Link unable to fragment message\n"

	.comm	_ENOMEM,8,3                     ## @ENOMEM
	.comm	_FRAGMENT,4,2                   ## @FRAGMENT
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_tipc_link_send_long_buf        ; -- Begin function tipc_link_send_long_buf
	.p2align	2
_tipc_link_send_long_buf:               ; @tipc_link_send_long_buf
	.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	x19, x1
	mov	x21, x0
	mov	x0, x1
	bl	_buf_msg
	mov	x25, x0
	bl	_msg_size
	mov	x22, x0
	mov	x0, x25
	bl	_msg_data_sz
	mov	x28, x0
	ldr	x23, [x19]
	mov	x0, x21
	bl	_link_max_pkt
	mov	x24, x0
Lloh0:
	adrp	x27, _INT_H_SIZE@GOTPAGE
Lloh1:
	ldr	x27, [x27, _INT_H_SIZE@GOTPAGEOFF]
	ldr	x20, [x27]
	mov	x0, x25
	bl	_msg_short
	cbz	x0, LBB0_2
; %bb.1:
	ldr	x26, [x21]
	b	LBB0_3
LBB0_2:
	mov	x0, x25
	bl	_msg_destnode
	mov	x26, x0
LBB0_3:
	mov	x0, x25
	bl	_msg_routed
	cbz	x0, LBB0_5
; %bb.4:
Lloh2:
	adrp	x8, _tipc_own_addr@GOTPAGE
Lloh3:
	ldr	x8, [x8, _tipc_own_addr@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	mov	x0, x25
	bl	_msg_set_prevnode
LBB0_5:
Lloh5:
	adrp	x8, _MSG_FRAGMENTER@GOTPAGE
Lloh6:
	ldr	x8, [x8, _MSG_FRAGMENTER@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
Lloh8:
	adrp	x8, _FIRST_FRAGMENT@GOTPAGE
Lloh9:
	ldr	x8, [x8, _FIRST_FRAGMENT@GOTPAGEOFF]
Lloh10:
	ldr	w2, [x8]
	ldr	x3, [x27]
	add	x0, sp, #8
	mov	x4, x26
	bl	_msg_init
	mov	x0, x25
	bl	_msg_link_selector
	mov	x1, x0
	add	x0, sp, #8
	bl	_msg_set_link_selector
	ldr	w0, [x21, #16]
	add	w8, w0, #1
	str	w8, [x21, #16]
	bl	_mod
	mov	x1, x0
	add	x0, sp, #8
	bl	_msg_set_long_msgno
	add	x0, sp, #8
	mov	w1, #1
	bl	_msg_set_fragm_no
	ldr	w8, [x21, #12]
	add	w8, w8, #1
	str	w8, [x21, #12]
	cmp	x22, #1
	b.lt	LBB0_14
; %bb.6:
	str	x28, [sp]                       ; 8-byte Folded Spill
	sub	x25, x24, x20
	mov	w24, #2
Lloh11:
	adrp	x28, _FRAGMENT@GOTPAGE
Lloh12:
	ldr	x28, [x28, _FRAGMENT@GOTPAGEOFF]
Lloh13:
	adrp	x20, _LAST_FRAGMENT@GOTPAGE
Lloh14:
	ldr	x20, [x20, _LAST_FRAGMENT@GOTPAGEOFF]
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	cmp	x22, x25
	b.gt	LBB0_9
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	ldr	w1, [x20]
	add	x0, sp, #8
	bl	_msg_set_type
	mov	x25, x22
LBB0_9:                                 ;   in Loop: Header=BB0_7 Depth=1
	ldr	x8, [x27]
	add	x0, x8, x25
	bl	_buf_acquire
	cbz	x0, LBB0_13
; %bb.10:                               ;   in Loop: Header=BB0_7 Depth=1
	mov	x26, x0
	ldr	x8, [x27]
	add	x1, x8, x25
	add	x0, sp, #8
	bl	_msg_set_size
	ldr	x2, [x27]
	add	x1, sp, #8
	mov	x0, x26
	bl	_skb_copy_to_linear_data
	ldr	x1, [x27]
	mov	x0, x26
	mov	x2, x23
	mov	x3, x25
	bl	_skb_copy_to_linear_data_offset
	ldr	w8, [x21, #8]
	add	w8, w8, #1
	str	w8, [x21, #8]
	mov	x0, x21
	mov	x1, x26
	bl	_tipc_link_send_buf
	mov	x0, x21
	bl	_tipc_link_is_up
	cbz	w0, LBB0_15
; %bb.11:                               ;   in Loop: Header=BB0_7 Depth=1
	add	x0, sp, #8
	mov	x1, x24
	bl	_msg_set_fragm_no
	sub	x22, x22, x25
	add	x23, x23, x25, lsl #2
	ldr	w1, [x28]
	add	x0, sp, #8
	bl	_msg_set_type
	add	x24, x24, #1
	cmp	x22, #0
	b.gt	LBB0_7
; %bb.12:
	ldr	x28, [sp]                       ; 8-byte Folded Reload
	b	LBB0_14
LBB0_13:
Lloh15:
	adrp	x0, l_.str@PAGE
Lloh16:
	add	x0, x0, l_.str@PAGEOFF
	bl	_warn
Lloh17:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh18:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh19:
	ldr	x8, [x8]
	neg	x28, x8
LBB0_14:
	mov	x0, x19
	bl	_buf_discard
	b	LBB0_16
LBB0_15:
	ldr	x28, [sp]                       ; 8-byte Folded Reload
LBB0_16:
	mov	x0, x28
	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	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpAdd	Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_INT_H_SIZE,8,3                 ; @INT_H_SIZE
	.comm	_tipc_own_addr,4,2              ; @tipc_own_addr
	.comm	_MSG_FRAGMENTER,4,2             ; @MSG_FRAGMENTER
	.comm	_FIRST_FRAGMENT,4,2             ; @FIRST_FRAGMENT
	.comm	_LAST_FRAGMENT,4,2              ; @LAST_FRAGMENT
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Link unable to fragment message\n"

	.comm	_ENOMEM,8,3                     ; @ENOMEM
	.comm	_FRAGMENT,4,2                   ; @FRAGMENT
.subsections_via_symbols
