	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ivtv_start_v4l2_encode_stream  ## -- Begin function ivtv_start_v4l2_encode_stream
	.p2align	4, 0x90
_ivtv_start_v4l2_encode_stream:         ## @ivtv_start_v4l2_encode_stream
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_CX2341X_MBOX_MAX_DATA@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	shlq	$3, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %r15
	cmpq	$0, 32(%r14)
	je	LBB0_1
## %bb.2:
	movq	40(%r14), %r13
	movslq	24(%r14), %rsi
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	callq	_IVTV_DEBUG_INFO
	movl	(%r14), %eax
	addl	$-128, %eax
	cmpl	$3, %eax
	ja	LBB0_1
## %bb.3:
	movl	$0, -52(%rbp)                   ## 4-byte Folded Spill
	movl	$2, %r12d
	movl	$1, -56(%rbp)                   ## 4-byte Folded Spill
	leaq	LJTI0_0(%rip), %rcx
	movslq	(%rcx,%rax,4), %rax
	addq	%rcx, %rax
	jmpq	*%rax
LBB0_8:
	movl	92(%r13), %eax
	movq	_OUT_PASSTHROUGH@GOTPCREL(%rip), %rcx
	xorl	%edx, %edx
	cmpl	(%rcx), %eax
	sete	%dl
	movl	$11, %eax
	movl	$1, %r12d
	cmovel	%eax, %r12d
	incl	%edx
	movl	%edx, -56(%rbp)                 ## 4-byte Spill
	jmp	LBB0_9
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_27
LBB0_7:
	movq	$0, 84(%r13)
	movl	80(%r13), %edi
	movl	$0, -52(%rbp)                   ## 4-byte Folded Spill
	movl	$4, %r12d
	xorl	%esi, %esi
	movl	$4, %edx
	callq	_memset
	jmp	LBB0_9
LBB0_4:
	movl	92(%r13), %eax
	movq	_OUT_PASSTHROUGH@GOTPCREL(%rip), %rcx
	movl	$0, -56(%rbp)                   ## 4-byte Folded Spill
	movl	$0, %edx
	cmpl	(%rcx), %eax
	jne	LBB0_6
## %bb.5:
	movq	%r13, %rdi
	xorl	%esi, %esi
	callq	_ivtv_passthrough_mode
	movl	$1, %edx
LBB0_6:
	movl	%edx, -52(%rbp)                 ## 4-byte Spill
	movq	$0, 104(%r13)
	movq	_jiffies@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 100(%r13)
	movl	24(%r13), %edi
	callq	_v4l2_ctrl_g_ctrl
	movl	%eax, (%r13)
	movl	$0, 96(%r13)
	movl	$3, %r12d
LBB0_9:
	movl	%r12d, 4(%r14)
	movq	$0, 16(%r14)
	movq	_IVTV_F_S_STREAMOFF@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	8(%r14), %rsi
	callq	_clear_bit
	leaq	8(%r13), %rdi
	movq	%rdi, -64(%rbp)                 ## 8-byte Spill
	callq	_atomic_read
	testq	%rax, %rax
	jne	LBB0_14
## %bb.10:
	movq	_CX2341X_ENC_SET_DMA_BLOCK_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$2, %edx
	movl	$1, %ecx
	movl	$1, %r8d
	xorl	%eax, %eax
	callq	_ivtv_vapi
	movq	_CX2341X_ENC_SET_VERT_CROP_LINE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$1, %edx
	xorl	%ecx, %ecx
	xorl	%eax, %eax
	callq	_ivtv_vapi
	movq	_CX2341X_ENC_MISC@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	xorl	%r8d, %r8d
	cmpq	$0, 32(%r13)
	sete	%r8b
	movq	%r13, %rdi
	movl	$2, %edx
	movl	$3, %ecx
	xorl	%eax, %eax
	callq	_ivtv_vapi
	movl	(%rbx), %esi
	movq	%r13, %rdi
	movl	$2, %edx
	movl	$8, %ecx
	xorl	%r8d, %r8d
	xorl	%eax, %eax
	callq	_ivtv_vapi
	movl	(%rbx), %esi
	movq	%r13, %rdi
	movl	$2, %edx
	movl	$4, %ecx
	movl	$1, %r8d
	xorl	%eax, %eax
	callq	_ivtv_vapi
	movl	(%rbx), %esi
	movq	%r13, %rdi
	movl	$1, %edx
	movl	$12, %ecx
	xorl	%eax, %eax
	callq	_ivtv_vapi
	movq	_CX2341X_ENC_SET_PLACEHOLDER@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	subq	$8, %rsp
	movq	%r13, %rdi
	movl	$12, %edx
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	xorl	%r9d, %r9d
	xorl	%eax, %eax
	pushq	$0
	pushq	$0
	pushq	$0
	pushq	$0
	pushq	$0
	pushq	$0
	pushq	$0
	pushq	$0
	pushq	$0
	callq	_ivtv_vapi
	addq	$80, %rsp
	movq	72(%r13), %rax
	movl	(%rax), %eax
	movq	_IVTV_HW_SAA7115@GOTPCREL(%rip), %rcx
	movq	_IVTV_HW_SAA717X@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	orl	(%rcx), %edx
	movq	_IVTV_HW_SAA7114@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	andl	%eax, %ecx
	movl	$320, %ecx                      ## imm = 0x140
	movl	$239, %esi
	cmovel	%ecx, %esi
	testl	%eax, %edx
	movl	$241, %ecx
	cmovel	%esi, %ecx
	movq	_CX2341X_ENC_SET_NUM_VSYNC_LINES@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$2, %edx
	movl	%ecx, %r8d
	xorl	%eax, %eax
	callq	_ivtv_vapi
	movq	_V4L2_CAP_VBI_CAPTURE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, 4(%r13)
	je	LBB0_12
