	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ng_l2cap_new_con               ## -- Begin function ng_l2cap_new_con
	.p2align	4, 0x90
_ng_l2cap_new_con:                      ## @ng_l2cap_new_con
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r15d
	movl	%esi, %r12d
	movq	%rdi, %r14
	movq	_M_NETGRAPH_L2CAP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_M_NOWAIT@GOTPCREL(%rip), %rax
	movq	_M_ZERO@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	orl	(%rax), %edx
	movl	$56, %edi
	callq	_malloc
	movq	%rax, %rbx
	testq	%rax, %rax
	je	LBB0_4
## %bb.1:
	movq	%r14, 48(%rbx)
	movq	_NG_L2CAP_CON_CLOSED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 40(%rbx)
	movq	$0, 32(%rbx)
	movl	_ng_l2cap_new_con.fake_con_handle(%rip), %eax
	leal	1(%rax), %ecx
	movl	%ecx, _ng_l2cap_new_con.fake_con_handle(%rip)
	movl	%eax, 24(%rbx)
	cmpl	$4095, %eax                     ## imm = 0xFFF
	jl	LBB0_3
## %bb.2:
	movl	$3840, _ng_l2cap_new_con.fake_con_handle(%rip) ## imm = 0xF00
LBB0_3:
	leaq	20(%rbx), %rsi
	movl	%r12d, %edi
	movl	$4, %edx
	callq	_bcopy
	movl	%r15d, (%rbx)
	leaq	16(%rbx), %rdi
	callq	_ng_callout_init
	movq	_NG_L2CAP_FIRST_IDENT@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	decq	%rax
	movq	%rax, 8(%rbx)
	movq	%rbx, %rdi
	addq	$4, %rdi
	callq	_TAILQ_INIT
	movq	_next@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_LIST_INSERT_HEAD
LBB0_4:
	movq	%rbx, %rax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__DATA,__data
	.p2align	2                               ## @ng_l2cap_new_con.fake_con_handle
_ng_l2cap_new_con.fake_con_handle:
	.long	3840                            ## 0xf00

	.comm	_M_NETGRAPH_L2CAP,4,2           ## @M_NETGRAPH_L2CAP
	.comm	_M_NOWAIT,4,2                   ## @M_NOWAIT
	.comm	_M_ZERO,4,2                     ## @M_ZERO
	.comm	_NG_L2CAP_CON_CLOSED,4,2        ## @NG_L2CAP_CON_CLOSED
	.comm	_NG_L2CAP_FIRST_IDENT,8,3       ## @NG_L2CAP_FIRST_IDENT
	.comm	_next,4,2                       ## @next
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ng_l2cap_new_con               ; -- Begin function ng_l2cap_new_con
	.p2align	2
_ng_l2cap_new_con:                      ; @ng_l2cap_new_con
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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	x21, x2
	mov	x22, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _M_NETGRAPH_L2CAP@GOTPAGE
Lloh1:
	ldr	x8, [x8, _M_NETGRAPH_L2CAP@GOTPAGEOFF]
Lloh2:
	adrp	x9, _M_NOWAIT@GOTPAGE
Lloh3:
	ldr	x9, [x9, _M_NOWAIT@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
Lloh5:
	ldr	w8, [x9]
Lloh6:
	adrp	x9, _M_ZERO@GOTPAGE
Lloh7:
	ldr	x9, [x9, _M_ZERO@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	orr	w2, w9, w8
	mov	w0, #56
	bl	_malloc
	mov	x20, x0
	cbz	x0, LBB0_4
; %bb.1:
	str	x19, [x20, #48]
Lloh9:
	adrp	x8, _NG_L2CAP_CON_CLOSED@GOTPAGE
Lloh10:
	ldr	x8, [x8, _NG_L2CAP_CON_CLOSED@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	str	w8, [x20, #40]
	str	xzr, [x20, #32]
	adrp	x8, _ng_l2cap_new_con.fake_con_handle@PAGE
	ldr	w9, [x8, _ng_l2cap_new_con.fake_con_handle@PAGEOFF]
	add	w10, w9, #1
	str	w10, [x8, _ng_l2cap_new_con.fake_con_handle@PAGEOFF]
	str	w9, [x20, #24]
	cmp	w9, #4095
	b.lt	LBB0_3
; %bb.2:
	mov	w9, #3840
	str	w9, [x8, _ng_l2cap_new_con.fake_con_handle@PAGEOFF]
LBB0_3:
	add	x1, x20, #20
	mov	x0, x22
	mov	w2, #4
	bl	_bcopy
	str	w21, [x20]
	add	x0, x20, #16
	bl	_ng_callout_init
Lloh12:
	adrp	x8, _NG_L2CAP_FIRST_IDENT@GOTPAGE
Lloh13:
	ldr	x8, [x8, _NG_L2CAP_FIRST_IDENT@GOTPAGEOFF]
Lloh14:
	ldr	x8, [x8]
	sub	x8, x8, #1
	str	x8, [x20, #8]
	add	x0, x20, #4
	bl	_TAILQ_INIT
Lloh15:
	adrp	x8, _next@GOTPAGE
Lloh16:
	ldr	x8, [x8, _next@GOTPAGEOFF]
Lloh17:
	ldr	w2, [x8]
	mov	x0, x19
	mov	x1, x20
	bl	_LIST_INSERT_HEAD
LBB0_4:
	mov	x0, x20
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh4
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.section	__DATA,__data
	.p2align	2                               ; @ng_l2cap_new_con.fake_con_handle
_ng_l2cap_new_con.fake_con_handle:
	.long	3840                            ; 0xf00

	.comm	_M_NETGRAPH_L2CAP,4,2           ; @M_NETGRAPH_L2CAP
	.comm	_M_NOWAIT,4,2                   ; @M_NOWAIT
	.comm	_M_ZERO,4,2                     ; @M_ZERO
	.comm	_NG_L2CAP_CON_CLOSED,4,2        ; @NG_L2CAP_CON_CLOSED
	.comm	_NG_L2CAP_FIRST_IDENT,8,3       ; @NG_L2CAP_FIRST_IDENT
	.comm	_next,4,2                       ; @next
.subsections_via_symbols
