	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_tipc_link_changeover           ## -- Begin function tipc_link_changeover
	.p2align	4, 0x90
_tipc_link_changeover:                  ## @tipc_link_changeover
	.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), %rax
	movq	(%rax), %rcx
	movq	(%rcx), %r15
	testq	%r15, %r15
	je	LBB0_15
## %bb.1:
	cmpl	$0, 8(%rax)
	je	LBB0_16
## %bb.2:
	movq	%rdi, %r12
	movl	32(%rdi), %ebx
	movq	16(%rdi), %r14
	movq	_CHANGEOVER_PROTOCOL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_ORIGINAL_MSG@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_INT_H_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	28(%rdi), %r8d
	leaq	-48(%rbp), %r13
	movq	%r13, %rdi
	callq	_msg_init
	movl	24(%r12), %esi
	movq	%r13, %rdi
	callq	_msg_set_bearer_id
	movq	%r13, %rdi
	movl	%ebx, %esi
	callq	_msg_set_msgcnt
	leaq	L_.str.1(%rip), %rdi
	movl	%ebx, %esi
	xorl	%eax, %eax
	callq	_dbg
	cmpq	$0, 16(%r12)
	je	LBB0_3
## %bb.6:
	testq	%r14, %r14
	je	LBB0_15
## %bb.7:
	movq	%r14, %rbx
	movq	(%r12), %rax
	movq	(%rax), %rax
	movq	(%rax), %rcx
	movq	%rcx, -64(%rbp)                 ## 8-byte Spill
	movq	8(%rax), %rax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	leaq	-48(%rbp), %r14
	jmp	LBB0_8
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_8 Depth=1
	movq	%r13, %rdi
	callq	_msg_link_selector
	movq	%r12, %rdi
	movq	%r14, %rsi
	movq	%r13, %rdx
	movl	%eax, %ecx
	callq	_tipc_link_tunnel
LBB0_14:                                ##   in Loop: Header=BB0_8 Depth=1
	movq	-72(%rbp), %rbx                 ## 8-byte Reload
	movq	(%rbx), %rbx
	testq	%rbx, %rbx
	je	LBB0_15
LBB0_8:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_12 Depth 2
	movq	%rbx, %rdi
	callq	_buf_msg
	movq	%rax, %r13
	movq	%rax, %rdi
	callq	_msg_user
	movq	_MSG_BUNDLER@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	movq	%rbx, -72(%rbp)                 ## 8-byte Spill
	jne	LBB0_13
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=1
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	cmpq	%rax, -64(%rbp)                 ## 8-byte Folded Reload
	je	LBB0_13
## %bb.10:                              ##   in Loop: Header=BB0_8 Depth=1
	movq	%r13, %rdi
	callq	_msg_get_wrapped
	movq	%rax, %rbx
	movq	%r13, %rdi
	callq	_msg_msgcnt
	testl	%eax, %eax
	je	LBB0_14
## %bb.11:                              ##   in Loop: Header=BB0_8 Depth=1
	movl	%eax, %r15d
	.p2align	4, 0x90
LBB0_12:                                ##   Parent Loop BB0_8 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	%r13, %rdi
	callq	_msg_seqno
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_msg_set_seqno
	movq	%rbx, %rdi
	callq	_msg_link_selector
	movq	%r12, %rdi
	movq	%r14, %rsi
	movq	%rbx, %rdx
	movl	%eax, %ecx
	callq	_tipc_link_tunnel
	movq	%rbx, %rdi
	callq	_msg_size
	movl	%eax, %edi
	callq	_align
	cltq
	leaq	(%rbx,%rax,4), %rbx
	decl	%r15d
	jne	LBB0_12
	jmp	LBB0_14
LBB0_16:
	leaq	L_.str(%rip), %rdi
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_warn                           ## TAILCALL
LBB0_3:
	movq	_INT_H_SIZE@GOTPCREL(%rip), %r13
	movl	(%r13), %edi
	callq	_buf_acquire
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	movq	%rax, %rbx
	movl	(%r13), %edx
	leaq	-48(%rbp), %r14
	movq	%rax, %rdi
	movq	%r14, %rsi
	callq	_skb_copy_to_linear_data
	movl	(%r13), %esi
	movq	%r14, %rdi
	callq	_msg_set_size
	movq	8(%r12), %rax
	movl	(%rax), %esi
	movq	8(%r15), %rax
	movl	(%rax), %edx
	leaq	L_.str.2(%rip), %rdi
	xorl	%eax, %eax
	callq	_dbg
	leaq	L_.str.3(%rip), %rsi
	movq	%r14, %rdi
	callq	_msg_dbg
	movq	%r15, %rdi
	movq	%rbx, %rsi
	callq	_tipc_link_send_buf
	jmp	LBB0_15
LBB0_5:
	leaq	L_.str.4(%rip), %rdi
	callq	_warn
LBB0_15:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Link changeover error, peer did not permit changeover\n"

	.comm	_CHANGEOVER_PROTOCOL,4,2        ## @CHANGEOVER_PROTOCOL
	.comm	_ORIGINAL_MSG,4,2               ## @ORIGINAL_MSG
	.comm	_INT_H_SIZE,4,2                 ## @INT_H_SIZE
L_.str.1:                               ## @.str.1
	.asciz	"Link changeover requires %u tunnel messages\n"

L_.str.2:                               ## @.str.2
	.asciz	"%c->%c:"

L_.str.3:                               ## @.str.3
	.asciz	"EMPTY>SEND>"

L_.str.4:                               ## @.str.4
	.asciz	"Link changeover error, unable to send changeover msg\n"

	.comm	_MSG_BUNDLER,8,3                ## @MSG_BUNDLER
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_tipc_link_changeover           ; -- Begin function tipc_link_changeover
	.p2align	2