## %bb.11:
	movq	%r13, %rdi
	callq	_ivtv_vbi_setup
LBB0_12:
	movq	_CX2341X_ENC_SET_PGM_INDEX_INFO@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r13, %rdi
	movq	%r15, %rsi
	movl	$2, %ecx
	movl	$7, %r8d
	movl	$400, %r9d                      ## imm = 0x190
	callq	_ivtv_vapi_result
	movq	(%r15), %rsi
	movq	%rsi, 48(%r13)
	movq	8(%r15), %rdx
	movq	%rdx, 40(%r13)
	xorps	%xmm0, %xmm0
	movups	%xmm0, 56(%r13)
	leaq	L_.str.1(%rip), %rdi
	xorl	%eax, %eax
	callq	_IVTV_DEBUG_INFO
	leaq	20(%r13), %rdi
	callq	_cx2341x_handler_setup
	movq	_IVTV_F_I_RADIO_USER@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	28(%r13), %rsi
	callq	_test_bit
	testq	%rax, %rax
	je	LBB0_14
## %bb.13:
	movq	_CX2341X_ENC_MUTE_VIDEO@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movl	20(%r13), %edi
	callq	_v4l2_ctrl_g_ctrl
                                        ## kill: def $eax killed $eax def $rax
	shll	$8, %eax
	leal	1(%rax), %ecx
	movq	%r13, %rdi
	movl	%ebx, %esi
	movl	$1, %edx
	xorl	%eax, %eax
	callq	_ivtv_vapi
LBB0_14:
	cmpq	$0, 32(%r13)
	je	LBB0_17
## %bb.15:
	movq	_IVTV_F_I_DIG_RST@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	28(%r13), %rsi
	callq	_test_and_set_bit
	testl	%eax, %eax
	jne	LBB0_17
## %bb.16:
	movq	_CX2341X_ENC_SET_EVENT_NOTIFICATION@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_IVTV_IRQ_ENC_VIM_RST@GOTPCREL(%rip), %rbx
	movl	(%rbx), %r9d
	subq	$8, %rsp
	movq	%r13, %rdi
	movl	$4, %edx
	xorl	%ecx, %ecx
	movl	$1, %r8d
	xorl	%eax, %eax
	pushq	$-1
	callq	_ivtv_vapi
	addq	$16, %rsp
	movl	(%rbx), %esi
	movq	%r13, %rdi
	callq	_ivtv_clear_irq_mask
LBB0_17:
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	callq	_atomic_read
	testq	%rax, %rax
	jne	LBB0_19
## %bb.18:
	movq	_IVTV_IRQ_MASK_CAPTURE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_ivtv_set_irq_mask
	movq	_IVTV_F_I_EOS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	28(%r13), %rsi
	callq	_clear_bit
	leaq	20(%r13), %rdi
	movl	$1, %esi
	callq	_cx2341x_handler_set_busy
	movl	16(%r13), %edi
	movq	_audio@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_s_stream@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edx
	movl	$1, %ecx
	callq	_v4l2_subdev_call
	movl	12(%r13), %edi
	movq	_video@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	movl	(%rbx), %edx
	xorl	%ecx, %ecx
	callq	_v4l2_subdev_call
	movl	$300, %edi                      ## imm = 0x12C
	xorl	%esi, %esi
	callq	_ivtv_msleep_timeout
	movq	_CX2341X_ENC_INITIALIZE_INPUT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	xorl	%edx, %edx
	xorl	%eax, %eax
	callq	_ivtv_vapi
	movl	12(%r13), %edi
	movl	(%r15), %esi
	movl	(%rbx), %edx
	movl	$1, %ecx
	callq	_v4l2_subdev_call
