	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cmtp_session
_cmtp_session:                          ## @cmtp_session
	.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	%rdi, %r15
	movq	8(%rdi), %rax
	movq	8(%rax), %r13
	leaq	L_.str(%rip), %rdi
	movq	%r15, %rsi
	callq	_BT_DBG
	movl	20(%r15), %esi
	leaq	L_.str.1(%rip), %rdi
	callq	_daemonize
	movq	_current@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edi
	movl	$-15, %esi
	callq	_set_user_nice
	movl	(%rbx), %esi
	leaq	-44(%rbp), %rbx
	movq	%rbx, %rdi
	callq	_init_waitqueue_entry
	movl	8(%r13), %edi
	movq	%rbx, %rsi
	callq	_add_wait_queue
	leaq	16(%r15), %r14
	movq	%r14, %rdi
	callq	_atomic_read
	testl	%eax, %eax
	je	LBB0_1
LBB0_7:
	movq	_TASK_RUNNING@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_set_current_state
	movl	8(%r13), %edi
	leaq	-44(%rbp), %rsi
	callq	_remove_wait_queue
	movq	_cmtp_session_sem@GOTPCREL(%rip), %rdi
	callq	_down_write
	movl	(%r15), %eax
	movq	_CMTP_LOOPBACK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	btl	%ecx, %eax
	jb	LBB0_9
## %bb.8:
	movq	%r15, %rdi
	callq	_cmtp_detach_device
LBB0_9:
	movq	8(%r15), %rax
	movl	(%rax), %edi
	callq	_fput
	movq	%r15, %rdi
	callq	___cmtp_unlink_session
	movq	_cmtp_session_sem@GOTPCREL(%rip), %rdi
	callq	_up_write
	movq	%r15, %rdi
	callq	_kfree
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	leaq	12(%r13), %r12
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	%r15, %rdi
	callq	_cmtp_process_transmit
	xorl	%eax, %eax
	callq	_schedule
	movq	%r14, %rdi
	callq	_atomic_read
	testl	%eax, %eax
	jne	LBB0_7
LBB0_2:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_5 Depth 2
	movq	_TASK_INTERRUPTIBLE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_set_current_state
	movq	(%r13), %rax
	movq	_BT_CONNECTED@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_7
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%r12, %rdi
	callq	_skb_dequeue
	testq	%rax, %rax
	je	LBB0_6
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%rax, %rbx
	.p2align	4, 0x90
LBB0_5:                                 ##   Parent Loop BB0_2 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	%rbx, %rdi
	callq	_skb_orphan
	movq	%r15, %rdi
	movq	%rbx, %rsi
	callq	_cmtp_recv_frame
	movq	%r12, %rdi
	callq	_skb_dequeue
	movq	%rax, %rbx
	testq	%rax, %rax
	jne	LBB0_5
	jmp	LBB0_6
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"session %p"

