	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_v831_disconnect                ## -- Begin function v831_disconnect
	.p2align	4, 0x90
_v831_disconnect:                       ## @v831_disconnect
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movl	$2, %edi
	callq	_sleep
	movq	_FD@GOTPCREL(%rip), %r14
	movl	(%r14), %edi
	testl	%edi, %edi
	jle	LBB0_2
## %bb.1:
	movq	_TIOCCDTR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%edx, %edx
	callq	_ioctl
	movl	(%r14), %edi
	leaq	-24(%rbp), %rbx
	movq	%rbx, %rsi
	callq	_tcgetattr
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_cfsetospeed
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_cfsetispeed
	movl	(%r14), %edi
	movq	_TCSAFLUSH@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdx
	callq	_tcsetattr
	movl	(%r14), %edi
	movq	_TIOCNXCL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%edx, %edx
	callq	_ioctl
	movl	(%r14), %edi
LBB0_2:
	callq	_close
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_FD,4,2                         ## @FD
	.comm	_TIOCCDTR,4,2                   ## @TIOCCDTR
	.comm	_TCSAFLUSH,4,2                  ## @TCSAFLUSH
	.comm	_TIOCNXCL,4,2                   ## @TIOCNXCL
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_v831_disconnect                ; -- Begin function v831_disconnect
	.p2align	2
_v831_disconnect:                       ; @v831_disconnect
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	mov	w0, #2
	bl	_sleep
Lloh0:
	adrp	x19, _FD@GOTPAGE
Lloh1:
	ldr	x19, [x19, _FD@GOTPAGEOFF]
	ldr	w0, [x19]
	cmp	w0, #1
	b.lt	LBB0_2
; %bb.1:
Lloh2:
	adrp	x8, _TIOCCDTR@GOTPAGE
Lloh3:
	ldr	x8, [x8, _TIOCCDTR@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	mov	x2, #0
	bl	_ioctl
	ldr	w0, [x19]
	add	x1, sp, #8
	bl	_tcgetattr
	add	x0, sp, #8
	mov	w1, #0
	bl	_cfsetospeed
	add	x0, sp, #8
	mov	w1, #0
	bl	_cfsetispeed
	ldr	w0, [x19]
Lloh5:
	adrp	x8, _TCSAFLUSH@GOTPAGE
Lloh6:
	ldr	x8, [x8, _TCSAFLUSH@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	add	x2, sp, #8
	bl	_tcsetattr
	ldr	w0, [x19]
Lloh8:
	adrp	x8, _TIOCNXCL@GOTPAGE
Lloh9:
	ldr	x8, [x8, _TIOCNXCL@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
	mov	x2, #0
	bl	_ioctl
	ldr	w0, [x19]
LBB0_2:
	bl	_close
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_FD,4,2                         ; @FD
	.comm	_TIOCCDTR,4,2                   ; @TIOCCDTR
	.comm	_TCSAFLUSH,4,2                  ; @TCSAFLUSH
	.comm	_TIOCNXCL,4,2                   ; @TIOCNXCL
.subsections_via_symbols
