	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sctp_handle_str_reset_request_tsn
_sctp_handle_str_reset_request_tsn:     ## @sctp_handle_str_reset_request_tsn
	.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	%rbx
	subq	$40, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %rbx
	movl	$0, -28(%rbp)
	movl	(%rdx), %edi
	callq	_ntohl
	movl	%eax, %r15d
	movl	(%rbx), %eax
	cmpl	%r15d, %eax
	jne	LBB0_8
## %bb.1:
	movq	24(%rbx), %rax
	movl	(%rax), %ecx
	movl	%ecx, 4(%rax)
	movq	_SCTP_ENABLE_CHANGE_ASSOC_REQ@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	testl	%ecx, 4(%rbx)
	je	LBB0_2
## %bb.3:
	movl	$24, %edi
	callq	_htons
	movl	%eax, -36(%rbp)
	movq	_SCTP_FORWARD_CUM_TSN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -40(%rbp)
	movq	$0, -48(%rbp)
	movq	56(%rbx), %rdi
	incq	%rdi
	callq	_htonl
	movl	%eax, -56(%rbp)
	leaq	-56(%rbp), %rsi
	leaq	-28(%rbp), %rdx
	movq	%rbx, %rdi
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	callq	_sctp_handle_forward_tsn
	movl	$1, %eax
	cmpl	$0, -28(%rbp)
	jne	LBB0_15
## %bb.4:
	movq	_SCTP_STREAM_RESET_TSN_DELTA@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	addq	%rax, 56(%rbx)
	movq	_sctp_logging_level@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_SCTP_BASE_SYSCTL
	movq	_SCTP_MAP_LOGGING_ENABLE@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_6
## %bb.5:
	movq	56(%rbx), %rdx
	movq	_SCTP_MAP_SLIDE_RESULT@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	xorl	%edi, %edi
	movl	$10, %esi
	callq	_sctp_log_map
LBB0_6:
	movq	56(%rbx), %rax
	movq	%rax, 80(%rbx)
	movq	%rax, 88(%rbx)
	incq	%rax
	movq	%rax, 32(%rbx)
	movl	72(%rbx), %edi
	movl	44(%rbx), %edx
	xorl	%esi, %esi
	callq	_memset
	movq	56(%rbx), %rax
	movq	%rax, 64(%rbx)
	movl	44(%rbx), %edx
	movl	48(%rbx), %edi
	xorl	%esi, %esi
	callq	_memset
	leaq	40(%rbx), %rdi
	movl	$1, %esi
	callq	_atomic_add_int
	movq	16(%rbx), %rax
	movl	(%rax), %ecx
	movl	%ecx, 4(%rax)
	movl	40(%rbx), %ecx
	movl	%ecx, (%rax)
	movq	8(%rbx), %rax
	movq	(%rax), %rcx
	movq	%rcx, 8(%rax)
	movq	32(%rbx), %rcx
	movq	%rcx, (%rax)
	movq	%rbx, %rdi
	xorl	%esi, %esi
	xorl	%edx, %edx
	callq	_sctp_reset_out_streams
	movq	%rbx, %rdi
	xorl	%esi, %esi
	xorl	%edx, %edx
	callq	_sctp_reset_in_stream
	movq	_SCTP_STREAM_RESET_RESULT_PERFORMED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	24(%rbx), %rcx
	movl	%eax, (%rcx)
	movl	40(%rbx), %esi
	movq	32(%rbx), %rdx
	incq	%rdx
	movq	%rbx, %rdi
	xorl	%ecx, %ecx
	callq	_sctp_notify_stream_reset_tsn
	jmp	LBB0_7
LBB0_8:
	leal	-1(%rax), %ecx
	cmpl	%r15d, %ecx
	jne	LBB0_11
## %bb.9:
	movq	24(%rbx), %rax
	movl	(%rax), %edx
	movq	8(%rbx), %rax
	movq	16(%rbx), %rcx
	movl	(%rcx), %ecx
	movq	(%rax), %r8
	jmp	LBB0_10
LBB0_11:
	addl	$-2, %eax
	cmpl	%r15d, %eax
	jne	LBB0_13
## %bb.12:
	movq	24(%rbx), %rax
	movl	4(%rax), %edx
	movq	8(%rbx), %rax
	movq	16(%rbx), %rcx
	movl	4(%rcx), %ecx
	movq	8(%rax), %r8
LBB0_10:
	movq	%r14, %rdi
	movl	%r15d, %esi
	callq	_sctp_add_stream_reset_result_tsn
	jmp	LBB0_14
LBB0_2:
	movq	_SCTP_STREAM_RESET_RESULT_DENIED@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, (%rax)
LBB0_7:
	movq	24(%rbx), %rax
	movl	(%rax), %edx
	movq	8(%rbx), %rax
	movq	16(%rbx), %rcx
	movl	(%rcx), %ecx
	movq	(%rax), %r8
	movq	%r14, %rdi
	movl	%r15d, %esi
	callq	_sctp_add_stream_reset_result_tsn
	incl	(%rbx)
	jmp	LBB0_14