LBB0_19:
	movq	_CX2341X_ENC_START_CAPTURE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%ebx, %ebx
	movq	%r13, %rdi
	movl	$2, %edx
	movl	-56(%rbp), %ecx                 ## 4-byte Reload
	movl	%r12d, %r8d
	xorl	%eax, %eax
	callq	_ivtv_vapi
	testq	%rax, %rax
	je	LBB0_21
## %bb.20:
	leaq	L_.str.2(%rip), %rdi
	callq	_IVTV_DEBUG_WARN
	movq	_EINVAL@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
	jmp	LBB0_27
LBB0_21:
	cmpl	$0, -52(%rbp)                   ## 4-byte Folded Reload
	je	LBB0_23
## %bb.22:
	movq	%r13, %rdi
	movl	$1, %esi
	callq	_ivtv_passthrough_mode
LBB0_23:
	cmpl	$129, (%r14)
	jne	LBB0_24
## %bb.25:
	movq	_IVTV_IRQ_ENC_VBI_CAP@GOTPCREL(%rip), %rax
	jmp	LBB0_26
LBB0_24:
	movq	_IVTV_IRQ_MASK_CAPTURE@GOTPCREL(%rip), %rax
LBB0_26:
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_ivtv_clear_irq_mask
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	callq	_atomic_inc
	xorl	%ebx, %ebx
LBB0_27:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_29
## %bb.28:
	movl	%ebx, %eax
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_29:
	callq	___stack_chk_fail
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_8, LBB0_8-LJTI0_0
.set L0_0_set_7, LBB0_7-LJTI0_0
.set L0_0_set_9, LBB0_9-LJTI0_0
.set L0_0_set_4, LBB0_4-LJTI0_0
LJTI0_0:
	.long	L0_0_set_8
	.long	L0_0_set_7
	.long	L0_0_set_9
	.long	L0_0_set_4
	.end_data_region
                                        ## -- End function
	.comm	_CX2341X_MBOX_MAX_DATA,4,2      ## @CX2341X_MBOX_MAX_DATA
	.comm	_EINVAL,4,2                     ## @EINVAL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Start encoder stream %s\n"

	.comm	_OUT_PASSTHROUGH,4,2            ## @OUT_PASSTHROUGH
	.comm	_jiffies,4,2                    ## @jiffies
	.comm	_IVTV_F_S_STREAMOFF,4,2         ## @IVTV_F_S_STREAMOFF
	.comm	_CX2341X_ENC_SET_DMA_BLOCK_SIZE,4,2 ## @CX2341X_ENC_SET_DMA_BLOCK_SIZE
	.comm	_CX2341X_ENC_SET_VERT_CROP_LINE,4,2 ## @CX2341X_ENC_SET_VERT_CROP_LINE
	.comm	_CX2341X_ENC_MISC,4,2           ## @CX2341X_ENC_MISC
	.comm	_CX2341X_ENC_SET_PLACEHOLDER,4,2 ## @CX2341X_ENC_SET_PLACEHOLDER
	.comm	_IVTV_HW_SAA7115,4,2            ## @IVTV_HW_SAA7115
	.comm	_IVTV_HW_SAA717X,4,2            ## @IVTV_HW_SAA717X
	.comm	_IVTV_HW_SAA7114,4,2            ## @IVTV_HW_SAA7114
	.comm	_CX2341X_ENC_SET_NUM_VSYNC_LINES,4,2 ## @CX2341X_ENC_SET_NUM_VSYNC_LINES
	.comm	_V4L2_CAP_VBI_CAPTURE,4,2       ## @V4L2_CAP_VBI_CAPTURE
	.comm	_CX2341X_ENC_SET_PGM_INDEX_INFO,4,2 ## @CX2341X_ENC_SET_PGM_INDEX_INFO
