	.file	"extr_tve200_display.c_tve200_display_enable.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"CIF mode\n"
.LC1:
	.string	"VGA mode\n"
.LC2:
	.string	"D1 mode\n"
.LC3:
	.string	"Unknown FB format 0x%08x\n"
	.text
	.p2align 4
	.type	tve200_display_enable, @function
tve200_display_enable:
.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
	lea	r12, 8[rdi]
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	sub	rsp, 24
	.cfi_def_cfa_offset 80
	mov	rax, QWORD PTR [rdi]
	mov	rbp, QWORD PTR 8[rdi]
	mov	QWORD PTR 8[rsp], rsi
	mov	r14, QWORD PTR 8[rbp]
	mov	r15, QWORD PTR [rax]
	mov	rdx, QWORD PTR 16[r14]
	mov	rax, QWORD PTR [r15]
	mov	edi, DWORD PTR 8[r14]
	mov	QWORD PTR [rsp], rdx
	mov	r13d, DWORD PTR [rax]
	call	clk_prepare_enable@PLT
	mov	rdx, QWORD PTR [rsp]
	mov	ebx, DWORD PTR TVE200_CTRL_CSMODE[rip]
	or	ebx, DWORD PTR TVE200_CTRL_NONINTERLACE[rip]
	or	ebx, DWORD PTR TVE200_CTRL_BURST_32_WORDS[rip]
	mov	eax, DWORD PTR [rdx]
	or	ebx, DWORD PTR TVE200_CTRL_RETRYCNT_16[rip]
	or	ebx, DWORD PTR TVE200_CTRL_NTSC[rip]
	or	ebx, DWORD PTR TVE200_VSTSTYPE_VSYNC[rip]
	test	DWORD PTR DRM_BUS_FLAG_PIXDATA_DRIVE_NEGEDGE[rip], eax
	mov	rsi, QWORD PTR 8[rsp]
	je	.L2
	or	ebx, DWORD PTR TVE200_CTRL_TVCLKP[rip]
.L2:
	mov	eax, DWORD PTR [rsi]
	cmp	eax, 352
	je	.L39
	cmp	eax, 640
	je	.L40
	cmp	eax, 720
	jne	.L4
	mov	eax, DWORD PTR 4[rsi]
	cmp	eax, 480
	je	.L24
	cmp	eax, 576
	jne	.L4
.L24:
	mov	edi, DWORD PTR 0[rbp]
	lea	rsi, .LC2[rip]
	or	ebx, DWORD PTR TVE200_CTRL_IPRESOL_D1[rip]
	call	dev_info@PLT
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L40:
	cmp	DWORD PTR 4[rsi], 480
	je	.L41
.L4:
	mov	eax, DWORD PTR DRM_FORMAT_BIG_ENDIAN[rip]
	test	eax, r13d
	je	.L8
	not	eax
	or	ebx, DWORD PTR TVE200_CTRL_BBBP[rip]
	and	r13d, eax
.L8:
	add	r13d, -128
	cmp	r13d, 10
	ja	.L9
	lea	rdx, .L11[rip]
	movsx	rax, DWORD PTR [rdx+r13*4]
	add	rax, rdx
	notrack jmp	rax
	.section	.rodata
	.align 4
	.align 4
.L11:
	.long	.L21-.L11
	.long	.L20-.L11
	.long	.L19-.L11
	.long	.L18-.L11
	.long	.L17-.L11
	.long	.L16-.L11
	.long	.L15-.L11
	.long	.L14-.L11
	.long	.L13-.L11
	.long	.L12-.L11
	.long	.L10-.L11
	.text
	.p2align 4,,10
	.p2align 3
.L39:
	mov	eax, DWORD PTR 4[rsi]
	cmp	eax, 240
	je	.L23
	cmp	eax, 288
	jne	.L4
.L23:
	mov	edi, DWORD PTR 0[rbp]
	lea	rsi, .LC0[rip]
	or	ebx, DWORD PTR TVE200_CTRL_IPRESOL_CIF[rip]
	call	dev_info@PLT
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L12:
	or	ebx, DWORD PTR TVE200_IPDMOD_RGB565[rip]
.L22:
	or	ebx, DWORD PTR TVE200_TVEEN[rip]
	mov	rsi, QWORD PTR TVE200_CTRL[rip]
	mov	edi, ebx
	add	rsi, QWORD PTR [r14]
	call	writel@PLT
	add	rsp, 24
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	mov	rdi, r12
	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
	jmp	drm_crtc_vblank_on@PLT
	.p2align 4,,10
	.p2align 3
.L13:
	.cfi_restore_state
	mov	eax, DWORD PTR TVE200_IPDMOD_YUV422[rip]
	or	eax, DWORD PTR TVE200_CTRL_YCBCRODR_Y1CR0Y0CB0[rip]
	or	ebx, eax
	jmp	.L22
	.p2align 4,,10
	.p2align 3
