	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function handle_tx
_handle_tx:                             ## @handle_tx
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r15
	movq	32(%rdi), %r13
	movl	$1, (%rdi)
	movq	_CAIF_SENDING@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	4(%r15), %r14
	movq	%r14, %rsi
	callq	_test_and_set_bit
	xorl	%ebx, %ebx
	testq	%rax, %rax
	jne	LBB0_17
## %bb.1:
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	leaq	24(%r15), %rdi
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	callq	_skb_peek
	testq	%rax, %rax
	je	LBB0_12
## %bb.2:
	movq	%rax, %r14
	jmp	LBB0_3
	.p2align	4, 0x90
LBB0_11:                                ##   in Loop: Header=BB0_3 Depth=1
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_skb_peek
	movq	%rax, %r14
	testq	%rax, %rax
	je	LBB0_12
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r14), %r12d
	movq	%r13, %rdi
	callq	_tty_write_room
	testl	%eax, %eax
	je	LBB0_12
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	movq	_ser_write_chunk@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ebx
	cmpl	%ebx, %eax
	cmovll	%eax, %ebx
	cmpl	%ebx, %r12d
	cmovll	%r12d, %ebx
	movq	_ser_loop@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	je	LBB0_5
## %bb.6:                               ##   in Loop: Header=BB0_3 Depth=1
	movl	4(%r14), %esi
	movq	%r13, %rdi
	xorl	%edx, %edx
	movl	%ebx, %ecx
	callq	_ldisc_receive
	jmp	LBB0_7
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_3 Depth=1
	movq	(%r13), %rax
	movl	4(%r14), %esi
	movq	%r13, %rdi
	movl	%ebx, %edx
	callq	*(%rax)
	movl	%eax, %ebx
	movq	%r15, %rdi
	callq	_update_tty_status
LBB0_7:                                 ##   in Loop: Header=BB0_3 Depth=1
	movq	8(%r15), %rax
	incl	4(%rax)
	addl	%ebx, (%rax)
	testl	%ebx, %ebx
	js	LBB0_8
## %bb.9:                               ##   in Loop: Header=BB0_3 Depth=1
	movq	%r14, %rdi
	movl	%ebx, %esi
	callq	_skb_pull
	cmpl	$0, (%r14)
	jne	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_3 Depth=1
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_skb_dequeue
	xorl	%edi, %edi
	cmpq	%r14, %rax
	setne	%dil
	callq	_WARN_ON
	movq	%r14, %rdi
	callq	_dev_consume_skb_any
	jmp	LBB0_11
LBB0_12:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rax
	movq	_SEND_QUEUE_LOW@GOTPCREL(%rip), %rcx
	xorl	%ebx, %ebx
	cmpq	(%rcx), %rax
	jle	LBB0_13
LBB0_8:
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	jmp	LBB0_16
LBB0_13:
	movq	_CAIF_FLOW_OFF_SENT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rsi
	callq	_test_and_clear_bit
	testq	%rax, %rax
	je	LBB0_16
## %bb.14:
	movq	16(%r15), %rcx
	testq	%rcx, %rcx
	je	LBB0_16
## %bb.15:
	movq	8(%r15), %rdi
	movq	_ON@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	*%rcx
LBB0_16:
	movq	_CAIF_SENDING@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%r14, %rsi
	callq	_clear_bit
