	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function stk1160_start_streaming
_stk1160_start_streaming:               ## @stk1160_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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	cmpl	$0, 4(%rdi)
	je	LBB0_1
## %bb.3:
	movq	%rdi, %r14
	callq	_mutex_lock_interruptible
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	movq	_ERESTARTSYS@GOTPCREL(%rip), %rax
	jmp	LBB0_2
LBB0_1:
	movq	_ENODEV@GOTPCREL(%rip), %rax
LBB0_2:
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
	jmp	LBB0_18
LBB0_5:
	movq	%r14, %rdi
	callq	_stk1160_set_alternate
	movl	24(%r14), %ecx
	testl	%ecx, %ecx
	je	LBB0_7
## %bb.6:
	testl	%eax, %eax
	jne	LBB0_7
## %bb.10:
	testl	%ecx, %ecx
	jg	LBB0_11
	jmp	LBB0_16
LBB0_7:
	movq	%r14, %rdi
	callq	_stk1160_alloc_isoc
	testl	%eax, %eax
	js	LBB0_8
## %bb.9:
	movl	24(%r14), %ecx
	testl	%ecx, %ecx
	jle	LBB0_16
LBB0_11:
	xorl	%ebx, %ebx
	movq	_GFP_KERNEL@GOTPCREL(%rip), %r12
	.p2align	4, 0x90
LBB0_12:                                ## =>This Inner Loop Header: Depth=1
	movq	32(%r14), %rax
	movl	(%rax,%rbx,4), %edi
	movl	(%r12), %esi
	callq	_usb_submit_urb
	testl	%eax, %eax
	jne	LBB0_13
## %bb.15:                              ##   in Loop: Header=BB0_12 Depth=1
	incq	%rbx
	movslq	24(%r14), %rax
	cmpq	%rax, %rbx
	jl	LBB0_12
LBB0_16:
	leaq	16(%r14), %rdi
	movq	_video@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_s_stream@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	xorl	%r15d, %r15d
	xorl	%esi, %esi
	movl	$1, %r8d
	callq	_v4l2_device_call_all
	movq	$0, 8(%r14)
	movq	_STK1160_DCTRL@GOTPCREL(%rip), %rbx
	movq	(%rbx), %rsi
	movq	%r14, %rdi
	movl	$179, %edx
	callq	_stk1160_write_reg
	movq	(%rbx), %rsi
	addq	$3, %rsi
	movq	%r14, %rdi
	xorl	%edx, %edx
	callq	_stk1160_write_reg
	leaq	L_.str.1(%rip), %rdi
	callq	_stk1160_dbg
	jmp	LBB0_17
LBB0_13:
	movl	%eax, %r15d
	leaq	L_.str(%rip), %rdi
	movl	%ebx, %esi
	movl	%eax, %edx
	callq	_stk1160_err
	movq	%r14, %rdi
	callq	_stk1160_uninit_isoc
	jmp	LBB0_14
LBB0_8:
	movl	%eax, %r15d
LBB0_14:
	movl	4(%r14), %edi
	xorl	%esi, %esi
	xorl	%edx, %edx
	callq	_usb_set_interface
	movq	%r14, %rdi
	callq	_stk1160_clear_queue
LBB0_17:
	movq	%r14, %rdi
	callq	_mutex_unlock
LBB0_18:
	movl	%r15d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_ERESTARTSYS,4,2                ## @ERESTARTSYS
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"cannot submit urb[%d] (%d)\n"

	.comm	_video,4,2                      ## @video
	.comm	_s_stream,4,2                   ## @s_stream
	.comm	_STK1160_DCTRL,8,3              ## @STK1160_DCTRL
L_.str.1:                               ## @.str.1
	.asciz	"streaming started\n"

	.no_dead_strip	_stk1160_start_streaming
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function stk1160_start_streaming
_stk1160_start_streaming:               ; @stk1160_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
	ldr	w8, [x0, #4]
	cbz	w8, LBB0_3
; %bb.1:
	mov	x19, x0
	bl	_mutex_lock_interruptible
	cbz	x0, LBB0_6
; %bb.2:
Lloh0:
	adrp	x8, _ERESTARTSYS@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ERESTARTSYS@GOTPAGEOFF]
	b	LBB0_4