.L14:
	mov	eax, DWORD PTR TVE200_IPDMOD_YUV422[rip]
	or	eax, DWORD PTR TVE200_CTRL_YCBCRODR_Y1CB0Y0CR0[rip]
	or	ebx, eax
	jmp	.L22
	.p2align 4,,10
	.p2align 3
.L15:
	mov	eax, DWORD PTR TVE200_IPDMOD_RGB555[rip]
	or	eax, DWORD PTR TVE200_BGR[rip]
	or	ebx, eax
	jmp	.L22
	.p2align 4,,10
	.p2align 3
.L16:
	mov	eax, DWORD PTR TVE200_IPDMOD_RGB888[rip]
	or	eax, DWORD PTR TVE200_BGR[rip]
	or	ebx, eax
	jmp	.L22
	.p2align 4,,10
	.p2align 3
.L17:
	or	ebx, DWORD PTR TVE200_IPDMOD_RGB555[rip]
	jmp	.L22
	.p2align 4,,10
	.p2align 3
.L18:
	or	ebx, DWORD PTR TVE200_IPDMOD_RGB888[rip]
	jmp	.L22
	.p2align 4,,10
	.p2align 3
.L19:
	mov	eax, DWORD PTR TVE200_CTRL_YUV420[rip]
	or	eax, DWORD PTR TVE200_IPDMOD_YUV420[rip]
	or	ebx, eax
	jmp	.L22
	.p2align 4,,10
	.p2align 3
.L20:
	mov	eax, DWORD PTR TVE200_IPDMOD_YUV422[rip]
	or	eax, DWORD PTR TVE200_CTRL_YCBCRODR_CR0Y1CB0Y0[rip]
	or	ebx, eax
	jmp	.L22
	.p2align 4,,10
	.p2align 3
.L21:
	mov	eax, DWORD PTR TVE200_IPDMOD_YUV422[rip]
	or	eax, DWORD PTR TVE200_CTRL_YCBCRODR_CB0Y1CR0Y0[rip]
	or	ebx, eax
	jmp	.L22
	.p2align 4,,10
	.p2align 3
.L10:
	mov	eax, DWORD PTR TVE200_IPDMOD_RGB565[rip]
	or	eax, DWORD PTR TVE200_BGR[rip]
	or	ebx, eax
	jmp	.L22
.L9:
	mov	rax, QWORD PTR [r15]
	mov	edi, DWORD PTR 0[rbp]
	lea	rsi, .LC3[rip]
	mov	edx, DWORD PTR [rax]
	call	dev_err@PLT
	jmp	.L22
	.p2align 4,,10
	.p2align 3
.L41:
	mov	edi, DWORD PTR 0[rbp]
	lea	rsi, .LC1[rip]
	or	ebx, DWORD PTR TVE200_CTRL_IPRESOL_VGA[rip]
	call	dev_info@PLT
	jmp	.L4
	.cfi_endproc
.LFE0:
	.size	tve200_display_enable, .-tve200_display_enable
	.comm	TVE200_VSTSTYPE_VSYNC,4,4
	.comm	TVE200_TVEEN,4,4
	.comm	TVE200_IPDMOD_YUV422,4,4
	.comm	TVE200_IPDMOD_YUV420,4,4
	.comm	TVE200_IPDMOD_RGB888,4,4
	.comm	TVE200_IPDMOD_RGB565,4,4
	.comm	TVE200_IPDMOD_RGB555,4,4
	.comm	TVE200_CTRL_YUV420,4,4
	.comm	TVE200_CTRL_YCBCRODR_Y1CR0Y0CB0,4,4
	.comm	TVE200_CTRL_YCBCRODR_Y1CB0Y0CR0,4,4
	.comm	TVE200_CTRL_YCBCRODR_CR0Y1CB0Y0,4,4
	.comm	TVE200_CTRL_YCBCRODR_CB0Y1CR0Y0,4,4
	.comm	TVE200_CTRL_TVCLKP,4,4
	.comm	TVE200_CTRL_RETRYCNT_16,4,4
	.comm	TVE200_CTRL_NTSC,4,4
	.comm	TVE200_CTRL_NONINTERLACE,4,4
	.comm	TVE200_CTRL_IPRESOL_VGA,4,4
	.comm	TVE200_CTRL_IPRESOL_D1,4,4
	.comm	TVE200_CTRL_IPRESOL_CIF,4,4
	.comm	TVE200_CTRL_CSMODE,4,4
	.comm	TVE200_CTRL_BURST_32_WORDS,4,4
	.comm	TVE200_CTRL_BBBP,4,4
	.comm	TVE200_CTRL,8,8
	.comm	TVE200_BGR,4,4
	.comm	DRM_FORMAT_BIG_ENDIAN,4,4
	.comm	DRM_BUS_FLAG_PIXDATA_DRIVE_NEGEDGE,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_tve200_display.c_tve200_display_enable.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"CIF mode\012\000"
	.align	2
