	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function llc_ui_shutdown
_llc_ui_shutdown:                       ## @llc_ui_shutdown
	.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	%esi, %r15d
	movq	(%rdi), %r14
	movq	_ENOTCONN@GOTPCREL(%rip), %rax
	xorl	%r12d, %r12d
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	movq	%r14, %rdi
	callq	_lock_sock
	movq	(%r14), %rax
	movq	_TCP_ESTABLISHED@GOTPCREL(%rip), %rcx
	xorl	%edi, %edi
	cmpq	(%rcx), %rax
	setne	%dil
	callq	_unlikely
	testq	%rax, %rax
	jne	LBB0_6
## %bb.1:
	cmpl	$2, %r15d
	jne	LBB0_2
## %bb.3:
	movq	%r14, %rdi
	callq	_llc_send_disc
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_5
## %bb.4:
	movl	16(%r14), %esi
	movq	%r14, %rdi
	callq	_llc_ui_wait_for_disc
	movl	%eax, %ebx
LBB0_5:
	movq	%r14, %rdi
	callq	*8(%r14)
	jmp	LBB0_6
LBB0_2:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	subl	(%rax), %r12d
	movl	%r12d, %ebx
LBB0_6:
	movq	%r14, %rdi
	callq	_release_sock
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOTCONN,4,2                   ## @ENOTCONN
	.comm	_TCP_ESTABLISHED,8,3            ## @TCP_ESTABLISHED
	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_llc_ui_shutdown
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function llc_ui_shutdown
_llc_ui_shutdown:                       ; @llc_ui_shutdown
	.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	x20, x1
	ldr	x19, [x0]
Lloh0:
	adrp	x8, _ENOTCONN@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ENOTCONN@GOTPAGEOFF]
Lloh2:
	ldr	w21, [x8]
	mov	x0, x19
	bl	_lock_sock
	ldr	x8, [x19]
Lloh3:
	adrp	x9, _TCP_ESTABLISHED@GOTPAGE
Lloh4:
	ldr	x9, [x9, _TCP_ESTABLISHED@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x8, x9
	cset	w0, ne
	bl	_unlikely
	cbz	x0, LBB0_2
; %bb.1:
	neg	w20, w21
	b	LBB0_7
LBB0_2:
	cmp	w20, #2
	b.ne	LBB0_6
; %bb.3:
	mov	x0, x19
	bl	_llc_send_disc
	mov	x20, x0
	cbnz	w0, LBB0_5
; %bb.4:
	ldr	w1, [x19, #16]
	mov	x0, x19
	bl	_llc_ui_wait_for_disc
	mov	x20, x0
LBB0_5:
	ldr	x8, [x19, #8]
	mov	x0, x19
	blr	x8
	b	LBB0_7
LBB0_6:
Lloh6:
	adrp	x8, _EINVAL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	neg	w20, w8
LBB0_7:
	mov	x0, x19
	bl	_release_sock
	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	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOTCONN,4,2                   ; @ENOTCONN
	.comm	_TCP_ESTABLISHED,8,3            ; @TCP_ESTABLISHED
	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_llc_ui_shutdown
.subsections_via_symbols
