	.file	"extr_msm_gem_submit.c_submit_pin_objects.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	submit_pin_objects, @function
submit_pin_objects:
.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
	push	rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	sub	rsp, 24
	.cfi_def_cfa_offset 64
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 8[rsp], rax
	xor	eax, eax
	mov	eax, DWORD PTR 4[rdi]
	mov	DWORD PTR [rdi], 1
	test	eax, eax
	jle	.L8
	mov	rsi, QWORD PTR 8[rdi]
	mov	r13, rdi
	xor	ebp, ebp
	mov	r12, rsp
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L5:
	not	ecx
	mov	QWORD PTR [rax], rdi
	add	rbp, 1
	and	edx, ecx
	mov	DWORD PTR 8[rax], edx
	mov	DWORD PTR 0[r13], 0
	cmp	DWORD PTR 4[r13], ebp
	jle	.L8
.L7:
	lea	rax, 0[rbp+rbp*2]
	mov	r8d, DWORD PTR 16[r13]
	mov	rdx, r12
	lea	rbx, 0[0+rax*8]
	mov	rdi, QWORD PTR 16[rsi+rbx]
	mov	esi, r8d
	call	msm_gem_get_and_pin_iova@PLT
	test	eax, eax
	jne	.L1
	mov	rsi, QWORD PTR 8[r13]
	mov	rdi, QWORD PTR [rsp]
	mov	ecx, DWORD PTR BO_VALID[rip]
	lea	rax, [rsi+rbx]
	mov	edx, DWORD PTR 8[rax]
	or	edx, DWORD PTR BO_PINNED[rip]
	cmp	QWORD PTR [rax], rdi
	jne	.L5
	or	edx, ecx
	add	rbp, 1
	mov	DWORD PTR 8[rax], edx
	cmp	DWORD PTR 4[r13], ebp
	jg	.L7
.L8:
	xor	eax, eax
.L1:
	mov	rbx, QWORD PTR 8[rsp]
	xor	rbx, QWORD PTR fs:40
	jne	.L13
	add	rsp, 24
	.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
.L13:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	submit_pin_objects, .-submit_pin_objects
	.comm	BO_VALID,4,4
	.comm	BO_PINNED,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_msm_gem_submit.c_submit_pin_objects.c"
	.text
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC0:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	submit_pin_objects, %function
submit_pin_objects:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 0, uses_anonymous_args = 0
	mov	r3, #1
	push	{r4, r5, r6, r7, r8, r9, lr}
	ldr	r2, [r0, #4]
	ldr	r1, .L15
	sub	sp, sp, #12
	cmp	r2, #0
	ldr	r1, [r1]
	str	r1, [sp, #4]
	mov	r1,#0
	str	r3, [r0]
	ble	.L8
	mov	r7, r0
	mov	r4, #0
	ldr	r3, [r0, #8]
	ldr	r6, .L15+4
	ldr	r5, .L15+8
	b	.L7
.L13:
	ldr	r3, [r7, #8]
	ldr	lr, [r6]
	add	r1, r3, r1
	ldr	r2, [r1, #4]
	ldr	r9, [r3, r8, lsl #2]
	ldr	ip, [sp]
	orr	r2, r2, lr
	ldr	lr, [r5]
	cmp	r9, ip
	orreq	r2, r2, lr
	bicne	r2, r2, lr
	strne	ip, [r3, r8, lsl #2]
	streq	r2, [r1, #4]
	strne	r2, [r1, #4]
	ldr	r2, [r7, #4]
	add	r4, r4, #1
	strne	r0, [r7]
	cmp	r2, r4
	ble	.L8
.L7:
	add	r8, r4, r4, lsl #1
	add	r3, r3, r8, lsl #2
	ldr	r1, [r7, #12]
	mov	r2, sp
	ldr	r0, [r3, #8]
	bl	msm_gem_get_and_pin_iova
	cmp	r0, #0
	lsl	r1, r8, #2
	beq	.L13
.L1:
	ldr	r3, .L15
	ldr	r2, [r3]
	ldr	r3, [sp, #4]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L14
	add	sp, sp, #12
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, pc}
.L8:
	mov	r0, #0
	b	.L1
.L14:
	bl	__stack_chk_fail
.L16:
	.align	2
.L15:
	.word	.LC0
	.word	BO_PINNED
	.word	BO_VALID
	.size	submit_pin_objects, .-submit_pin_objects
	.comm	BO_VALID,4,4
	.comm	BO_PINNED,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
