	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function isdn_tty_cmd_ATA
_isdn_tty_cmd_ATA:                      ## @isdn_tty_cmd_ATA
	.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	$32, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	movq	_UART_MSR_RI@GOTPCREL(%rip), %r14
	movl	(%r14), %eax
	testl	%eax, (%rdi)
	je	LBB0_2
## %bb.1:
	movq	$0, 72(%rbx)
	movl	64(%rbx), %edi
	movq	_dev@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%rax), %rax
	movq	8(%rbx), %rcx
	movl	(%rax,%rcx,4), %esi
	callq	_strcpy
	movq	24(%rbx), %rax
	movq	_REG_RINGCNT@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movl	$0, (%rax,%rcx,4)
	movl	(%r14), %ecx
	notl	%ecx
	andl	%ecx, (%rbx)
	movq	_REG_L2PROT@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movl	(%rax,%rcx,4), %eax
	movl	48(%rbx), %ecx
	movl	%ecx, -32(%rbp)
	movq	_ISDN_CMD_SETL2@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, -48(%rbp)
	movl	%eax, %ecx
	shll	$8, %ecx
	movslq	%ecx, %rcx
	addq	40(%rbx), %rcx
	movq	%rcx, -40(%rbp)
	movl	%eax, 16(%rbx)
	leaq	-48(%rbp), %r14
	movq	%r14, %rdi
	callq	_isdn_command
	movl	48(%rbx), %eax
	movl	%eax, -32(%rbp)
	movq	_ISDN_CMD_SETL3@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -48(%rbp)
	movq	24(%rbx), %rax
	movq	_REG_L3PROT@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movl	(%rax,%rcx,4), %eax
	shll	$8, %eax
	cltq
	addq	40(%rbx), %rax
	movq	%rax, -40(%rbp)
	movq	%r14, %rdi
	callq	_isdn_command
	movl	48(%rbx), %eax
	movl	%eax, -32(%rbp)
	movq	40(%rbx), %rax
	movq	%rax, -40(%rbp)
	movq	_ISDN_CMD_ACCEPTD@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -48(%rbp)
	movl	$16, 20(%rbx)
	movq	$0, 32(%rbx)
	movq	%r14, %rdi
	callq	_isdn_command
	movq	_ISDN_TIMER_CARRIER@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	$1, %esi
	callq	_isdn_timer_ctrl
	addq	$32, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_2:
	movq	_RESULT_NO_ANSWER@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	addq	$32, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_isdn_tty_modem_result          ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_UART_MSR_RI,4,2                ## @UART_MSR_RI
	.comm	_dev,8,3                        ## @dev
	.comm	_REG_RINGCNT,8,3                ## @REG_RINGCNT
	.comm	_REG_L2PROT,8,3                 ## @REG_L2PROT
	.comm	_ISDN_CMD_SETL2,4,2             ## @ISDN_CMD_SETL2
	.comm	_ISDN_CMD_SETL3,4,2             ## @ISDN_CMD_SETL3
	.comm	_REG_L3PROT,8,3                 ## @REG_L3PROT
	.comm	_ISDN_CMD_ACCEPTD,4,2           ## @ISDN_CMD_ACCEPTD
	.comm	_ISDN_TIMER_CARRIER,4,2         ## @ISDN_TIMER_CARRIER
	.comm	_RESULT_NO_ANSWER,4,2           ## @RESULT_NO_ANSWER
	.comm	_ISDN_PROTO_L2_FAX,4,2          ## @ISDN_PROTO_L2_FAX
	.comm	_ISDN_PROTO_L2_MODEM,4,2        ## @ISDN_PROTO_L2_MODEM
	.comm	_ISDN_PROTO_L2_TRANS,4,2        ## @ISDN_PROTO_L2_TRANS
	.comm	_ISDN_PROTO_L2_X75I,4,2         ## @ISDN_PROTO_L2_X75I
	.comm	_ISDN_TTY_FAX_CONN_IN,4,2       ## @ISDN_TTY_FAX_CONN_IN
	.comm	_REG_SI1,8,3                    ## @REG_SI1
	.comm	_REG_SI1I,8,3                   ## @REG_SI1I
	.no_dead_strip	_isdn_tty_cmd_ATA
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function isdn_tty_cmd_ATA
_isdn_tty_cmd_ATA:                      ; @isdn_tty_cmd_ATA
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	ldr	w8, [x0]
Lloh0:
	adrp	x20, _UART_MSR_RI@GOTPAGE
Lloh1:
	ldr	x20, [x20, _UART_MSR_RI@GOTPAGEOFF]
	ldr	w9, [x20]
	tst	w9, w8
	b.eq	LBB0_2