LBB0_3:
Lloh2:
	adrp	x8, _ENODEV@GOTPAGE
Lloh3:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
LBB0_4:
	ldr	w8, [x8]
	neg	w20, w8
LBB0_5:
	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
LBB0_6:
	mov	x0, x19
	bl	_stk1160_set_alternate
	ldr	w8, [x19, #24]
	cbz	w8, LBB0_9
; %bb.7:
	cbnz	w0, LBB0_9
; %bb.8:
	cmp	w8, #1
	b.ge	LBB0_11
	b	LBB0_14
LBB0_9:
	mov	x0, x19
	bl	_stk1160_alloc_isoc
	tbnz	w0, #31, LBB0_16
; %bb.10:
	ldr	w8, [x19, #24]
	cmp	w8, #1
	b.lt	LBB0_14
LBB0_11:
	mov	x21, #0
Lloh4:
	adrp	x22, _GFP_KERNEL@GOTPAGE
Lloh5:
	ldr	x22, [x22, _GFP_KERNEL@GOTPAGEOFF]
LBB0_12:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #32]
	ldr	w0, [x8, x21, lsl #2]
	ldr	w1, [x22]
	bl	_usb_submit_urb
	cbnz	w0, LBB0_15
; %bb.13:                               ;   in Loop: Header=BB0_12 Depth=1
	add	x21, x21, #1
	ldrsw	x8, [x19, #24]
	cmp	x21, x8
	b.lt	LBB0_12
LBB0_14:
	add	x0, x19, #16
Lloh6:
	adrp	x8, _video@GOTPAGE
Lloh7:
	ldr	x8, [x8, _video@GOTPAGEOFF]
Lloh8:
	ldr	w2, [x8]
Lloh9:
	adrp	x8, _s_stream@GOTPAGE
Lloh10:
	ldr	x8, [x8, _s_stream@GOTPAGEOFF]
Lloh11:
	ldr	w3, [x8]
	mov	w1, #0
	mov	w4, #1
	bl	_v4l2_device_call_all
	str	xzr, [x19, #8]
Lloh12:
	adrp	x20, _STK1160_DCTRL@GOTPAGE
Lloh13:
	ldr	x20, [x20, _STK1160_DCTRL@GOTPAGEOFF]
	ldr	x1, [x20]
	mov	x0, x19
	mov	w2, #179
	bl	_stk1160_write_reg
	ldr	x8, [x20]
	add	x1, x8, #3
	mov	x0, x19
	mov	w2, #0
	bl	_stk1160_write_reg
Lloh14:
	adrp	x0, l_.str.1@PAGE
Lloh15:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_stk1160_dbg
	mov	x0, x19
	bl	_mutex_unlock
	mov	w20, #0
	b	LBB0_5
LBB0_15:
	mov	x20, x0
Lloh16:
	adrp	x0, l_.str@PAGE
Lloh17:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x21
	mov	x2, x20
	bl	_stk1160_err
	mov	x0, x19
	bl	_stk1160_uninit_isoc
	b	LBB0_17
LBB0_16:
	mov	x20, x0
LBB0_17:
	ldr	w0, [x19, #4]
	mov	w1, #0
	mov	w2, #0
	bl	_usb_set_interface
	mov	x0, x19
	bl	_stk1160_clear_queue
	mov	x0, x19
	bl	_mutex_unlock
	b	LBB0_5
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_ERESTARTSYS,4,2                ; @ERESTARTSYS
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"cannot submit urb[%d] (%d)\n"

	.comm	_video,4,2                      ; @video
	.comm	_s_stream,4,2                   ; @s_stream
	.comm	_STK1160_DCTRL,8,3              ; @STK1160_DCTRL
l_.str.1:                               ; @.str.1
	.asciz	"streaming started\n"

	.no_dead_strip	_stk1160_start_streaming
.subsections_via_symbols