_tipc_link_changeover:                  ; @tipc_link_changeover
	.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
	ldr	x8, [x0]
	ldr	x9, [x8]
	ldr	x21, [x9]
	cbz	x21, LBB0_15
; %bb.1:
	ldr	w8, [x8, #8]
	cbz	w8, LBB0_11
; %bb.2:
	mov	x19, x0
	ldr	x20, [x0, #16]
Lloh0:
	adrp	x8, _CHANGEOVER_PROTOCOL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _CHANGEOVER_PROTOCOL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x8, _ORIGINAL_MSG@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ORIGINAL_MSG@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
Lloh6:
	adrp	x23, _INT_H_SIZE@GOTPAGE
Lloh7:
	ldr	x23, [x23, _INT_H_SIZE@GOTPAGEOFF]
	ldr	w3, [x23]
	ldp	w4, w22, [x0, #28]
	add	x0, sp, #8
	bl	_msg_init
	ldr	w1, [x19, #24]
	add	x0, sp, #8
	bl	_msg_set_bearer_id
	add	x0, sp, #8
	mov	x1, x22
	bl	_msg_set_msgcnt
Lloh8:
	adrp	x0, l_.str.1@PAGE
Lloh9:
	add	x0, x0, l_.str.1@PAGEOFF
	mov	x1, x22
	bl	_dbg
	ldr	x8, [x19, #16]
	cbz	x8, LBB0_12
; %bb.3:
	cbz	x20, LBB0_15
; %bb.4:
	ldr	x8, [x19]
	ldr	x8, [x8]
	ldp	x24, x25, [x8]
Lloh10:
	adrp	x26, _MSG_BUNDLER@GOTPAGE
Lloh11:
	ldr	x26, [x26, _MSG_BUNDLER@GOTPAGEOFF]
	b	LBB0_7
LBB0_5:                                 ;   in Loop: Header=BB0_7 Depth=1
	bl	_msg_link_selector
	mov	x3, x0
	add	x1, sp, #8
	mov	x0, x19
	mov	x2, x21
	bl	_tipc_link_tunnel
LBB0_6:                                 ;   in Loop: Header=BB0_7 Depth=1
	ldr	x20, [x20]
	cbz	x20, LBB0_15
LBB0_7:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_10 Depth 2
	mov	x0, x20
	bl	_buf_msg
	mov	x21, x0
	bl	_msg_user
	ldr	x8, [x26]
	cmp	x0, x8
	mov	x0, x21
	ccmp	x24, x25, #4, eq
	b.eq	LBB0_5
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	bl	_msg_get_wrapped
	mov	x22, x0
	mov	x0, x21
	bl	_msg_msgcnt
	cbz	w0, LBB0_6
; %bb.9:                                ;   in Loop: Header=BB0_7 Depth=1
	mov	x23, x0
LBB0_10:                                ;   Parent Loop BB0_7 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	sub	w23, w23, #1
	mov	x0, x21
	bl	_msg_seqno
	mov	x1, x0
	mov	x0, x22
	bl	_msg_set_seqno
	mov	x0, x22
	bl	_msg_link_selector
	mov	x3, x0
	add	x1, sp, #8
	mov	x0, x19
	mov	x2, x22
	bl	_tipc_link_tunnel
	mov	x0, x22
	bl	_msg_size
	bl	_align
	add	x22, x22, w0, sxtw #2
	cbnz	w23, LBB0_10
	b	LBB0_6
LBB0_11:
Lloh12:
	adrp	x0, l_.str@PAGE
Lloh13:
	add	x0, x0, l_.str@PAGEOFF
	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	_warn
LBB0_12:
	ldr	w0, [x23]
	bl	_buf_acquire
	cbz	x0, LBB0_14
; %bb.13:
	mov	x20, x0
	ldr	w2, [x23]
	add	x1, sp, #8
	bl	_skb_copy_to_linear_data
	ldr	w1, [x23]
	add	x0, sp, #8
	bl	_msg_set_size
	ldr	x8, [x19, #8]
	ldr	w1, [x8]
	ldr	x8, [x21, #8]
	ldr	w8, [x8]
	str	x8, [sp]
Lloh14:
	adrp	x0, l_.str.2@PAGE
Lloh15:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_dbg
Lloh16:
	adrp	x1, l_.str.3@PAGE
Lloh17:
	add	x1, x1, l_.str.3@PAGEOFF
	add	x0, sp, #8
	bl	_msg_dbg
	mov	x0, x21
	mov	x1, x20
	bl	_tipc_link_send_buf
	b	LBB0_15
LBB0_14:
Lloh18:
	adrp	x0, l_.str.4@PAGE
Lloh19:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	_warn
LBB0_15:
	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 AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Link changeover error, peer did not permit changeover\n"

	.comm	_CHANGEOVER_PROTOCOL,4,2        ; @CHANGEOVER_PROTOCOL
	.comm	_ORIGINAL_MSG,4,2               ; @ORIGINAL_MSG
	.comm	_INT_H_SIZE,4,2                 ; @INT_H_SIZE
l_.str.1:                               ; @.str.1
	.asciz	"Link changeover requires %u tunnel messages\n"

l_.str.2:                               ; @.str.2
	.asciz	"%c->%c:"

l_.str.3:                               ; @.str.3
	.asciz	"EMPTY>SEND>"

l_.str.4:                               ; @.str.4
	.asciz	"Link changeover error, unable to send changeover msg\n"

	.comm	_MSG_BUNDLER,8,3                ; @MSG_BUNDLER
.subsections_via_symbols