LBB0_17:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_CAIF_SENDING,4,2               ## @CAIF_SENDING
	.comm	_ser_write_chunk,4,2            ## @ser_write_chunk
	.comm	_ser_loop,4,2                   ## @ser_loop
	.comm	_SEND_QUEUE_LOW,8,3             ## @SEND_QUEUE_LOW
	.comm	_CAIF_FLOW_OFF_SENT,4,2         ## @CAIF_FLOW_OFF_SENT
	.comm	_ON,4,2                         ## @ON
	.no_dead_strip	_handle_tx
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function handle_tx
_handle_tx:                             ; @handle_tx
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x20, x0
	ldr	x21, [x0, #32]
	mov	w8, #1
	str	w8, [x0]
Lloh0:
	adrp	x25, _CAIF_SENDING@GOTPAGE
Lloh1:
	ldr	x25, [x25, _CAIF_SENDING@GOTPAGEOFF]
	ldr	w0, [x25]
	add	x19, x20, #4
	mov	x1, x19
	bl	_test_and_set_bit
	cbz	x0, LBB0_2
; %bb.1:
	mov	w24, #0
	b	LBB0_18
LBB0_2:
	add	x22, x20, #24
	mov	x0, x22
	bl	_skb_peek
	cbz	x0, LBB0_12
; %bb.3:
	mov	x23, x0
Lloh2:
	adrp	x26, _ser_write_chunk@GOTPAGE
Lloh3:
	ldr	x26, [x26, _ser_write_chunk@GOTPAGEOFF]
Lloh4:
	adrp	x27, _ser_loop@GOTPAGE
Lloh5:
	ldr	x27, [x27, _ser_loop@GOTPAGEOFF]
	b	LBB0_5
LBB0_4:                                 ;   in Loop: Header=BB0_5 Depth=1
	mov	x0, x22
	bl	_skb_peek
	mov	x23, x0
	cbz	x0, LBB0_12
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w24, [x23]
	mov	x0, x21
	bl	_tty_write_room
	cbz	w0, LBB0_12
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	w8, [x26]
	cmp	w0, w8
	csel	w8, w0, w8, lt
	cmp	w24, w8
	csel	w24, w24, w8, lt
	ldr	w8, [x27]
	cbz	w8, LBB0_8
; %bb.7:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	w1, [x23, #4]
	mov	x0, x21
	mov	x2, #0
	mov	x3, x24
	bl	_ldisc_receive
	b	LBB0_9
LBB0_8:                                 ;   in Loop: Header=BB0_5 Depth=1
	ldr	x8, [x21]
	ldr	x8, [x8]
	ldr	w1, [x23, #4]
	mov	x0, x21
	mov	x2, x24
	blr	x8
	mov	x24, x0
	mov	x0, x20
	bl	_update_tty_status
LBB0_9:                                 ;   in Loop: Header=BB0_5 Depth=1
	ldr	x8, [x20, #8]
	ldr	d0, [x8]
	movi.2s	v1, #1
	mov.s	v1[0], w24
	add.2s	v0, v0, v1
	str	d0, [x8]
	tbnz	w24, #31, LBB0_17
; %bb.10:                               ;   in Loop: Header=BB0_5 Depth=1
	mov	x0, x23
	mov	x1, x24
	bl	_skb_pull
	ldr	w8, [x23]
	cbnz	w8, LBB0_4
; %bb.11:                               ;   in Loop: Header=BB0_5 Depth=1
	mov	x0, x22
	bl	_skb_dequeue
	cmp	x0, x23
	cset	w0, ne
	bl	_WARN_ON
	mov	x0, x23
	bl	_dev_consume_skb_any
	b	LBB0_4
LBB0_12:
	ldr	x8, [x22]
Lloh6:
	adrp	x9, _SEND_QUEUE_LOW@GOTPAGE
Lloh7:
	ldr	x9, [x9, _SEND_QUEUE_LOW@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	cmp	x8, x9
	b.gt	LBB0_16
; %bb.13:
Lloh9:
	adrp	x8, _CAIF_FLOW_OFF_SENT@GOTPAGE
Lloh10:
	ldr	x8, [x8, _CAIF_FLOW_OFF_SENT@GOTPAGEOFF]
Lloh11:
	ldr	w0, [x8]
	mov	x1, x19
	bl	_test_and_clear_bit
	cbz	x0, LBB0_16
; %bb.14:
	ldr	x8, [x20, #16]
	cbz	x8, LBB0_16
; %bb.15:
	ldr	x0, [x20, #8]
Lloh12:
	adrp	x9, _ON@GOTPAGE
Lloh13:
	ldr	x9, [x9, _ON@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x9]
	blr	x8
LBB0_16:
	mov	w24, #0
LBB0_17:
	ldr	w0, [x25]
	mov	x1, x19
	bl	_clear_bit
LBB0_18:
	mov	x0, x24
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_CAIF_SENDING,4,2               ; @CAIF_SENDING
	.comm	_ser_write_chunk,4,2            ; @ser_write_chunk
	.comm	_ser_loop,4,2                   ; @ser_loop
	.comm	_SEND_QUEUE_LOW,8,3             ; @SEND_QUEUE_LOW
	.comm	_CAIF_FLOW_OFF_SENT,4,2         ; @CAIF_FLOW_OFF_SENT
	.comm	_ON,4,2                         ; @ON
	.no_dead_strip	_handle_tx
.subsections_via_symbols
