	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function go7007_start_streaming
_go7007_start_streaming:                ## @go7007_start_streaming
	.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
	movq	%rdi, %r15
	callq	_vb2_get_drv_priv
	movq	%rax, %r13
	movq	%rax, %rdi
	callq	_set_formatting
	leaq	28(%r13), %r12
	movq	%r12, %rdi
	callq	_mutex_lock
	xorps	%xmm0, %xmm0
	movups	%xmm0, 32(%r13)
	movq	$0, 48(%r13)
	movl	$1, (%r15)
	movq	%r13, %rdi
	callq	_go7007_start_encoder
	movq	%rax, %r14
	movq	_EIO@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	sarq	$63, %r14
	movq	%r12, %rdi
	callq	_mutex_unlock
	andl	%ebx, %r14d
	je	LBB0_2
## %bb.1:
	movl	$0, (%r15)
	jmp	LBB0_4
LBB0_2:
	movq	%r13, %rdi
	addq	$24, %rdi
	movq	_video@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_s_stream@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	$1, %ecx
	callq	_call_all
	movl	20(%r13), %edi
	movl	$1, %esi
	callq	_v4l2_ctrl_grab
	movl	16(%r13), %edi
	movl	$1, %esi
	callq	_v4l2_ctrl_grab
	movl	12(%r13), %edi
	movl	$1, %esi
	callq	_v4l2_ctrl_grab
	movl	8(%r13), %edi
	movl	$1, %esi
	callq	_v4l2_ctrl_grab
	movq	(%r13), %rax
	movq	_GO7007_BOARDID_ADS_USBAV_709@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_4
## %bb.3:
	movq	%r13, %rdi
	movl	$15490, %esi                    ## imm = 0x3C82
	movl	$5, %edx
	callq	_go7007_write_addr
LBB0_4:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EIO,4,2                        ## @EIO
	.comm	_video,4,2                      ## @video
	.comm	_s_stream,4,2                   ## @s_stream
	.comm	_GO7007_BOARDID_ADS_USBAV_709,8,3 ## @GO7007_BOARDID_ADS_USBAV_709
	.no_dead_strip	_go7007_start_streaming
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function go7007_start_streaming
_go7007_start_streaming:                ; @go7007_start_streaming
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	mov	x21, x0
	bl	_vb2_get_drv_priv
	mov	x19, x0
	bl	_set_formatting
	add	x22, x19, #28
	mov	x0, x22
	bl	_mutex_lock
	stp	xzr, xzr, [x19, #40]
	str	xzr, [x19, #32]
	mov	w8, #1
	str	w8, [x21]
	mov	x0, x19
	bl	_go7007_start_encoder
Lloh0:
	adrp	x8, _EIO@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	asr	x9, x0, #63
	neg	w8, w8
	and	w20, w9, w8
	mov	x0, x22
	bl	_mutex_unlock
	cbz	w20, LBB0_2
; %bb.1:
	str	wzr, [x21]
	b	LBB0_4
LBB0_2:
	add	x0, x19, #24
Lloh3:
	adrp	x8, _video@GOTPAGE
Lloh4:
	ldr	x8, [x8, _video@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
Lloh6:
	adrp	x8, _s_stream@GOTPAGE
Lloh7:
	ldr	x8, [x8, _s_stream@GOTPAGEOFF]
Lloh8:
	ldr	w2, [x8]
	mov	w3, #1
	bl	_call_all
	ldr	w0, [x19, #20]
	mov	w1, #1
	bl	_v4l2_ctrl_grab
	ldr	w0, [x19, #16]
	mov	w1, #1
	bl	_v4l2_ctrl_grab
	ldr	w0, [x19, #12]
	mov	w1, #1
	bl	_v4l2_ctrl_grab
	ldr	w0, [x19, #8]
	mov	w1, #1
	bl	_v4l2_ctrl_grab
	ldr	x8, [x19]
Lloh9:
	adrp	x9, _GO7007_BOARDID_ADS_USBAV_709@GOTPAGE
Lloh10:
	ldr	x9, [x9, _GO7007_BOARDID_ADS_USBAV_709@GOTPAGEOFF]
Lloh11:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_4
; %bb.3:
	mov	x0, x19
	mov	w1, #15490
	mov	w2, #5
	bl	_go7007_write_addr
LBB0_4:
	mov	x0, x20
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_EIO,4,2                        ; @EIO
	.comm	_video,4,2                      ; @video
	.comm	_s_stream,4,2                   ; @s_stream
	.comm	_GO7007_BOARDID_ADS_USBAV_709,8,3 ; @GO7007_BOARDID_ADS_USBAV_709
	.no_dead_strip	_go7007_start_streaming
.subsections_via_symbols
