	.file	"extr_linux_schedule.c_linux_wait_event_common.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"wevent"
	.text
	.p2align 4
	.globl	linux_wait_event_common
	.type	linux_wait_event_common, @function
linux_wait_event_common:
.LFB0:
	.cfi_startproc
	endbr64
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	mov	r13d, ecx
	push	r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	mov	r12d, edx
	push	rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	mov	rbp, r8
	push	rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	sub	rsp, 8
	.cfi_def_cfa_offset 48
	test	r8, r8
	je	.L2
	mov	rdi, r8
	call	spin_unlock_irq@PLT
.L2:
	test	r12d, r12d
	jle	.L7
	cmp	DWORD PTR MAX_SCHEDULE_TIMEOUT[rip], r12d
	mov	eax, 0
	cmove	r12d, eax
.L3:
	mov	rbx, QWORD PTR current[rip]
	mov	rax, QWORD PTR [rbx]
	mov	edi, DWORD PTR [rax]
	call	PHOLD@PLT
	mov	rdi, rbx
	call	sleepq_lock@PLT
	lea	rdi, 8[rbx]
	call	atomic_read@PLT
	cmp	rax, QWORD PTR TASK_WAKING[rip]
	je	.L4
	mov	ecx, r12d
	mov	r8d, r13d
	lea	rdx, .LC0[rip]
	mov	rsi, rbx
	mov	rdi, rbx
	call	linux_add_to_sleepqueue@PLT
	mov	r12d, eax
.L5:
	mov	rax, QWORD PTR [rbx]
	mov	edi, DWORD PTR [rax]
	call	PRELE@PLT
	test	rbp, rbp
	je	.L1
	mov	rdi, rbp
	call	spin_lock_irq@PLT
.L1:
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	eax, r12d
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L7:
	.cfi_restore_state
	mov	r12d, 1
	jmp	.L3
	.p2align 4,,10
	.p2align 3
.L4:
	mov	rdi, rbx
	xor	r12d, r12d
	call	sleepq_release@PLT
	jmp	.L5
	.cfi_endproc
.LFE0:
	.size	linux_wait_event_common, .-linux_wait_event_common
	.comm	current,8,8
	.comm	TASK_WAKING,8,8
	.comm	MAX_SCHEDULE_TIMEOUT,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_linux_schedule.c_linux_wait_event_common.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"wevent\000"
	.text
	.align	2
	.global	linux_wait_event_common
	.syntax unified
	.arm
	.fpu softvfp
	.type	linux_wait_event_common, %function
linux_wait_event_common:
	@ args = 4, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, lr}
	sub	sp, sp, #12
	ldr	r6, [sp, #32]
	mov	r4, r2
	cmp	r6, #0
	mov	r7, r3
	beq	.L2
	mov	r0, r6
	bl	spin_unlock_irq
.L2:
	cmp	r4, #0
	movle	r4, #1
	ble	.L3
	ldr	r3, .L16
	ldr	r3, [r3]
	cmp	r3, r4
	moveq	r4, #0
.L3:
	ldr	r3, .L16+4
	ldr	r5, [r3]
	ldr	r3, [r5]
	ldr	r0, [r3]
	bl	PHOLD
	mov	r0, r5
	bl	sleepq_lock
	add	r0, r5, #4
	bl	atomic_read
	ldr	r3, .L16+8
	ldr	r3, [r3]
	cmp	r0, r3
	beq	.L4
	mov	r3, r4
	mov	r1, r5
	mov	r0, r5
	ldr	r2, .L16+12
	str	r7, [sp]
	bl	linux_add_to_sleepqueue
	mov	r4, r0
.L5:
	ldr	r3, [r5]
	ldr	r0, [r3]
	bl	PRELE
	cmp	r6, #0
	beq	.L1
	mov	r0, r6
	bl	spin_lock_irq
.L1:
	mov	r0, r4
	add	sp, sp, #12
	@ sp needed
	pop	{r4, r5, r6, r7, pc}
.L4:
	mov	r0, r5
	bl	sleepq_release
	mov	r4, #0
	b	.L5
.L17:
	.align	2
.L16:
	.word	MAX_SCHEDULE_TIMEOUT
	.word	current
	.word	TASK_WAKING
	.word	.LC0
	.size	linux_wait_event_common, .-linux_wait_event_common
	.comm	current,4,4
	.comm	TASK_WAKING,4,4
	.comm	MAX_SCHEDULE_TIMEOUT,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
