	.file	"extr_gsc-m2m.c_gsc_m2m_ctx_stop_req.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	gsc_m2m_ctx_stop_req, @function
gsc_m2m_ctx_stop_req:
.LFB0:
	.cfi_startproc
	endbr64
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	push	r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	push	rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	mov	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	sub	rsp, 8
	.cfi_def_cfa_offset 48
	mov	r12, QWORD PTR [rdi]
	mov	edi, DWORD PTR 4[r12]
	call	v4l2_m2m_get_curr_priv@PLT
	mov	rdi, r12
	mov	rbx, rax
	call	gsc_m2m_pending@PLT
	cmp	rbp, rbx
	jne	.L3
	test	eax, eax
	jne	.L6
.L3:
	xor	eax, eax
.L1:
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	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
.L6:
	.cfi_restore_state
	mov	edi, DWORD PTR GSC_CTX_STOP_REQ[rip]
	mov	rsi, rbp
	call	gsc_ctx_state_lock_set@PLT
	mov	edi, DWORD PTR GSC_CTX_STOP_REQ[rip]
	mov	rsi, rbp
	mov	r13d, DWORD PTR GSC_SHUTDOWN_TIMEOUT[rip]
	call	gsc_ctx_state_is_set@PLT
	xor	esi, esi
	mov	edi, DWORD PTR [r12]
	mov	edx, r13d
	test	eax, eax
	sete	sil
	call	wait_event_timeout@PLT
	test	eax, eax
	jne	.L1
	mov	eax, DWORD PTR ETIMEDOUT[rip]
	neg	eax
	jmp	.L1
	.cfi_endproc
.LFE0:
	.size	gsc_m2m_ctx_stop_req, .-gsc_m2m_ctx_stop_req
	.comm	GSC_SHUTDOWN_TIMEOUT,4,4
	.comm	GSC_CTX_STOP_REQ,4,4
	.comm	ETIMEDOUT,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_gsc-m2m.c_gsc_m2m_ctx_stop_req.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	gsc_m2m_ctx_stop_req, %function
gsc_m2m_ctx_stop_req:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, lr}
	ldr	r6, [r0]
	mov	r4, r0
	ldr	r0, [r6, #4]
	bl	v4l2_m2m_get_curr_priv
	mov	r5, r0
	mov	r0, r6
	bl	gsc_m2m_pending
	clz	r3, r0
	lsr	r3, r3, #5
	cmp	r4, r5
	orrne	r3, r3, #1
	cmp	r3, #0
	beq	.L6
	mov	r0, #0
	pop	{r4, r5, r6, pc}
.L6:
	ldr	r5, .L7
	mov	r1, r4
	ldr	r0, [r5]
	bl	gsc_ctx_state_lock_set
	mov	r1, r4
	ldr	r0, [r5]
	ldr	r4, [r6]
	bl	gsc_ctx_state_is_set
	clz	r1, r0
	ldr	r3, .L7+4
	mov	r0, r4
	ldr	r2, [r3]
	lsr	r1, r1, #5
	bl	wait_event_timeout
	cmp	r0, #0
	ldreq	r3, .L7+8
	ldreq	r0, [r3]
	rsbeq	r0, r0, #0
	pop	{r4, r5, r6, pc}
.L8:
	.align	2
.L7:
	.word	GSC_CTX_STOP_REQ
	.word	GSC_SHUTDOWN_TIMEOUT
	.word	ETIMEDOUT
	.size	gsc_m2m_ctx_stop_req, .-gsc_m2m_ctx_stop_req
	.comm	GSC_SHUTDOWN_TIMEOUT,4,4
	.comm	GSC_CTX_STOP_REQ,4,4
	.comm	ETIMEDOUT,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