LBB0_13:
	movq	_SCTP_STREAM_RESET_RESULT_ERR_BAD_SEQNO@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	movl	%r15d, %esi
	callq	_sctp_add_stream_reset_result
LBB0_14:
	xorl	%eax, %eax
LBB0_15:
	addq	$40, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SCTP_ENABLE_CHANGE_ASSOC_REQ,4,2 ## @SCTP_ENABLE_CHANGE_ASSOC_REQ
	.comm	_SCTP_STREAM_RESET_RESULT_DENIED,4,2 ## @SCTP_STREAM_RESET_RESULT_DENIED
	.comm	_SCTP_FORWARD_CUM_TSN,4,2       ## @SCTP_FORWARD_CUM_TSN
	.comm	_SCTP_STREAM_RESET_TSN_DELTA,8,3 ## @SCTP_STREAM_RESET_TSN_DELTA
	.comm	_sctp_logging_level,4,2         ## @sctp_logging_level
	.comm	_SCTP_MAP_LOGGING_ENABLE,4,2    ## @SCTP_MAP_LOGGING_ENABLE
	.comm	_SCTP_MAP_SLIDE_RESULT,4,2      ## @SCTP_MAP_SLIDE_RESULT
	.comm	_SCTP_STREAM_RESET_RESULT_PERFORMED,4,2 ## @SCTP_STREAM_RESET_RESULT_PERFORMED
	.comm	_SCTP_STREAM_RESET_RESULT_ERR_BAD_SEQNO,4,2 ## @SCTP_STREAM_RESET_RESULT_ERR_BAD_SEQNO
	.no_dead_strip	_sctp_handle_str_reset_request_tsn
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sctp_handle_str_reset_request_tsn
_sctp_handle_str_reset_request_tsn:     ; @sctp_handle_str_reset_request_tsn
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	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
	mov	x19, x1
	mov	x20, x0
	str	wzr, [sp, #4]
	ldr	w0, [x2]
	bl	_ntohl
	mov	x21, x0
	ldr	w8, [x20]
	cmp	w8, w0
	b.ne	LBB0_4
; %bb.1:
	ldr	x8, [x20, #24]
	ldr	w9, [x8]
	str	w9, [x8, #4]
	ldr	w9, [x20, #4]
Lloh0:
	adrp	x10, _SCTP_ENABLE_CHANGE_ASSOC_REQ@GOTPAGE
Lloh1:
	ldr	x10, [x10, _SCTP_ENABLE_CHANGE_ASSOC_REQ@GOTPAGEOFF]
Lloh2:
	ldr	w10, [x10]
	tst	w10, w9
	b.eq	LBB0_9
; %bb.2:
	mov	w0, #24
	bl	_htons
Lloh3:
	adrp	x8, _SCTP_FORWARD_CUM_TSN@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SCTP_FORWARD_CUM_TSN@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	stp	w8, w0, [sp, #24]
	str	xzr, [sp, #16]
	ldr	x8, [x20, #56]
	add	x0, x8, #1
	bl	_htonl
	str	w0, [sp, #8]
	add	x1, sp, #8
	add	x2, sp, #4
	mov	x0, x20
	mov	x3, #0
	mov	w4, #0
	bl	_sctp_handle_forward_tsn
	ldr	w8, [sp, #4]
	cbz	w8, LBB0_12
; %bb.3:
	mov	w0, #1
	b	LBB0_16
LBB0_4:
	sub	w9, w8, #1
	cmp	w9, w21
	b.ne	LBB0_6
; %bb.5:
	ldr	x8, [x20, #24]
	ldr	w2, [x8]
	ldp	x9, x8, [x20, #8]
	ldr	w3, [x8]
	ldr	x4, [x9]
	b	LBB0_8
LBB0_6:
	sub	w8, w8, #2
	cmp	w8, w21
	b.ne	LBB0_10
; %bb.7:
	ldr	x8, [x20, #24]
	ldr	w2, [x8, #4]
	ldp	x9, x8, [x20, #8]
	ldr	w3, [x8, #4]
	ldr	x4, [x9, #8]
LBB0_8:
	mov	x0, x19
	mov	x1, x21
	bl	_sctp_add_stream_reset_result_tsn
	b	LBB0_11
LBB0_9:
Lloh6:
	adrp	x9, _SCTP_STREAM_RESET_RESULT_DENIED@GOTPAGE
Lloh7:
	ldr	x9, [x9, _SCTP_STREAM_RESET_RESULT_DENIED@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	str	w9, [x8]
	b	LBB0_15
LBB0_10:
Lloh9:
	adrp	x8, _SCTP_STREAM_RESET_RESULT_ERR_BAD_SEQNO@GOTPAGE
Lloh10:
	ldr	x8, [x8, _SCTP_STREAM_RESET_RESULT_ERR_BAD_SEQNO@GOTPAGEOFF]
Lloh11:
	ldr	w2, [x8]
	mov	x0, x19
	mov	x1, x21
	bl	_sctp_add_stream_reset_result
LBB0_11:
	mov	w0, #0
	b	LBB0_16
LBB0_12:
Lloh12:
	adrp	x8, _SCTP_STREAM_RESET_TSN_DELTA@GOTPAGE
Lloh13:
	ldr	x8, [x8, _SCTP_STREAM_RESET_TSN_DELTA@GOTPAGEOFF]
Lloh14:
	ldr	x8, [x8]
	ldr	x9, [x20, #56]
	add	x8, x9, x8
	str	x8, [x20, #56]
Lloh15:
	adrp	x8, _sctp_logging_level@GOTPAGE
Lloh16:
	ldr	x8, [x8, _sctp_logging_level@GOTPAGEOFF]
Lloh17:
	ldr	w0, [x8]
	bl	_SCTP_BASE_SYSCTL
Lloh18:
	adrp	x8, _SCTP_MAP_LOGGING_ENABLE@GOTPAGE
Lloh19:
	ldr	x8, [x8, _SCTP_MAP_LOGGING_ENABLE@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	tst	w8, w0
	b.eq	LBB0_14
; %bb.13:
	ldr	x2, [x20, #56]
Lloh21:
	adrp	x8, _SCTP_MAP_SLIDE_RESULT@GOTPAGE
Lloh22:
	ldr	x8, [x8, _SCTP_MAP_SLIDE_RESULT@GOTPAGEOFF]
Lloh23:
	ldr	w3, [x8]
	mov	w0, #0
	mov	w1, #10
	bl	_sctp_log_map
LBB0_14:
	ldr	x8, [x20, #56]
	stp	x8, x8, [x20, #80]
	add	x8, x8, #1
	str	x8, [x20, #32]
	ldr	w0, [x20, #72]
	ldr	w2, [x20, #44]
	mov	w1, #0
	bl	_memset
	ldr	x8, [x20, #56]
	str	x8, [x20, #64]
	ldp	w2, w0, [x20, #44]
	mov	w1, #0
	bl	_memset
	add	x0, x20, #40
	mov	w1, #1
	bl	_atomic_add_int
	ldr	x8, [x20, #16]
	ldr	w9, [x8]
	str	w9, [x8, #4]
	ldr	w9, [x20, #40]
	str	w9, [x8]
	ldr	x8, [x20, #8]
	ldr	x9, [x8]
	str	x9, [x8, #8]
	ldr	x9, [x20, #32]
	str	x9, [x8]
	mov	x0, x20
	mov	w1, #0
	mov	x2, #0
	bl	_sctp_reset_out_streams
	mov	x0, x20
	mov	w1, #0
	mov	x2, #0
	bl	_sctp_reset_in_stream
Lloh24:
	adrp	x8, _SCTP_STREAM_RESET_RESULT_PERFORMED@GOTPAGE
Lloh25:
	ldr	x8, [x8, _SCTP_STREAM_RESET_RESULT_PERFORMED@GOTPAGEOFF]
Lloh26:
	ldr	w8, [x8]
	ldr	x9, [x20, #24]
	str	w8, [x9]
	ldr	w1, [x20, #40]
	ldr	x8, [x20, #32]
	add	x2, x8, #1
	mov	x0, x20
	mov	w3, #0
	bl	_sctp_notify_stream_reset_tsn
LBB0_15:
	ldr	x8, [x20, #24]
	ldr	w2, [x8]
	ldp	x9, x8, [x20, #8]
	ldr	w3, [x8]
	ldr	x4, [x9]
	mov	x0, x19
	mov	x1, x21
	bl	_sctp_add_stream_reset_result_tsn
	mov	w0, #0
	ldr	w8, [x20]
	add	w8, w8, #1
	str	w8, [x20]
LBB0_16:
	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
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.cfi_endproc
                                        ; -- End function
	.comm	_SCTP_ENABLE_CHANGE_ASSOC_REQ,4,2 ; @SCTP_ENABLE_CHANGE_ASSOC_REQ
	.comm	_SCTP_STREAM_RESET_RESULT_DENIED,4,2 ; @SCTP_STREAM_RESET_RESULT_DENIED
	.comm	_SCTP_FORWARD_CUM_TSN,4,2       ; @SCTP_FORWARD_CUM_TSN
	.comm	_SCTP_STREAM_RESET_TSN_DELTA,8,3 ; @SCTP_STREAM_RESET_TSN_DELTA
	.comm	_sctp_logging_level,4,2         ; @sctp_logging_level
	.comm	_SCTP_MAP_LOGGING_ENABLE,4,2    ; @SCTP_MAP_LOGGING_ENABLE
	.comm	_SCTP_MAP_SLIDE_RESULT,4,2      ; @SCTP_MAP_SLIDE_RESULT
	.comm	_SCTP_STREAM_RESET_RESULT_PERFORMED,4,2 ; @SCTP_STREAM_RESET_RESULT_PERFORMED
	.comm	_SCTP_STREAM_RESET_RESULT_ERR_BAD_SEQNO,4,2 ; @SCTP_STREAM_RESET_RESULT_ERR_BAD_SEQNO
	.no_dead_strip	_sctp_handle_str_reset_request_tsn
.subsections_via_symbols
