	.file	"extr_mx1_camera.c_mx1_camera_set_bus_param.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	mx1_camera_set_bus_param, @function
mx1_camera_set_bus_param:
.LFB0:
	.cfi_startproc
	endbr64
	push	r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	mov	r12, rdi
	push	rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	push	rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	mov	edi, DWORD PTR 16[rdi]
	call	to_soc_camera_host@PLT
	mov	rdi, r12
	mov	rbp, QWORD PTR [rax]
	mov	rax, QWORD PTR 8[r12]
	call	[QWORD PTR [rax]]
	mov	esi, DWORD PTR CSI_BUS_FLAGS[rip]
	mov	rdi, rax
	call	soc_camera_bus_param_compatible@PLT
	test	rax, rax
	je	.L54
	mov	rbx, rax
	mov	rax, QWORD PTR SOCAM_VSYNC_ACTIVE_HIGH[rip]
	mov	DWORD PTR [r12], 8
	test	rax, rbx
	je	.L4
	mov	rdx, QWORD PTR SOCAM_VSYNC_ACTIVE_LOW[rip]
	test	rdx, rbx
	je	.L4
	mov	rcx, QWORD PTR 8[rbp]
	test	rcx, rcx
	je	.L5
	mov	ecx, DWORD PTR [rcx]
	test	DWORD PTR MX1_CAMERA_VSYNC_HIGH[rip], ecx
	jne	.L5
	not	rax
	and	rbx, rax
	.p2align 4,,10
	.p2align 3
.L4:
	mov	rax, QWORD PTR SOCAM_PCLK_SAMPLE_RISING[rip]
	test	rax, rbx
	je	.L7
.L56:
	mov	rdx, QWORD PTR SOCAM_PCLK_SAMPLE_FALLING[rip]
	test	rdx, rbx
	je	.L7
	mov	rcx, QWORD PTR 8[rbp]
	test	rcx, rcx
	je	.L8
	mov	ecx, DWORD PTR [rcx]
	test	DWORD PTR MX1_CAMERA_PCLK_RISING[rip], ecx
	jne	.L8
	not	rax
	and	rbx, rax
	.p2align 4,,10
	.p2align 3
.L7:
	mov	rax, QWORD PTR SOCAM_DATA_ACTIVE_HIGH[rip]
	test	rax, rbx
	je	.L10
.L55:
	mov	rdx, QWORD PTR SOCAM_DATA_ACTIVE_LOW[rip]
	test	rdx, rbx
	je	.L10
	mov	rcx, QWORD PTR 8[rbp]
	test	rcx, rcx
	je	.L11
	mov	ecx, DWORD PTR [rcx]
	test	DWORD PTR MX1_CAMERA_DATA_HIGH[rip], ecx
	jne	.L11
	not	rax
	and	rbx, rax
	.p2align 4,,10
	.p2align 3
.L10:
	mov	rax, QWORD PTR 8[r12]
	mov	rsi, rbx
	mov	rdi, r12
	call	[QWORD PTR 8[rax]]
	test	eax, eax
	js	.L1
	mov	rdi, QWORD PTR CSICR1[rip]
	add	rdi, QWORD PTR 0[rbp]
	call	__raw_readl@PLT
	mov	edi, eax
	test	QWORD PTR SOCAM_PCLK_SAMPLE_RISING[rip], rbx
	je	.L13
	or	edi, DWORD PTR CSICR1_REDGE[rip]
.L13:
	test	QWORD PTR SOCAM_VSYNC_ACTIVE_HIGH[rip], rbx
	je	.L14
	or	edi, DWORD PTR CSICR1_SOF_POL[rip]
.L14:
	test	QWORD PTR SOCAM_DATA_ACTIVE_LOW[rip], rbx
	je	.L15
	or	edi, DWORD PTR CSICR1_DATA_POL[rip]
.L15:
	mov	rsi, QWORD PTR CSICR1[rip]
	add	rsi, QWORD PTR 0[rbp]
	call	__raw_writel@PLT
	xor	eax, eax
.L1:
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L54:
	.cfi_restore_state
	mov	eax, DWORD PTR EINVAL[rip]
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	neg	eax
	ret
	.p2align 4,,10
	.p2align 3
.L11:
	.cfi_restore_state
	not	rdx
	and	rbx, rdx
	jmp	.L10
	.p2align 4,,10
	.p2align 3
.L8:
	not	rdx
	mov	rax, QWORD PTR SOCAM_DATA_ACTIVE_HIGH[rip]
	and	rbx, rdx
	test	rax, rbx
	je	.L10
	jmp	.L55
	.p2align 4,,10
	.p2align 3
.L5:
	not	rdx
	mov	rax, QWORD PTR SOCAM_PCLK_SAMPLE_RISING[rip]
	and	rbx, rdx
	test	rax, rbx
	je	.L7
	jmp	.L56
	.cfi_endproc
.LFE0:
	.size	mx1_camera_set_bus_param, .-mx1_camera_set_bus_param
	.comm	SOCAM_VSYNC_ACTIVE_LOW,8,8
	.comm	SOCAM_VSYNC_ACTIVE_HIGH,8,8
	.comm	SOCAM_PCLK_SAMPLE_RISING,8,8
	.comm	SOCAM_PCLK_SAMPLE_FALLING,8,8
	.comm	SOCAM_DATA_ACTIVE_LOW,8,8
	.comm	SOCAM_DATA_ACTIVE_HIGH,8,8
	.comm	MX1_CAMERA_VSYNC_HIGH,4,4
	.comm	MX1_CAMERA_PCLK_RISING,4,4
	.comm	MX1_CAMERA_DATA_HIGH,4,4
	.comm	EINVAL,4,4
	.comm	CSI_BUS_FLAGS,4,4
	.comm	CSICR1_SOF_POL,4,4
	.comm	CSICR1_REDGE,4,4
	.comm	CSICR1_DATA_POL,4,4
	.comm	CSICR1,8,8
	.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_mx1_camera.c_mx1_camera_set_bus_param.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	mx1_camera_set_bus_param, %function
