	.file	"extr_i915_request.c_igt_request_rewind.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"A"
.LC1:
	.string	"B"
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC2:
	.string	"failed to cancel request (already executed)!\n"
	.align 8
.LC3:
	.string	"timed out waiting for high priority request\n"
	.align 8
.LC4:
	.string	"low priority request already completed\n"
	.text
	.p2align 4
	.type	igt_request_rewind, @function
igt_request_rewind:
.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	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	sub	rsp, 24
	.cfi_def_cfa_offset 80
	mov	eax, DWORD PTR EINVAL[rip]
	mov	DWORD PTR 12[rsp], eax
	call	mutex_lock@PLT
	lea	rsi, .LC0[rip]
	mov	rdi, rbp
	call	mock_context@PLT
	mov	esi, DWORD PTR RCS0[rip]
	mov	rdi, rax
	mov	r14, rax
	call	i915_gem_context_get_engine@PLT
	mov	rdi, rax
	mov	r13, rax
	call	IS_ERR@PLT
	mov	edi, eax
	call	GEM_BUG_ON@PLT
	mov	eax, DWORD PTR HZ[rip]
	mov	rdi, r13
	lea	esi, [rax+rax]
	call	mock_request@PLT
	mov	rdi, r13
	mov	r12, rax
	call	intel_context_put@PLT
	mov	ebx, DWORD PTR ENOMEM[rip]
	neg	ebx
	test	r12, r12
	je	.L3
	mov	rdi, r12
	call	i915_request_get@PLT
	mov	rdi, r12
	call	i915_request_add@PLT
	lea	rsi, .LC1[rip]
	mov	rdi, rbp
	call	mock_context@PLT
	mov	esi, DWORD PTR RCS0[rip]
	mov	rdi, rax
	mov	r15, rax
	call	i915_gem_context_get_engine@PLT
	mov	rdi, rax
	mov	rbx, rax
	call	IS_ERR@PLT
	mov	edi, eax
	call	GEM_BUG_ON@PLT
	mov	rdi, rbx
	xor	esi, esi
	call	mock_request@PLT
	mov	rdi, rbx
	mov	r13, rax
	call	intel_context_put@PLT
	mov	ebx, DWORD PTR ENOMEM[rip]
	neg	ebx
	test	r13, r13
	je	.L5
	mov	ebx, DWORD PTR 12[rsp]
	mov	rdi, r12
	neg	ebx
	call	mock_cancel_request@PLT
	test	eax, eax
	je	.L12
	mov	rdi, r13
	call	i915_request_get@PLT
	mov	rdi, r13
	call	i915_request_add@PLT
	xor	eax, eax
	call	rcu_read_lock@PLT
	mov	rax, QWORD PTR [r12]
	mov	rdi, r12
	call	[QWORD PTR [rax]]
	xor	eax, eax
	call	rcu_read_unlock@PLT
	mov	rdi, rbp
	call	mutex_unlock@PLT
	mov	edx, DWORD PTR HZ[rip]
	xor	esi, esi
	mov	rdi, r13
	call	i915_request_wait@PLT
	add	eax, DWORD PTR ETIME[rip]
	je	.L13
	mov	rdi, r12
	call	i915_request_completed@PLT
	test	rax, rax
	jne	.L14
	xor	ebx, ebx
.L8:
	mov	rdi, r13
	call	i915_request_put@PLT
	mov	rdi, rbp
	call	mutex_lock@PLT
.L5:
	mov	rdi, r15
	call	mock_context_close@PLT
	mov	rdi, r12
	call	i915_request_put@PLT
.L3:
	mov	rdi, r14
	call	mock_context_close@PLT
	mov	rdi, rbp
	call	mock_device_flush@PLT
	mov	rdi, rbp
	call	mutex_unlock@PLT
	add	rsp, 24
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	mov	eax, ebx
	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
.L14:
	.cfi_restore_state
	lea	rdi, .LC4[rip]
	call	pr_err@PLT
	jmp	.L8
	.p2align 4,,10
	.p2align 3
.L12:
	lea	rdi, .LC2[rip]
	call	pr_err@PLT
	mov	rdi, r13
	call	i915_request_add@PLT
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L13:
	lea	rdi, .LC3[rip]
	call	pr_err@PLT
	jmp	.L8
	.cfi_endproc
