	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ccp2_s_stream
_ccp2_s_stream:                         ## @ccp2_s_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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r14d
	movq	%rdi, %r12
	callq	_v4l2_get_subdevdata
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_to_isp_device
	movq	%rax, %r15
	movq	%rbx, %rdi
	callq	_to_device
	movq	%rax, %r13
	cmpl	$128, (%rbx)
	jne	LBB0_3
## %bb.1:
	movl	%r14d, %eax
	movq	%r13, -48(%rbp)                 ## 8-byte Spill
	movq	%r15, %r13
	xorl	%r15d, %r15d
	cmpl	$128, %r14d
	je	LBB0_23
## %bb.2:
	leaq	12(%rbx), %rdi
	xorl	%esi, %esi
	callq	_atomic_set
	movq	%r13, %r15
	movq	-48(%rbp), %r13                 ## 8-byte Reload
LBB0_3:
	cmpl	$128, %r14d
	je	LBB0_15
## %bb.4:
	cmpl	$129, %r14d
	je	LBB0_12
## %bb.5:
	cmpl	$130, %r14d
	jne	LBB0_22
## %bb.6:
	movl	4(%rbx), %edi
	testl	%edi, %edi
	je	LBB0_9
## %bb.7:
	addq	$4, %r12
	movq	%r12, %rsi
	callq	_omap3isp_csiphy_acquire
	testl	%eax, %eax
	js	LBB0_8
LBB0_9:
	movq	%rbx, %rdi
	callq	_ccp2_if_configure
	movq	%rbx, %rdi
	callq	_ccp2_print_status
	movq	%rbx, %rdi
	movl	$1, %esi
	callq	_ccp2_if_enable
	testl	%eax, %eax
	jns	LBB0_22
## %bb.10:
	movl	%eax, %r15d
	movl	4(%rbx), %edi
	testl	%edi, %edi
	je	LBB0_23
## %bb.11:
	callq	_omap3isp_csiphy_release
	jmp	LBB0_23
LBB0_15:
	leaq	4(%r12), %rdi
	leaq	16(%rbx), %rsi
	movq	%rbx, %rdx
	addq	$12, %rdx
	callq	_omap3isp_module_sync_idle
	testl	%eax, %eax
	je	LBB0_17
## %bb.16:
	movl	(%r12), %edx
	leaq	L_.str(%rip), %rsi
	movq	%r13, %rdi
	callq	_dev_dbg
LBB0_17:
	movl	8(%rbx), %eax
	movq	_CCP2_INPUT_MEMORY@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_19
## %bb.18:
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_ccp2_mem_enable
	movq	_OMAP3_ISP_SBL_CSI1_READ@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_omap3isp_sbl_disable
	jmp	LBB0_22
LBB0_12:
	cmpl	$129, (%rbx)
	je	LBB0_14
## %bb.13:
	movq	32(%rbx), %rax
	movq	_CCP2_PAD_SINK@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movl	4(%rax,%rcx,8), %edx
	movq	%rbx, %rsi
	addq	$20, %rsi
	movl	%edx, 28(%rbx)
	movl	(%rax,%rcx,8), %eax
	movl	%eax, 24(%rbx)
	movl	$0, 20(%rbx)
	movq	%rbx, %rdi
	callq	_ccp2_mem_configure
	movq	_OMAP3_ISP_SBL_CSI1_READ@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_omap3isp_sbl_enable
	movq	%rbx, %rdi
	callq	_ccp2_print_status
LBB0_14:
	movq	%rbx, %rdi
	movl	$1, %esi
	callq	_ccp2_mem_enable
LBB0_22:
	movl	%r14d, (%rbx)
	xorl	%r15d, %r15d
LBB0_23:
	movl	%r15d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_19:
	movq	_CCP2_INPUT_SENSOR@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_22
## %bb.20:
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_ccp2_if_enable
	movl	4(%rbx), %edi
	testl	%edi, %edi
	je	LBB0_22
## %bb.21:
	callq	_omap3isp_csiphy_release
	jmp	LBB0_22
LBB0_8:
	movl	%eax, %r15d
	jmp	LBB0_23
	.cfi_endproc
                                        ## -- End function
	.comm	_CCP2_PAD_SINK,8,3              ## @CCP2_PAD_SINK
	.comm	_OMAP3_ISP_SBL_CSI1_READ,4,2    ## @OMAP3_ISP_SBL_CSI1_READ
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s: module stop timeout.\n"

	.comm	_CCP2_INPUT_MEMORY,4,2          ## @CCP2_INPUT_MEMORY
	.comm	_CCP2_INPUT_SENSOR,4,2          ## @CCP2_INPUT_SENSOR
	.no_dead_strip	_ccp2_s_stream
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ccp2_s_stream
_ccp2_s_stream:                         ; @ccp2_s_stream
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x19, x1
	mov	x22, x0
	bl	_v4l2_get_subdevdata
	mov	x20, x0
	bl	_to_isp_device
	mov	x21, x0
	mov	x0, x20
	bl	_to_device
	mov	x23, x0
	ldr	w8, [x20]
	cmp	w8, #128
	b.ne	LBB0_4
