	.file	"extr_xpc_channel.c_xpc_initiate_disconnect.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	xpc_initiate_disconnect
	.type	xpc_initiate_disconnect, @function
xpc_initiate_disconnect:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	mov	ebp, edi
	mov	edi, 1
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	sub	rsp, 40
	.cfi_def_cfa_offset 96
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 24[rsp], rax
	xor	eax, eax
	test	ebp, ebp
	js	.L2
	xor	edi, edi
	cmp	DWORD PTR XPC_MAX_NCHANNELS[rip], ebp
	setle	dil
.L2:
	call	DBUG_ON@PLT
	cmp	WORD PTR xp_max_npartitions[rip], 0
	jle	.L3
	movsx	r12, ebp
	lea	rax, 16[rsp]
	xor	ebx, ebx
	mov	QWORD PTR 8[rsp], rax
	sal	r12, 3
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L4:
	add	ebx, 1
	cmp	WORD PTR xp_max_npartitions[rip], bx
	jle	.L3
.L6:
	mov	rdx, QWORD PTR xpc_partitions[rip]
	movsx	rax, bx
	lea	r14, [rdx+rax*8]
	mov	rdi, r14
	call	xpc_part_ref@PLT
	test	rax, rax
	je	.L4
	mov	r15, QWORD PTR [r14]
	add	r15, r12
	mov	rdi, r15
	lea	r13, 4[r15]
	call	xpc_msgqueue_ref@PLT
	mov	rsi, QWORD PTR 16[rsp]
	mov	rdi, r13
	call	spin_lock_irqsave@PLT
	mov	eax, DWORD PTR [r15]
	test	DWORD PTR XPC_C_DISCONNECTED[rip], eax
	je	.L16
.L5:
	mov	rsi, QWORD PTR 16[rsp]
	mov	rdi, r13
	add	ebx, 1
	call	spin_unlock_irqrestore@PLT
	mov	rdi, r15
	call	xpc_msgqueue_deref@PLT
	mov	rdi, r14
	call	xpc_part_deref@PLT
	cmp	WORD PTR xp_max_npartitions[rip], bx
	jg	.L6
.L3:
	mov	edi, ebp
	call	xpc_disconnect_wait@PLT
	mov	rax, QWORD PTR 24[rsp]
	xor	rax, QWORD PTR fs:40
	jne	.L17
	add	rsp, 40
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	pop	rbx
	.cfi_def_cfa_offset 48
	pop	rbp
	.cfi_def_cfa_offset 40
	pop	r12
	.cfi_def_cfa_offset 32
	pop	r13
	.cfi_def_cfa_offset 24
	pop	r14
	.cfi_def_cfa_offset 16
	pop	r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L16:
	.cfi_restore_state
	or	eax, DWORD PTR XPC_C_WDISCONNECT[rip]
	mov	rdx, QWORD PTR 8[rsp]
	mov	rdi, r15
	mov	DWORD PTR [r15], eax
	mov	esi, DWORD PTR xpUnregistering[rip]
	call	XPC_DISCONNECT_CHANNEL@PLT
	jmp	.L5
.L17:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	xpc_initiate_disconnect, .-xpc_initiate_disconnect
	.comm	xpc_partitions,8,8
	.comm	xp_max_npartitions,2,2
	.comm	xpUnregistering,4,4
	.comm	XPC_MAX_NCHANNELS,4,4
	.comm	XPC_C_WDISCONNECT,4,4
	.comm	XPC_C_DISCONNECTED,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_xpc_channel.c_xpc_initiate_disconnect.c"
	.text
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC0:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	xpc_initiate_disconnect
	.syntax unified
	.arm
	.fpu softvfp
	.type	xpc_initiate_disconnect, %function
xpc_initiate_disconnect:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	subs	r2, r0, #0
	sub	sp, sp, #20
	ldr	r3, .L17
	str	r2, [sp, #4]
	ldr	r3, [r3]
	str	r3, [sp, #12]
	mov	r3,#0
	movlt	r0, #1
	blt	.L2
	ldr	r3, .L17+4
	ldr	r0, [r3]
	cmp	r0, r2
	movgt	r0, #0
	movle	r0, #1
.L2:
	ldr	r7, .L17+8
	bl	DBUG_ON
	ldrsh	r3, [r7]
	cmp	r3, #0
	ble	.L3
	mov	r5, #0
	ldr	r3, [sp, #4]
	mov	r4, r5
	ldr	r8, .L17+12
	ldr	fp, .L17+16
	lsl	r10, r3, #3
	b	.L6
.L4:
	ldrsh	r3, [r7]
	add	r5, r5, #1
	lsl	r4, r5, #16
	cmp	r3, r4, asr #16
	ble	.L3
.L6:
	ldr	r9, [r8]
	asr	r6, r4, #16
	add	r4, r9, r4, asr #14
	mov	r0, r4
	bl	xpc_part_ref
	cmp	r0, #0
	beq	.L4
	ldr	r3, [r9, r6, lsl #2]
	add	r6, r3, r10
	mov	r0, r6
	add	r9, r6, #4
	str	r3, [sp]
	bl	xpc_msgqueue_ref
	ldr	r1, [sp, #8]
	mov	r0, r9
	bl	spin_lock_irqsave
	ldr	r3, [sp]
	ldr	r2, [fp]
	ldr	r1, [r3, r10]
	tst	r1, r2
	beq	.L15
.L5:
	ldr	r1, [sp, #8]
	mov	r0, r9
	bl	spin_unlock_irqrestore
	mov	r0, r6
	bl	xpc_msgqueue_deref
	mov	r0, r4
	bl	xpc_part_deref
	b	.L4
.L3:
	ldr	r0, [sp, #4]
	bl	xpc_disconnect_wait
	ldr	r3, .L17
	ldr	r2, [r3]
	ldr	r3, [sp, #12]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L16
	add	sp, sp, #20
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L15:
	ldr	r2, .L17+20
	ldr	r0, [r2]
	add	r2, sp, #8
	orr	r1, r0, r1
	str	r1, [r3, r10]
	ldr	r3, .L17+24
	mov	r0, r6
	ldr	r1, [r3]
	bl	XPC_DISCONNECT_CHANNEL
	b	.L5
.L16:
	bl	__stack_chk_fail
.L18:
	.align	2
.L17:
	.word	.LC0
	.word	XPC_MAX_NCHANNELS
	.word	xp_max_npartitions
	.word	xpc_partitions
	.word	XPC_C_DISCONNECTED
	.word	XPC_C_WDISCONNECT
	.word	xpUnregistering
	.size	xpc_initiate_disconnect, .-xpc_initiate_disconnect
	.comm	xpc_partitions,4,4
	.comm	xp_max_npartitions,2,2
	.comm	xpUnregistering,4,4
	.comm	XPC_MAX_NCHANNELS,4,4
	.comm	XPC_C_WDISCONNECT,4,4
	.comm	XPC_C_DISCONNECTED,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