mx1_camera_set_bus_param:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	mov	r5, r0
	ldr	r0, [r0, #8]
	bl	to_soc_camera_host
	mov	r2, r0
	ldr	r3, [r5, #4]
	mov	r0, r5
	ldr	r3, [r3]
	ldr	r6, [r2]
	blx	r3
	ldr	r3, .L55
	ldr	r1, [r3]
	bl	soc_camera_bus_param_compatible
	subs	r4, r0, #0
	beq	.L54
	mov	r3, #8
	ldr	r7, .L55+4
	str	r3, [r5]
	ldr	r3, [r7]
	tst	r3, r4
	beq	.L4
	ldr	r2, .L55+8
	ldr	r2, [r2]
	tst	r2, r4
	beq	.L4
	ldr	r1, [r6, #4]
	cmp	r1, #0
	beq	.L5
	ldr	ip, .L55+12
	ldr	r0, [r1]
	ldr	r1, [ip]
	tst	r0, r1
	biceq	r4, r4, r3
	beq	.L4
.L5:
	bic	r4, r4, r2
.L4:
	ldr	r8, .L55+16
	ldr	r3, [r8]
	tst	r3, r4
	beq	.L7
	ldr	r2, .L55+20
	ldr	r2, [r2]
	tst	r2, r4
	beq	.L7
	ldr	r1, [r6, #4]
	cmp	r1, #0
	beq	.L8
	ldr	ip, .L55+24
	ldr	r0, [r1]
	ldr	r1, [ip]
	tst	r0, r1
	biceq	r4, r4, r3
	beq	.L7
.L8:
	bic	r4, r4, r2
.L7:
	ldr	r3, .L55+28
	ldr	r3, [r3]
	tst	r3, r4
	beq	.L10
	ldr	r2, .L55+32
	ldr	r2, [r2]
	tst	r2, r4
	beq	.L10
	ldr	r1, [r6, #4]
	cmp	r1, #0
	beq	.L11
	ldr	ip, .L55+36
	ldr	r0, [r1]
	ldr	r1, [ip]
	tst	r0, r1
	biceq	r4, r4, r3
	beq	.L10
.L11:
	bic	r4, r4, r2
.L10:
	ldr	r3, [r5, #4]
	mov	r0, r5
	mov	r1, r4
	ldr	r3, [r3, #4]
	blx	r3
	cmp	r0, #0
	poplt	{r4, r5, r6, r7, r8, pc}
	ldr	r5, .L55+40
	ldr	r0, [r6]
	ldr	r3, [r5]
	add	r0, r0, r3
	bl	__raw_readl
	ldr	r3, [r8]
	ldr	r1, [r6]
	tst	r4, r3
	ldrne	r3, .L55+44
	ldrne	r3, [r3]
	orrne	r0, r0, r3
	ldr	r3, [r7]
	tst	r4, r3
	ldrne	r3, .L55+48
	ldrne	r3, [r3]
	orrne	r0, r0, r3
	ldr	r3, .L55+32
	ldr	r3, [r3]
	tst	r4, r3
	ldrne	r3, .L55+52
	ldrne	r3, [r3]
	orrne	r0, r0, r3
	ldr	r3, [r5]
	add	r1, r1, r3
	bl	__raw_writel
	mov	r0, #0
	pop	{r4, r5, r6, r7, r8, pc}
.L54:
	ldr	r3, .L55+56
	ldr	r0, [r3]
	rsb	r0, r0, #0
	pop	{r4, r5, r6, r7, r8, pc}
.L56:
	.align	2
.L55:
	.word	CSI_BUS_FLAGS
	.word	SOCAM_VSYNC_ACTIVE_HIGH
	.word	SOCAM_VSYNC_ACTIVE_LOW
	.word	MX1_CAMERA_VSYNC_HIGH
	.word	SOCAM_PCLK_SAMPLE_RISING
	.word	SOCAM_PCLK_SAMPLE_FALLING
	.word	MX1_CAMERA_PCLK_RISING
	.word	SOCAM_DATA_ACTIVE_HIGH
	.word	SOCAM_DATA_ACTIVE_LOW
	.word	MX1_CAMERA_DATA_HIGH
	.word	CSICR1
	.word	CSICR1_REDGE
	.word	CSICR1_SOF_POL
	.word	CSICR1_DATA_POL
	.word	EINVAL
	.size	mx1_camera_set_bus_param, .-mx1_camera_set_bus_param
	.comm	SOCAM_VSYNC_ACTIVE_LOW,4,4
	.comm	SOCAM_VSYNC_ACTIVE_HIGH,4,4
	.comm	SOCAM_PCLK_SAMPLE_RISING,4,4
	.comm	SOCAM_PCLK_SAMPLE_FALLING,4,4
	.comm	SOCAM_DATA_ACTIVE_LOW,4,4
	.comm	SOCAM_DATA_ACTIVE_HIGH,4,4
	.comm	MX1_CAMERA_VSYNC_HIGH,4,4
	.comm	MX1_CAMERA_PCLK_RISING,4,4
	.comm	MX1_CAMERA_DATA_HIGH,4,4
	.comm	EINVAL,4,4
	.comm	CSI_BUS_FLAGS,4,4
	.comm	CSICR1_SOF_POL,4,4
	.comm	CSICR1_REDGE,4,4
	.comm	CSICR1_DATA_POL,4,4
	.comm	CSICR1,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
