	.file	"extr_waitq.c_waitq_link_reserve.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	waitq_link_reserve
	.type	waitq_link_reserve, @function
waitq_link_reserve:
.LFB0:
	.cfi_startproc
	endbr64
	sub	rsp, 8
	.cfi_def_cfa_offset 16
	xor	eax, eax
	call	get_preemption_level@PLT
	xor	edi, edi
	test	rax, rax
	je	.L9
.L2:
	call	assert@PLT
	xor	eax, eax
	call	wql_ensure_free_space@PLT
	mov	edi, DWORD PTR LT_RESERVED[rip]
	call	wql_alloc_link@PLT
	test	rax, rax
	je	.L5
	mov	eax, DWORD PTR [rax]
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L9:
	.cfi_restore_state
	call	current_thread@PLT
	mov	edi, eax
	call	waitq_wait_possible@PLT
	xor	edi, edi
	test	rax, rax
	setne	dil
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L5:
	xor	eax, eax
	add	rsp, 8
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE0:
	.size	waitq_link_reserve, .-waitq_link_reserve
	.comm	LT_RESERVED,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_waitq.c_waitq_link_reserve.c"
	.text
	.align	2
	.global	waitq_link_reserve
	.syntax unified
	.arm
	.fpu softvfp
	.type	waitq_link_reserve, %function
waitq_link_reserve:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, lr}
	bl	get_preemption_level
	cmp	r0, #0
	movne	r0, #0
	beq	.L8
.L2:
	bl	assert
	bl	wql_ensure_free_space
	ldr	r3, .L9
	ldr	r0, [r3]
	bl	wql_alloc_link
	cmp	r0, #0
	ldrne	r0, [r0]
	pop	{r4, pc}
.L8:
	bl	current_thread
	bl	waitq_wait_possible
	subs	r0, r0, #0
	movne	r0, #1
	b	.L2
.L10:
	.align	2
.L9:
	.word	LT_RESERVED
	.size	waitq_link_reserve, .-waitq_link_reserve
	.comm	LT_RESERVED,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