.LFE0:
	.size	igt_request_rewind, .-igt_request_rewind
	.comm	RCS0,4,4
	.comm	HZ,4,4
	.comm	ETIME,4,4
	.comm	ENOMEM,4,4
	.comm	EINVAL,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_i915_request.c_igt_request_rewind.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"A\000"
	.align	2
.LC1:
	.ascii	"B\000"
	.align	2
.LC2:
	.ascii	"failed to cancel request (already executed)!\012\000"
	.align	2
.LC3:
	.ascii	"timed out waiting for high priority request\012\000"
	.align	2
.LC4:
	.ascii	"low priority request already completed\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	igt_request_rewind, %function
igt_request_rewind:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r3, r4, r5, r6, r7, r8, r9, r10, fp, lr}
	mov	r5, r0
	ldr	r3, .L19
	ldr	fp, .L19+4
	ldr	r8, [r3]
	bl	mutex_lock
	ldr	r1, .L19+8
	mov	r0, r5
	bl	mock_context
	ldr	r1, [fp]
	mov	r7, r0
	bl	i915_gem_context_get_engine
	mov	r6, r0
	ldr	r10, .L19+12
	bl	IS_ERR
	bl	GEM_BUG_ON
	ldr	r1, [r10]
	mov	r0, r6
	lsl	r1, r1, #1
	bl	mock_request
	mov	r4, r0
	mov	r0, r6
	bl	intel_context_put
	cmp	r4, #0
	beq	.L14
	mov	r0, r4
	bl	i915_request_get
	mov	r0, r4
	bl	i915_request_add
	ldr	r1, .L19+16
	mov	r0, r5
	bl	mock_context
	ldr	r1, [fp]
	mov	r9, r0
	bl	i915_gem_context_get_engine
	mov	fp, r0
	bl	IS_ERR
	bl	GEM_BUG_ON
	mov	r1, #0
	mov	r0, fp
	bl	mock_request
	mov	r6, r0
	mov	r0, fp
	bl	intel_context_put
	cmp	r6, #0
	beq	.L15
	mov	r0, r4
	bl	mock_cancel_request
	cmp	r0, #0
	rsb	fp, r8, #0
	beq	.L16
	mov	r0, r6
	bl	i915_request_get
	mov	r0, r6
	bl	i915_request_add
	bl	rcu_read_lock
	ldr	r3, [r4]
	mov	r0, r4
	ldr	r3, [r3]
	blx	r3
	bl	rcu_read_unlock
	mov	r0, r5
	bl	mutex_unlock
	mov	r1, #0
	mov	r0, r6
	ldr	r2, [r10]
	bl	i915_request_wait
	ldr	r3, .L19+20
	ldr	r3, [r3]
	cmn	r0, r3
	beq	.L17
	mov	r0, r4
	bl	i915_request_completed
	subs	r8, r0, #0
	bne	.L18
.L8:
	mov	r0, r6
	bl	i915_request_put
	mov	r0, r5
	bl	mutex_lock
	b	.L5
.L15:
	ldr	r3, .L19+24
	ldr	r8, [r3]
	rsb	r8, r8, #0
.L5:
	mov	r0, r9
	bl	mock_context_close
	mov	r0, r4
	bl	i915_request_put
.L3:
	mov	r0, r7
	bl	mock_context_close
	mov	r0, r5
	bl	mock_device_flush
	mov	r0, r5
	bl	mutex_unlock
	mov	r0, r8
	pop	{r3, r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L14:
	ldr	r3, .L19+24
	ldr	r8, [r3]
	rsb	r8, r8, #0
	b	.L3
.L18:
	ldr	r0, .L19+28
	mov	r8, fp
	bl	pr_err
	b	.L8
.L16:
	ldr	r0, .L19+32
	bl	pr_err
	mov	r0, r6
	mov	r8, fp
	bl	i915_request_add
	b	.L5
.L17:
	ldr	r0, .L19+36
	mov	r8, fp
	bl	pr_err
	b	.L8
.L20:
	.align	2
.L19:
	.word	EINVAL
	.word	RCS0
	.word	.LC0
	.word	HZ
	.word	.LC1
	.word	ETIME
	.word	ENOMEM
	.word	.LC4
	.word	.LC2
	.word	.LC3
	.size	igt_request_rewind, .-igt_request_rewind
	.comm	RCS0,4,4
	.comm	HZ,4,4
	.comm	ETIME,4,4
	.comm	ENOMEM,4,4
	.comm	EINVAL,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