; %bb.1:
	str	xzr, [x19, #72]
Lloh2:
	adrp	x8, _dev@GOTPAGE
Lloh3:
	ldr	x8, [x8, _dev@GOTPAGEOFF]
	ldr	w0, [x19, #64]
Lloh4:
	ldr	x8, [x8]
	ldr	x8, [x8]
	ldr	x9, [x19, #8]
	ldr	w1, [x8, x9, lsl #2]
	bl	_strcpy
	ldr	x8, [x19, #24]
Lloh5:
	adrp	x9, _REG_RINGCNT@GOTPAGE
Lloh6:
	ldr	x9, [x9, _REG_RINGCNT@GOTPAGEOFF]
Lloh7:
	ldr	x9, [x9]
	str	wzr, [x8, x9, lsl #2]
	ldr	w9, [x20]
	ldr	w10, [x19]
	bic	w9, w10, w9
	str	w9, [x19]
Lloh8:
	adrp	x9, _REG_L2PROT@GOTPAGE
Lloh9:
	ldr	x9, [x9, _REG_L2PROT@GOTPAGEOFF]
Lloh10:
	ldr	x9, [x9]
	ldr	w8, [x8, x9, lsl #2]
	ldr	w9, [x19, #48]
	str	w9, [sp, #16]
Lloh11:
	adrp	x9, _ISDN_CMD_SETL2@GOTPAGE
Lloh12:
	ldr	x9, [x9, _ISDN_CMD_SETL2@GOTPAGEOFF]
Lloh13:
	ldr	w9, [x9]
	str	w9, [sp]
	ldr	x9, [x19, #40]
	lsl	w10, w8, #8
	add	x9, x9, w10, sxtw
	str	x9, [sp, #8]
	str	w8, [x19, #16]
	mov	x0, sp
	bl	_isdn_command
	ldr	w8, [x19, #48]
Lloh14:
	adrp	x9, _ISDN_CMD_SETL3@GOTPAGE
Lloh15:
	ldr	x9, [x9, _ISDN_CMD_SETL3@GOTPAGEOFF]
Lloh16:
	ldr	w9, [x9]
	str	w8, [sp, #16]
	str	w9, [sp]
	ldr	x8, [x19, #40]
	ldr	x9, [x19, #24]
Lloh17:
	adrp	x10, _REG_L3PROT@GOTPAGE
Lloh18:
	ldr	x10, [x10, _REG_L3PROT@GOTPAGEOFF]
Lloh19:
	ldr	x10, [x10]
	ldr	w9, [x9, x10, lsl #2]
	lsl	w9, w9, #8
	add	x8, x8, w9, sxtw
	str	x8, [sp, #8]
	mov	x0, sp
	bl	_isdn_command
	ldr	w8, [x19, #48]
	str	w8, [sp, #16]
	ldr	x8, [x19, #40]
Lloh20:
	adrp	x9, _ISDN_CMD_ACCEPTD@GOTPAGE
Lloh21:
	ldr	x9, [x9, _ISDN_CMD_ACCEPTD@GOTPAGEOFF]
	str	x8, [sp, #8]
Lloh22:
	ldr	w8, [x9]
	str	w8, [sp]
	mov	w8, #16
	str	w8, [x19, #20]
	str	xzr, [x19, #32]
	mov	x0, sp
	bl	_isdn_command
Lloh23:
	adrp	x8, _ISDN_TIMER_CARRIER@GOTPAGE
Lloh24:
	ldr	x8, [x8, _ISDN_TIMER_CARRIER@GOTPAGEOFF]
Lloh25:
	ldr	w0, [x8]
	mov	w1, #1
	bl	_isdn_timer_ctrl
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
LBB0_2:
Lloh26:
	adrp	x8, _RESULT_NO_ANSWER@GOTPAGE
Lloh27:
	ldr	x8, [x8, _RESULT_NO_ANSWER@GOTPAGEOFF]
Lloh28:
	ldr	w0, [x8]
	mov	x1, x19
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #64
	b	_isdn_tty_modem_result
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.cfi_endproc
                                        ; -- End function
	.comm	_UART_MSR_RI,4,2                ; @UART_MSR_RI
	.comm	_dev,8,3                        ; @dev
	.comm	_REG_RINGCNT,8,3                ; @REG_RINGCNT
	.comm	_REG_L2PROT,8,3                 ; @REG_L2PROT
	.comm	_ISDN_CMD_SETL2,4,2             ; @ISDN_CMD_SETL2
	.comm	_ISDN_CMD_SETL3,4,2             ; @ISDN_CMD_SETL3
	.comm	_REG_L3PROT,8,3                 ; @REG_L3PROT
	.comm	_ISDN_CMD_ACCEPTD,4,2           ; @ISDN_CMD_ACCEPTD
	.comm	_ISDN_TIMER_CARRIER,4,2         ; @ISDN_TIMER_CARRIER
	.comm	_RESULT_NO_ANSWER,4,2           ; @RESULT_NO_ANSWER
	.comm	_ISDN_PROTO_L2_FAX,4,2          ; @ISDN_PROTO_L2_FAX
	.comm	_ISDN_PROTO_L2_MODEM,4,2        ; @ISDN_PROTO_L2_MODEM
	.comm	_ISDN_PROTO_L2_TRANS,4,2        ; @ISDN_PROTO_L2_TRANS
	.comm	_ISDN_PROTO_L2_X75I,4,2         ; @ISDN_PROTO_L2_X75I
	.comm	_ISDN_TTY_FAX_CONN_IN,4,2       ; @ISDN_TTY_FAX_CONN_IN
	.comm	_REG_SI1,8,3                    ; @REG_SI1
	.comm	_REG_SI1I,8,3                   ; @REG_SI1I
	.no_dead_strip	_isdn_tty_cmd_ATA
.subsections_via_symbols