.LC1:
	.ascii	"VGA mode\012\000"
	.align	2
.LC2:
	.ascii	"D1 mode\012\000"
	.align	2
.LC3:
	.ascii	"Unknown FB format 0x%08x\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	tve200_display_enable, %function
tve200_display_enable:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r3, r4, r5, r6, r7, r8, r9, r10, fp, lr}
	ldm	r0, {r3, r7}
	mov	r10, r1
	mov	r5, r0
	ldr	r9, [r3]
	ldr	r8, [r7, #4]
	ldr	r3, [r9]
	ldr	r0, [r8, #4]
	ldr	r6, [r3]
	ldr	fp, [r8, #8]
	bl	clk_prepare_enable
	ldr	r2, .L39
	ldr	r3, .L39+4
	ldr	r4, [r2]
	ldr	r2, [r3]
	ldr	r3, .L39+8
	orr	r4, r4, r2
	ldr	r2, .L39+12
	ldr	r3, [r3]
	ldr	r0, [r2]
	ldr	r2, .L39+16
	ldr	r1, [fp]
	ldr	r2, [r2]
	orr	r4, r4, r0
	orr	r4, r4, r2
	ldr	r2, .L39+20
	tst	r1, r3
	ldr	r3, .L39+24
	ldr	r2, [r2]
	ldr	r3, [r3]
	orr	r4, r4, r2
	orr	r4, r4, r3
	ldrne	r3, .L39+28
	add	r5, r5, #4
	ldrne	r3, [r3]
	orrne	r4, r4, r3
	ldr	r3, [r10]
	cmp	r3, #352
	beq	.L36
	cmp	r3, #640
	beq	.L37
	cmp	r3, #720
	bne	.L4
	ldr	r3, [r10, #4]
	cmp	r3, #576
	cmpne	r3, #480
	bne	.L4
	ldr	r3, .L39+32
	ldr	r1, .L39+36
	ldr	r3, [r3]
	ldr	r0, [r7]
	orr	r4, r4, r3
	bl	dev_info
	b	.L4
.L37:
	ldr	r3, [r10, #4]
	cmp	r3, #480
	beq	.L38
.L4:
	ldr	r3, .L39+40
	ldr	r3, [r3]
	tst	r3, r6
	ldrne	r2, .L39+44
	bicne	r6, r6, r3
	ldrne	r3, [r2]
	sub	r6, r6, #128
	orrne	r4, r4, r3
	cmp	r6, #10
	ldrls	pc, [pc, r6, asl #2]
	b	.L7
.L9:
	.word	.L19
	.word	.L18
	.word	.L17
	.word	.L16
	.word	.L15
	.word	.L14
	.word	.L13
	.word	.L12
	.word	.L11
	.word	.L10
	.word	.L8
.L36:
	ldr	r3, [r10, #4]
	cmp	r3, #288
	cmpne	r3, #240
	bne	.L4
	ldr	r3, .L39+48
	ldr	r1, .L39+52
	ldr	r3, [r3]
	ldr	r0, [r7]
	orr	r4, r4, r3
	bl	dev_info
	b	.L4
.L11:
	ldr	r3, .L39+56
	ldr	r2, .L39+60
	ldr	r3, [r3]
	ldr	r2, [r2]
	orr	r3, r3, r2
	orr	r4, r4, r3
.L20:
	ldr	r2, .L39+64
	ldr	r3, .L39+68
	ldr	r1, [r8]
	ldr	r3, [r3]
	ldr	r0, [r2]
	add	r1, r1, r3
	orr	r0, r4, r0
	bl	writel
	mov	r0, r5
	pop	{r3, r4, r5, r6, r7, r8, r9, r10, fp, lr}
	b	drm_crtc_vblank_on
.L12:
	ldr	r3, .L39+56
	ldr	r2, .L39+72
	ldr	r3, [r3]
	ldr	r2, [r2]
	orr	r3, r3, r2
	orr	r4, r4, r3
	b	.L20
.L13:
	ldr	r3, .L39+76
.L34:
	ldr	r2, .L39+80
	ldr	r3, [r3]
	ldr	r2, [r2]
	orr	r3, r3, r2
	orr	r4, r4, r3
	b	.L20
.L14:
	ldr	r3, .L39+84
	b	.L34
.L8:
	ldr	r3, .L39+88
	b	.L34
.L10:
	ldr	r3, .L39+88
	ldr	r3, [r3]
	orr	r4, r4, r3
	b	.L20
.L19:
	ldr	r3, .L39+56
	ldr	r2, .L39+92
	ldr	r3, [r3]
	ldr	r2, [r2]
	orr	r3, r3, r2
	orr	r4, r4, r3
	b	.L20
.L15:
	ldr	r3, .L39+76
	ldr	r3, [r3]
	orr	r4, r4, r3
	b	.L20
.L16:
	ldr	r3, .L39+84
	ldr	r3, [r3]
	orr	r4, r4, r3
	b	.L20
.L17:
	ldr	r3, .L39+96
	ldr	r2, .L39+100
	ldr	r3, [r3]
	ldr	r2, [r2]
	orr	r3, r3, r2
	orr	r4, r4, r3
	b	.L20
.L18:
	ldr	r3, .L39+56
	ldr	r2, .L39+104
	ldr	r3, [r3]
	ldr	r2, [r2]
	orr	r3, r3, r2
	orr	r4, r4, r3
	b	.L20
.L38:
	ldr	r3, .L39+108
	ldr	r1, .L39+112
	ldr	r3, [r3]
	ldr	r0, [r7]
	orr	r4, r4, r3
	bl	dev_info
	b	.L4
.L7:
	ldr	r3, [r9]
	ldr	r0, [r7]
	ldr	r2, [r3]
	ldr	r1, .L39+116
	bl	dev_err
	b	.L20
.L40:
	.align	2
.L39:
	.word	TVE200_CTRL_CSMODE
	.word	TVE200_CTRL_NONINTERLACE
	.word	DRM_BUS_FLAG_PIXDATA_DRIVE_NEGEDGE
	.word	TVE200_CTRL_BURST_32_WORDS
	.word	TVE200_CTRL_RETRYCNT_16
	.word	TVE200_CTRL_NTSC
	.word	TVE200_VSTSTYPE_VSYNC
	.word	TVE200_CTRL_TVCLKP
	.word	TVE200_CTRL_IPRESOL_D1
	.word	.LC2
	.word	DRM_FORMAT_BIG_ENDIAN
	.word	TVE200_CTRL_BBBP
	.word	TVE200_CTRL_IPRESOL_CIF
	.word	.LC0
	.word	TVE200_IPDMOD_YUV422
	.word	TVE200_CTRL_YCBCRODR_Y1CR0Y0CB0
	.word	TVE200_TVEEN
	.word	TVE200_CTRL
	.word	TVE200_CTRL_YCBCRODR_Y1CB0Y0CR0
	.word	TVE200_IPDMOD_RGB555
	.word	TVE200_BGR
	.word	TVE200_IPDMOD_RGB888
	.word	TVE200_IPDMOD_RGB565
	.word	TVE200_CTRL_YCBCRODR_CB0Y1CR0Y0
	.word	TVE200_CTRL_YUV420
	.word	TVE200_IPDMOD_YUV420
	.word	TVE200_CTRL_YCBCRODR_CR0Y1CB0Y0
	.word	TVE200_CTRL_IPRESOL_VGA
	.word	.LC1
	.word	.LC3
	.size	tve200_display_enable, .-tve200_display_enable
	.comm	TVE200_VSTSTYPE_VSYNC,4,4
	.comm	TVE200_TVEEN,4,4
	.comm	TVE200_IPDMOD_YUV422,4,4
	.comm	TVE200_IPDMOD_YUV420,4,4
	.comm	TVE200_IPDMOD_RGB888,4,4
	.comm	TVE200_IPDMOD_RGB565,4,4
	.comm	TVE200_IPDMOD_RGB555,4,4
	.comm	TVE200_CTRL_YUV420,4,4
	.comm	TVE200_CTRL_YCBCRODR_Y1CR0Y0CB0,4,4
	.comm	TVE200_CTRL_YCBCRODR_Y1CB0Y0CR0,4,4
	.comm	TVE200_CTRL_YCBCRODR_CR0Y1CB0Y0,4,4
	.comm	TVE200_CTRL_YCBCRODR_CB0Y1CR0Y0,4,4
	.comm	TVE200_CTRL_TVCLKP,4,4
	.comm	TVE200_CTRL_RETRYCNT_16,4,4
	.comm	TVE200_CTRL_NTSC,4,4
	.comm	TVE200_CTRL_NONINTERLACE,4,4
	.comm	TVE200_CTRL_IPRESOL_VGA,4,4
	.comm	TVE200_CTRL_IPRESOL_D1,4,4
	.comm	TVE200_CTRL_IPRESOL_CIF,4,4
	.comm	TVE200_CTRL_CSMODE,4,4
	.comm	TVE200_CTRL_BURST_32_WORDS,4,4
	.comm	TVE200_CTRL_BBBP,4,4
	.comm	TVE200_CTRL,4,4
	.comm	TVE200_BGR,4,4
	.comm	DRM_FORMAT_BIG_ENDIAN,4,4
	.comm	DRM_BUS_FLAG_PIXDATA_DRIVE_NEGEDGE,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