; %bb.1:
	cmp	w19, #128
	b.ne	LBB0_3
; %bb.2:
	mov	w21, #0
	b	LBB0_20
LBB0_3:
	add	x0, x20, #12
	mov	w1, #0
	bl	_atomic_set
LBB0_4:
	cmp	w19, #128
	b.eq	LBB0_12
; %bb.5:
	cmp	w19, #129
	b.eq	LBB0_16
; %bb.6:
	cmp	w19, #130
	b.ne	LBB0_19
; %bb.7:
	ldr	w0, [x20, #4]
	cbz	w0, LBB0_9
; %bb.8:
	add	x1, x22, #4
	bl	_omap3isp_csiphy_acquire
	tbnz	w0, #31, LBB0_24
LBB0_9:
	mov	x0, x20
	bl	_ccp2_if_configure
	mov	x0, x20
	bl	_ccp2_print_status
	mov	x0, x20
	mov	w1, #1
	bl	_ccp2_if_enable
	tbz	w0, #31, LBB0_19
; %bb.10:
	mov	x21, x0
	ldr	w0, [x20, #4]
	cbz	w0, LBB0_20
; %bb.11:
	bl	_omap3isp_csiphy_release
	b	LBB0_20
LBB0_12:
	add	x0, x22, #4
	add	x1, x20, #16
	add	x2, x20, #12
	bl	_omap3isp_module_sync_idle
	cbz	w0, LBB0_14
; %bb.13:
	ldr	w2, [x22]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x23
	bl	_dev_dbg
LBB0_14:
	ldr	w8, [x20, #8]
Lloh2:
	adrp	x9, _CCP2_INPUT_MEMORY@GOTPAGE
Lloh3:
	ldr	x9, [x9, _CCP2_INPUT_MEMORY@GOTPAGEOFF]
Lloh4:
	ldr	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_21
; %bb.15:
	mov	x0, x20
	mov	w1, #0
	bl	_ccp2_mem_enable
Lloh5:
	adrp	x8, _OMAP3_ISP_SBL_CSI1_READ@GOTPAGE
Lloh6:
	ldr	x8, [x8, _OMAP3_ISP_SBL_CSI1_READ@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	mov	x0, x21
	bl	_omap3isp_sbl_disable
	b	LBB0_19
LBB0_16:
	ldr	w8, [x20]
	cmp	w8, #129
	b.eq	LBB0_18
; %bb.17:
	ldr	x8, [x20, #32]
Lloh8:
	adrp	x9, _CCP2_PAD_SINK@GOTPAGE
Lloh9:
	ldr	x9, [x9, _CCP2_PAD_SINK@GOTPAGEOFF]
Lloh10:
	ldr	x9, [x9]
	ldr	d0, [x8, x9, lsl #3]
	str	d0, [x20, #24]
	mov	x1, x20
	str	wzr, [x1, #20]!
	mov	x0, x20
	bl	_ccp2_mem_configure
Lloh11:
	adrp	x8, _OMAP3_ISP_SBL_CSI1_READ@GOTPAGE
Lloh12:
	ldr	x8, [x8, _OMAP3_ISP_SBL_CSI1_READ@GOTPAGEOFF]
Lloh13:
	ldr	w1, [x8]
	mov	x0, x21
	bl	_omap3isp_sbl_enable
	mov	x0, x20
	bl	_ccp2_print_status
LBB0_18:
	mov	x0, x20
	mov	w1, #1
	bl	_ccp2_mem_enable
LBB0_19:
	mov	w21, #0
	str	w19, [x20]
LBB0_20:
	mov	x0, x21
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_21:
Lloh14:
	adrp	x9, _CCP2_INPUT_SENSOR@GOTPAGE
Lloh15:
	ldr	x9, [x9, _CCP2_INPUT_SENSOR@GOTPAGEOFF]
Lloh16:
	ldr	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_19
; %bb.22:
	mov	x0, x20
	mov	w1, #0
	bl	_ccp2_if_enable
	ldr	w0, [x20, #4]
	cbz	w0, LBB0_19
; %bb.23:
	bl	_omap3isp_csiphy_release
	b	LBB0_19
LBB0_24:
	mov	x21, x0
	b	LBB0_20
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_CCP2_PAD_SINK,8,3              ; @CCP2_PAD_SINK
	.comm	_OMAP3_ISP_SBL_CSI1_READ,4,2    ; @OMAP3_ISP_SBL_CSI1_READ
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s: module stop timeout.\n"

	.comm	_CCP2_INPUT_MEMORY,4,2          ; @CCP2_INPUT_MEMORY
	.comm	_CCP2_INPUT_SENSOR,4,2          ; @CCP2_INPUT_SENSOR
	.no_dead_strip	_ccp2_s_stream
.subsections_via_symbols