L_.str.1:                               ## @.str.1
	.asciz	"PGM Index at 0x%08x with %d elements\n"

	.comm	_IVTV_F_I_RADIO_USER,4,2        ## @IVTV_F_I_RADIO_USER
	.comm	_CX2341X_ENC_MUTE_VIDEO,4,2     ## @CX2341X_ENC_MUTE_VIDEO
	.comm	_IVTV_F_I_DIG_RST,4,2           ## @IVTV_F_I_DIG_RST
	.comm	_CX2341X_ENC_SET_EVENT_NOTIFICATION,4,2 ## @CX2341X_ENC_SET_EVENT_NOTIFICATION
	.comm	_IVTV_IRQ_ENC_VIM_RST,4,2       ## @IVTV_IRQ_ENC_VIM_RST
	.comm	_IVTV_IRQ_MASK_CAPTURE,4,2      ## @IVTV_IRQ_MASK_CAPTURE
	.comm	_IVTV_F_I_EOS,4,2               ## @IVTV_F_I_EOS
	.comm	_audio,4,2                      ## @audio
	.comm	_s_stream,4,2                   ## @s_stream
	.comm	_video,4,2                      ## @video
	.comm	_CX2341X_ENC_INITIALIZE_INPUT,4,2 ## @CX2341X_ENC_INITIALIZE_INPUT
	.comm	_CX2341X_ENC_START_CAPTURE,4,2  ## @CX2341X_ENC_START_CAPTURE
L_.str.2:                               ## @.str.2
	.asciz	"Error starting capture!\n"

	.comm	_IVTV_IRQ_ENC_VBI_CAP,4,2       ## @IVTV_IRQ_ENC_VBI_CAP
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ivtv_start_v4l2_encode_stream  ; -- Begin function ivtv_start_v4l2_encode_stream
	.p2align	2
_ivtv_start_v4l2_encode_stream:         ; @ivtv_start_v4l2_encode_stream
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	sub	sp, sp, #16
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-88]
Lloh3:
	adrp	x8, _CX2341X_MBOX_MAX_DATA@GOTPAGE