L_.str.1:                               ## @.str.1
	.asciz	"kcmtpd_ctr_%d"

	.comm	_current,4,2                    ## @current
	.comm	_TASK_INTERRUPTIBLE,4,2         ## @TASK_INTERRUPTIBLE
	.comm	_BT_CONNECTED,8,3               ## @BT_CONNECTED
	.comm	_TASK_RUNNING,4,2               ## @TASK_RUNNING
	.comm	_cmtp_session_sem,4,2           ## @cmtp_session_sem
	.comm	_CMTP_LOOPBACK,4,2              ## @CMTP_LOOPBACK
	.no_dead_strip	_cmtp_session
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cmtp_session
_cmtp_session:                          ; @cmtp_session
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.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
	mov	x19, x0
	ldr	x8, [x0, #8]
	ldr	x23, [x8, #8]
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x19
	bl	_BT_DBG
	ldr	w1, [x19, #20]
Lloh2:
	adrp	x0, l_.str.1@PAGE
Lloh3:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_daemonize
Lloh4:
	adrp	x20, _current@GOTPAGE
Lloh5:
	ldr	x20, [x20, _current@GOTPAGEOFF]
	ldr	w0, [x20]
	mov	w1, #-15
	bl	_set_user_nice
	ldr	w1, [x20]
	add	x0, sp, #12
	bl	_init_waitqueue_entry
	ldr	w0, [x23, #8]
	add	x1, sp, #12
	bl	_add_wait_queue
	add	x20, x19, #16
	mov	x0, x20
	bl	_atomic_read
	cbz	w0, LBB0_4
LBB0_1:
Lloh6:
	adrp	x8, _TASK_RUNNING@GOTPAGE
Lloh7:
	ldr	x8, [x8, _TASK_RUNNING@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
	bl	_set_current_state
	ldr	w0, [x23, #8]
	add	x1, sp, #12
	bl	_remove_wait_queue
Lloh9:
	adrp	x0, _cmtp_session_sem@GOTPAGE
Lloh10:
	ldr	x0, [x0, _cmtp_session_sem@GOTPAGEOFF]
	bl	_down_write
	ldr	w8, [x19]
Lloh11:
	adrp	x9, _CMTP_LOOPBACK@GOTPAGE
Lloh12:
	ldr	x9, [x9, _CMTP_LOOPBACK@GOTPAGEOFF]
Lloh13:
	ldr	w9, [x9]
	lsr	w8, w8, w9
	tbnz	w8, #0, LBB0_3
; %bb.2:
	mov	x0, x19
	bl	_cmtp_detach_device
LBB0_3:
	ldr	x8, [x19, #8]
	ldr	w0, [x8]
	bl	_fput
	mov	x0, x19
	bl	___cmtp_unlink_session
Lloh14:
	adrp	x0, _cmtp_session_sem@GOTPAGE
Lloh15:
	ldr	x0, [x0, _cmtp_session_sem@GOTPAGEOFF]
	bl	_up_write
	mov	x0, x19
	bl	_kfree
	mov	w0, #0
	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
	add	sp, sp, #96
	ret
LBB0_4:
	add	x21, x23, #12
Lloh16:
	adrp	x24, _TASK_INTERRUPTIBLE@GOTPAGE
Lloh17:
	ldr	x24, [x24, _TASK_INTERRUPTIBLE@GOTPAGEOFF]
Lloh18:
	adrp	x25, _BT_CONNECTED@GOTPAGE
Lloh19:
	ldr	x25, [x25, _BT_CONNECTED@GOTPAGEOFF]
	b	LBB0_6
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	mov	x0, x19
	bl	_cmtp_process_transmit
	bl	_schedule
	mov	x0, x20
	bl	_atomic_read
	cbnz	w0, LBB0_1
LBB0_6:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_9 Depth 2
	ldr	w0, [x24]
	bl	_set_current_state
	ldr	x8, [x23]
	ldr	x9, [x25]
	cmp	x8, x9
	b.ne	LBB0_1
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	mov	x0, x21
	bl	_skb_dequeue
	cbz	x0, LBB0_5
; %bb.8:                                ;   in Loop: Header=BB0_6 Depth=1
	mov	x22, x0
LBB0_9:                                 ;   Parent Loop BB0_6 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	mov	x0, x22
	bl	_skb_orphan
	mov	x0, x19
	mov	x1, x22
	bl	_cmtp_recv_frame
	mov	x0, x21
	bl	_skb_dequeue
	mov	x22, x0
	cbnz	x0, LBB0_9
	b	LBB0_5
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"session %p"

l_.str.1:                               ; @.str.1
	.asciz	"kcmtpd_ctr_%d"

	.comm	_current,4,2                    ; @current
	.comm	_TASK_INTERRUPTIBLE,4,2         ; @TASK_INTERRUPTIBLE
	.comm	_BT_CONNECTED,8,3               ; @BT_CONNECTED
	.comm	_TASK_RUNNING,4,2               ; @TASK_RUNNING
	.comm	_cmtp_session_sem,4,2           ; @cmtp_session_sem
	.comm	_CMTP_LOOPBACK,4,2              ; @CMTP_LOOPBACK
	.no_dead_strip	_cmtp_session
.subsections_via_symbols
