	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_line_open                      ## -- Begin function line_open
	.p2align	4, 0x90
_line_open:                             ## @line_open
	.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	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %r12
	movq	(%rsi), %r15
	shlq	$5, %r15
	movq	_ENODEV@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	leaq	(%rdi,%r15), %r13
	addq	$4, %r13
	movq	%r13, %rdi
	callq	_spin_lock
	cmpl	$0, 24(%r12,%r15)
	je	LBB0_6
## %bb.1:
	cmpl	$1, 8(%r14)
	movl	$0, %ebx
	jle	LBB0_2
LBB0_6:
	movq	%r13, %rdi
	callq	_spin_unlock
	jmp	LBB0_7
LBB0_2:
	leaq	(%r12,%r15), %rax
	movq	%r13, %rdi
	movq	%rax, %r13
	callq	_spin_unlock
	movq	%r13, 24(%r14)
	movq	%r14, 16(%r12,%r15)
	movq	%r13, %rdi
	callq	_enable_chan
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_7
## %bb.3:
	leaq	(%r12,%r15), %rdi
	addq	$12, %rdi
	movq	_line_timer_cb@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_INIT_DELAYED_WORK
	cmpl	$0, (%r13)
	jne	LBB0_5
## %bb.4:
	leaq	(%r12,%r15), %rdi
	addq	$8, %rdi
	movq	%r14, %rsi
	callq	_chan_enable_winch
	movl	$1, (%r13)
LBB0_5:
	leaq	(%r12,%r15), %rdi
	addq	$8, %rdi
	leaq	16(%r14), %rsi
	addq	$12, %r14
	movq	%r14, %rdx
	callq	_chan_window_size
	xorl	%ebx, %ebx
LBB0_7:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_line_timer_cb,4,2              ## @line_timer_cb
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_line_open                      ; -- Begin function line_open
	.p2align	2
_line_open:                             ; @line_open
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x1
	mov	x20, x0
	ldr	x24, [x1]
	add	x21, x0, x24, lsl #5
Lloh0:
	adrp	x8, _ENODEV@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
Lloh2:
	ldr	w23, [x8]
	add	x22, x21, #4
	mov	x0, x22
	bl	_spin_lock
	ldr	w8, [x21, #24]
	cbz	w8, LBB0_3
; %bb.1:
	ldr	w8, [x19, #8]
	cmp	w8, #1
	b.le	LBB0_5
; %bb.2:
	mov	w23, #0
	b	LBB0_4
LBB0_3:
	neg	w23, w23
LBB0_4:
	mov	x0, x22
	bl	_spin_unlock
	b	LBB0_9
LBB0_5:
	mov	x0, x22
	bl	_spin_unlock
	str	x21, [x19, #24]
	add	x22, x20, x24, lsl #5
	str	x19, [x22, #16]
	mov	x0, x21
	bl	_enable_chan
	mov	x23, x0
	cbnz	w0, LBB0_9
; %bb.6:
	add	x0, x22, #12
Lloh3:
	adrp	x8, _line_timer_cb@GOTPAGE
Lloh4:
	ldr	x8, [x8, _line_timer_cb@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	bl	_INIT_DELAYED_WORK
	ldr	w8, [x21]
	cbnz	w8, LBB0_8
; %bb.7:
	add	x8, x20, x24, lsl #5
	add	x0, x8, #8
	mov	x1, x19
	bl	_chan_enable_winch
	mov	w8, #1
	str	w8, [x21]
LBB0_8:
	add	x8, x20, x24, lsl #5
	add	x0, x8, #8
	add	x1, x19, #16
	add	x2, x19, #12
	bl	_chan_window_size
	mov	w23, #0
LBB0_9:
	mov	x0, x23
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_line_timer_cb,4,2              ; @line_timer_cb
.subsections_via_symbols