Lloh4:
	ldr	x8, [x8, _CX2341X_MBOX_MAX_DATA@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	lsl	x8, x8, #3
	mov	x9, x8
Lloh6:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh7:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	add	x8, x8, #15
	and	x8, x8, #0xffffffff0
	sub	x22, x9, x8
	mov	sp, x22
	ldr	x8, [x0, #32]
	cbz	x8, LBB0_21
; %bb.1:
	ldr	x20, [x19, #40]
	ldrsw	x1, [x19, #24]
Lloh8:
	adrp	x0, l_.str@PAGE
Lloh9:
	add	x0, x0, l_.str@PAGEOFF
	bl	_IVTV_DEBUG_INFO
	ldr	w8, [x19]
	sub	w8, w8, #128
	cmp	w8, #3
	b.hi	LBB0_21
; %bb.2:
	mov	w23, #0
	mov	w24, #2
	mov	w25, #1
Lloh10:
	adrp	x9, lJTI0_0@PAGE
Lloh11:
	add	x9, x9, lJTI0_0@PAGEOFF
	adr	x10, LBB0_3
	ldrb	w11, [x9, x8]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_3:
	mov	w23, #0
	ldr	w8, [x20, #92]
Lloh12:
	adrp	x9, _OUT_PASSTHROUGH@GOTPAGE
Lloh13:
	ldr	x9, [x9, _OUT_PASSTHROUGH@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
	cmp	w8, w9
	mov	w8, #1
	cinc	w25, w8, eq
	mov	w8, #11
	csinc	w24, w8, wzr, eq
	b	LBB0_9
LBB0_4:
	stp	wzr, wzr, [x20, #84]
	ldr	w0, [x20, #80]
	mov	w24, #4
	mov	w1, #0
	mov	w2, #4
	bl	_memset
	mov	w23, #0
	mov	w25, #1
	b	LBB0_9
LBB0_5:
	ldr	w8, [x20, #92]
Lloh15:
	adrp	x9, _OUT_PASSTHROUGH@GOTPAGE
Lloh16:
	ldr	x9, [x9, _OUT_PASSTHROUGH@GOTPAGEOFF]
Lloh17:
	ldr	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_7
; %bb.6:
	mov	x0, x20
	mov	w1, #0
	bl	_ivtv_passthrough_mode
	mov	w23, #1
	b	LBB0_8
LBB0_7:
	mov	w23, #0
LBB0_8:
	str	wzr, [x20, #108]
Lloh18:
	adrp	x8, _jiffies@GOTPAGE
Lloh19:
	ldr	x8, [x8, _jiffies@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	stp	w8, wzr, [x20, #100]
	ldr	w0, [x20, #24]
	bl	_v4l2_ctrl_g_ctrl
	mov	w25, #0
	str	w0, [x20]
	str	wzr, [x20, #96]
	mov	w24, #3
LBB0_9:
	str	w24, [x19, #4]
	str	xzr, [x19, #16]
Lloh21:
	adrp	x8, _IVTV_F_S_STREAMOFF@GOTPAGE
Lloh22:
	ldr	x8, [x8, _IVTV_F_S_STREAMOFF@GOTPAGEOFF]
Lloh23:
	ldr	w0, [x8]
	add	x1, x19, #8
	bl	_clear_bit
	add	x21, x20, #8
	mov	x0, x21
	bl	_atomic_read
	cbnz	x0, LBB0_14
; %bb.10:
Lloh24:
	adrp	x8, _CX2341X_ENC_SET_DMA_BLOCK_SIZE@GOTPAGE
Lloh25:
	ldr	x8, [x8, _CX2341X_ENC_SET_DMA_BLOCK_SIZE@GOTPAGEOFF]
Lloh26:
	ldr	w1, [x8]
	mov	w26, #1
	stp	x26, x26, [sp, #-16]!
	mov	x0, x20
	mov	w2, #2
	bl	_ivtv_vapi
	add	sp, sp, #16
Lloh27:
	adrp	x8, _CX2341X_ENC_SET_VERT_CROP_LINE@GOTPAGE
Lloh28:
	ldr	x8, [x8, _CX2341X_ENC_SET_VERT_CROP_LINE@GOTPAGEOFF]
Lloh29:
	ldr	w1, [x8]
	str	xzr, [sp, #-16]!
	mov	x0, x20
	mov	w2, #1
	bl	_ivtv_vapi
	add	sp, sp, #16
Lloh30:
	adrp	x27, _CX2341X_ENC_MISC@GOTPAGE
Lloh31:
	ldr	x27, [x27, _CX2341X_ENC_MISC@GOTPAGEOFF]
	ldr	w1, [x27]
	ldr	x8, [x20, #32]
	cmp	x8, #0
	cset	w8, eq
	mov	w9, #3
	stp	x9, x8, [sp, #-16]!
	mov	x0, x20
	mov	w2, #2
	bl	_ivtv_vapi
	add	sp, sp, #16
	ldr	w1, [x27]
	mov	w8, #8
	stp	x8, xzr, [sp, #-16]!
	mov	x0, x20
	mov	w2, #2
	bl	_ivtv_vapi
	add	sp, sp, #16
	ldr	w1, [x27]
	mov	w8, #4
	stp	x8, x26, [sp, #-16]!
	mov	x0, x20
	mov	w2, #2
	bl	_ivtv_vapi
	add	sp, sp, #16
	ldr	w1, [x27]
	mov	w8, #12
	str	x8, [sp, #-16]!
	mov	x0, x20
	mov	w2, #1
	bl	_ivtv_vapi
	add	sp, sp, #16
Lloh32:
	adrp	x8, _CX2341X_ENC_SET_PLACEHOLDER@GOTPAGE
Lloh33:
	ldr	x8, [x8, _CX2341X_ENC_SET_PLACEHOLDER@GOTPAGEOFF]
Lloh34:
	ldr	w1, [x8]
	sub	sp, sp, #96
	movi.2d	v0, #0000000000000000
	stp	q0, q0, [sp, #64]
	stp	q0, q0, [sp, #32]
	stp	q0, q0, [sp]
	mov	x0, x20
	mov	w2, #12
	bl	_ivtv_vapi
	add	sp, sp, #96
	ldr	x8, [x20, #72]
	ldr	w8, [x8]
Lloh35:
	adrp	x9, _IVTV_HW_SAA7115@GOTPAGE
Lloh36:
	ldr	x9, [x9, _IVTV_HW_SAA7115@GOTPAGEOFF]
Lloh37:
	ldr	w9, [x9]
Lloh38:
	adrp	x10, _IVTV_HW_SAA717X@GOTPAGE
Lloh39:
	ldr	x10, [x10, _IVTV_HW_SAA717X@GOTPAGEOFF]
Lloh40:
	ldr	w10, [x10]
Lloh41:
	adrp	x11, _IVTV_HW_SAA7114@GOTPAGE
Lloh42:
	ldr	x11, [x11, _IVTV_HW_SAA7114@GOTPAGEOFF]
	orr	w9, w10, w9
Lloh43:
	ldr	w10, [x11]
	tst	w10, w8
	mov	w10, #239
	mov	w11, #320
	csel	w10, w11, w10, eq
	tst	w9, w8
	mov	w8, #241
	csel	w8, w10, w8, eq
Lloh44:
	adrp	x9, _CX2341X_ENC_SET_NUM_VSYNC_LINES@GOTPAGE
Lloh45:
	ldr	x9, [x9, _CX2341X_ENC_SET_NUM_VSYNC_LINES@GOTPAGEOFF]
Lloh46:
	ldr	w1, [x9]
	stp	x8, x8, [sp, #-16]!
	mov	x0, x20
	mov	w2, #2
	bl	_ivtv_vapi
	add	sp, sp, #16
	ldr	w8, [x20, #4]
Lloh47:
	adrp	x9, _V4L2_CAP_VBI_CAPTURE@GOTPAGE
Lloh48:
	ldr	x9, [x9, _V4L2_CAP_VBI_CAPTURE@GOTPAGEOFF]
Lloh49:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_12
; %bb.11:
	mov	x0, x20
	bl	_ivtv_vbi_setup
LBB0_12:
Lloh50:
	adrp	x8, _CX2341X_ENC_SET_PGM_INDEX_INFO@GOTPAGE
Lloh51:
	ldr	x8, [x8, _CX2341X_ENC_SET_PGM_INDEX_INFO@GOTPAGEOFF]
Lloh52:
	ldr	w2, [x8]
	mov	x0, x20
	mov	x1, x22
	mov	w3, #2
	mov	w4, #7
	mov	w5, #400
	bl	_ivtv_vapi_result
	ldp	x1, x8, [x22]
	stp	x8, x1, [x20, #40]
	stp	xzr, xzr, [x20, #56]
	str	x8, [sp, #-16]!
Lloh53:
	adrp	x0, l_.str.1@PAGE
Lloh54:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_IVTV_DEBUG_INFO
	add	sp, sp, #16
	add	x0, x20, #20
	bl	_cx2341x_handler_setup
Lloh55:
	adrp	x8, _IVTV_F_I_RADIO_USER@GOTPAGE
Lloh56:
	ldr	x8, [x8, _IVTV_F_I_RADIO_USER@GOTPAGEOFF]
Lloh57:
	ldr	w0, [x8]
	add	x1, x20, #28
	bl	_test_bit
	cbz	x0, LBB0_14
; %bb.13:
Lloh58:
	adrp	x8, _CX2341X_ENC_MUTE_VIDEO@GOTPAGE
Lloh59:
	ldr	x8, [x8, _CX2341X_ENC_MUTE_VIDEO@GOTPAGEOFF]
Lloh60:
	ldr	w22, [x8]
	ldr	w0, [x20, #20]
	bl	_v4l2_ctrl_g_ctrl
	mov	w8, #1
	bfi	w8, w0, #8, #24
	str	x8, [sp, #-16]!
	mov	x0, x20
	mov	x1, x22
	mov	w2, #1
	bl	_ivtv_vapi
	add	sp, sp, #16
LBB0_14:
	ldr	x8, [x20, #32]
	cbz	x8, LBB0_17
; %bb.15:
Lloh61:
	adrp	x8, _IVTV_F_I_DIG_RST@GOTPAGE
Lloh62:
	ldr	x8, [x8, _IVTV_F_I_DIG_RST@GOTPAGEOFF]
Lloh63:
	ldr	w0, [x8]
	add	x1, x20, #28
	bl	_test_and_set_bit
	cbnz	w0, LBB0_17
; %bb.16:
Lloh64:
	adrp	x8, _CX2341X_ENC_SET_EVENT_NOTIFICATION@GOTPAGE
Lloh65:
	ldr	x8, [x8, _CX2341X_ENC_SET_EVENT_NOTIFICATION@GOTPAGEOFF]
Lloh66:
	ldr	w1, [x8]
Lloh67:
	adrp	x22, _IVTV_IRQ_ENC_VIM_RST@GOTPAGE
Lloh68:
	ldr	x22, [x22, _IVTV_IRQ_ENC_VIM_RST@GOTPAGEOFF]
	ldr	w8, [x22]
	sub	sp, sp, #32
	mov	w9, #-1
	stp	x8, x9, [sp, #16]
	mov	w8, #1
	stp	xzr, x8, [sp]
	mov	x0, x20
	mov	w2, #4
	bl	_ivtv_vapi
	add	sp, sp, #32
	ldr	w1, [x22]
	mov	x0, x20
	bl	_ivtv_clear_irq_mask
LBB0_17:
	mov	x0, x21
	bl	_atomic_read
	cbnz	x0, LBB0_19
; %bb.18:
Lloh69:
	adrp	x8, _IVTV_IRQ_MASK_CAPTURE@GOTPAGE
Lloh70:
	ldr	x8, [x8, _IVTV_IRQ_MASK_CAPTURE@GOTPAGEOFF]
Lloh71:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_ivtv_set_irq_mask
Lloh72:
	adrp	x8, _IVTV_F_I_EOS@GOTPAGE
Lloh73:
	ldr	x8, [x8, _IVTV_F_I_EOS@GOTPAGEOFF]
Lloh74:
	ldr	w0, [x8]
	add	x1, x20, #28
	bl	_clear_bit
	add	x0, x20, #20
	mov	w1, #1
	bl	_cx2341x_handler_set_busy
	ldr	w0, [x20, #16]
Lloh75:
	adrp	x8, _audio@GOTPAGE
Lloh76:
	ldr	x8, [x8, _audio@GOTPAGEOFF]
Lloh77:
	ldr	w1, [x8]
Lloh78:
	adrp	x22, _s_stream@GOTPAGE
Lloh79:
	ldr	x22, [x22, _s_stream@GOTPAGEOFF]
	ldr	w2, [x22]
	mov	w3, #1
	bl	_v4l2_subdev_call
	ldr	w0, [x20, #12]
Lloh80:
	adrp	x26, _video@GOTPAGE
Lloh81:
	ldr	x26, [x26, _video@GOTPAGEOFF]
	ldr	w1, [x26]
	ldr	w2, [x22]
	mov	w3, #0
	bl	_v4l2_subdev_call
	mov	w0, #300
	mov	w1, #0
	bl	_ivtv_msleep_timeout
Lloh82:
	adrp	x8, _CX2341X_ENC_INITIALIZE_INPUT@GOTPAGE
Lloh83:
	ldr	x8, [x8, _CX2341X_ENC_INITIALIZE_INPUT@GOTPAGEOFF]
Lloh84:
	ldr	w1, [x8]
	mov	x0, x20
	mov	w2, #0
	bl	_ivtv_vapi
	ldr	w0, [x20, #12]
	ldr	w1, [x26]
	ldr	w2, [x22]
	mov	w3, #1
	bl	_v4l2_subdev_call
LBB0_19:
Lloh85:
	adrp	x8, _CX2341X_ENC_START_CAPTURE@GOTPAGE
Lloh86:
	ldr	x8, [x8, _CX2341X_ENC_START_CAPTURE@GOTPAGEOFF]
Lloh87:
	ldr	w1, [x8]
	stp	x25, x24, [sp, #-16]!
	mov	x0, x20
	mov	w2, #2
	bl	_ivtv_vapi
	add	sp, sp, #16
	cbz	x0, LBB0_24
; %bb.20:
Lloh88:
	adrp	x0, l_.str.2@PAGE
Lloh89:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_IVTV_DEBUG_WARN
LBB0_21:
Lloh90:
	adrp	x8, _EINVAL@GOTPAGE
Lloh91:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh92:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_22:
	ldur	x8, [x29, #-88]
Lloh93:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh94:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh95:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_27
; %bb.23:
	sub	sp, x29, #80
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_24:
	cbz	w23, LBB0_26
; %bb.25:
	mov	x0, x20
	mov	w1, #1
	bl	_ivtv_passthrough_mode
LBB0_26:
Lloh96:
	adrp	x8, _IVTV_IRQ_ENC_VBI_CAP@GOTPAGE
Lloh97:
	ldr	x8, [x8, _IVTV_IRQ_ENC_VBI_CAP@GOTPAGEOFF]
	ldr	w9, [x19]
Lloh98:
	adrp	x10, _IVTV_IRQ_MASK_CAPTURE@GOTPAGE
Lloh99:
	ldr	x10, [x10, _IVTV_IRQ_MASK_CAPTURE@GOTPAGEOFF]
	cmp	w9, #129
	csel	x8, x8, x10, eq
	ldr	w1, [x8]
	mov	x0, x20
	bl	_ivtv_clear_irq_mask
	mov	x0, x21
	bl	_atomic_inc
	mov	w0, #0
	b	LBB0_22
LBB0_27:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh47, Lloh48, Lloh49
	.loh AdrpLdrGotLdr	Lloh44, Lloh45, Lloh46
	.loh AdrpLdrGotLdr	Lloh41, Lloh42, Lloh43
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGot	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh55, Lloh56, Lloh57
	.loh AdrpAdd	Lloh53, Lloh54
	.loh AdrpLdrGotLdr	Lloh50, Lloh51, Lloh52
	.loh AdrpLdrGotLdr	Lloh58, Lloh59, Lloh60
	.loh AdrpLdrGotLdr	Lloh61, Lloh62, Lloh63
	.loh AdrpLdrGot	Lloh67, Lloh68
	.loh AdrpLdrGotLdr	Lloh64, Lloh65, Lloh66
	.loh AdrpLdrGotLdr	Lloh82, Lloh83, Lloh84
	.loh AdrpLdrGot	Lloh80, Lloh81
	.loh AdrpLdrGot	Lloh78, Lloh79
	.loh AdrpLdrGotLdr	Lloh75, Lloh76, Lloh77
	.loh AdrpLdrGotLdr	Lloh72, Lloh73, Lloh74
	.loh AdrpLdrGotLdr	Lloh69, Lloh70, Lloh71
	.loh AdrpLdrGotLdr	Lloh85, Lloh86, Lloh87
	.loh AdrpAdd	Lloh88, Lloh89
	.loh AdrpLdrGotLdr	Lloh90, Lloh91, Lloh92
	.loh AdrpLdrGotLdr	Lloh93, Lloh94, Lloh95
	.loh AdrpLdrGot	Lloh98, Lloh99
	.loh AdrpLdrGot	Lloh96, Lloh97
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_3-LBB0_3)>>2
	.byte	(LBB0_4-LBB0_3)>>2
	.byte	(LBB0_9-LBB0_3)>>2
	.byte	(LBB0_5-LBB0_3)>>2
                                        ; -- End function
	.comm	_CX2341X_MBOX_MAX_DATA,4,2      ; @CX2341X_MBOX_MAX_DATA
	.comm	_EINVAL,4,2                     ; @EINVAL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Start encoder stream %s\n"

	.comm	_OUT_PASSTHROUGH,4,2            ; @OUT_PASSTHROUGH
	.comm	_jiffies,4,2                    ; @jiffies
	.comm	_IVTV_F_S_STREAMOFF,4,2         ; @IVTV_F_S_STREAMOFF
	.comm	_CX2341X_ENC_SET_DMA_BLOCK_SIZE,4,2 ; @CX2341X_ENC_SET_DMA_BLOCK_SIZE
	.comm	_CX2341X_ENC_SET_VERT_CROP_LINE,4,2 ; @CX2341X_ENC_SET_VERT_CROP_LINE
	.comm	_CX2341X_ENC_MISC,4,2           ; @CX2341X_ENC_MISC
	.comm	_CX2341X_ENC_SET_PLACEHOLDER,4,2 ; @CX2341X_ENC_SET_PLACEHOLDER
	.comm	_IVTV_HW_SAA7115,4,2            ; @IVTV_HW_SAA7115
	.comm	_IVTV_HW_SAA717X,4,2            ; @IVTV_HW_SAA717X
	.comm	_IVTV_HW_SAA7114,4,2            ; @IVTV_HW_SAA7114
	.comm	_CX2341X_ENC_SET_NUM_VSYNC_LINES,4,2 ; @CX2341X_ENC_SET_NUM_VSYNC_LINES
	.comm	_V4L2_CAP_VBI_CAPTURE,4,2       ; @V4L2_CAP_VBI_CAPTURE
	.comm	_CX2341X_ENC_SET_PGM_INDEX_INFO,4,2 ; @CX2341X_ENC_SET_PGM_INDEX_INFO
l_.str.1:                               ; @.str.1
	.asciz	"PGM Index at 0x%08x with %d elements\n"

	.comm	_IVTV_F_I_RADIO_USER,4,2        ; @IVTV_F_I_RADIO_USER
	.comm	_CX2341X_ENC_MUTE_VIDEO,4,2     ; @CX2341X_ENC_MUTE_VIDEO
	.comm	_IVTV_F_I_DIG_RST,4,2           ; @IVTV_F_I_DIG_RST
	.comm	_CX2341X_ENC_SET_EVENT_NOTIFICATION,4,2 ; @CX2341X_ENC_SET_EVENT_NOTIFICATION
	.comm	_IVTV_IRQ_ENC_VIM_RST,4,2       ; @IVTV_IRQ_ENC_VIM_RST
	.comm	_IVTV_IRQ_MASK_CAPTURE,4,2      ; @IVTV_IRQ_MASK_CAPTURE
	.comm	_IVTV_F_I_EOS,4,2               ; @IVTV_F_I_EOS
	.comm	_audio,4,2                      ; @audio
	.comm	_s_stream,4,2                   ; @s_stream
	.comm	_video,4,2                      ; @video
	.comm	_CX2341X_ENC_INITIALIZE_INPUT,4,2 ; @CX2341X_ENC_INITIALIZE_INPUT
	.comm	_CX2341X_ENC_START_CAPTURE,4,2  ; @CX2341X_ENC_START_CAPTURE
l_.str.2:                               ; @.str.2
	.asciz	"Error starting capture!\n"

	.comm	_IVTV_IRQ_ENC_VBI_CAP,4,2       ; @IVTV_IRQ_ENC_VBI_CAP
.subsections_via_symbols
