	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cx231xx_init_vbi_isoc          ## -- Begin function cx231xx_init_vbi_isoc
	.p2align	4, 0x90
_cx231xx_init_vbi_isoc:                 ## @cx231xx_init_vbi_isoc
	.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	%r8, %rbx
	movl	%ecx, %r14d
	movl	%edx, %r13d
	movl	%esi, -44(%rbp)                 ## 4-byte Spill
	movq	%rdi, %r12
	movl	8(%rdi), %edi
	leaq	L_.str(%rip), %rsi
	callq	_dev_dbg
	movq	%r12, %rdi
	callq	_cx231xx_uninit_vbi_isoc
	movl	56(%r12), %esi
	movl	128(%r12), %r15d
	movl	%r15d, %edi
	callq	_usb_rcvbulkpipe
	movl	%r15d, %edi
	movl	%eax, %esi
	callq	_usb_clear_halt
	movq	%rbx, 16(%r12)
	movl	%r13d, 24(%r12)
	xorps	%xmm0, %xmm0
	movups	%xmm0, 104(%r12)
	movq	$0, 120(%r12)
	movl	$-1, 64(%r12)
	movl	(%r12), %eax
	addl	%eax, %eax
	movl	%eax, 68(%r12)
	movq	_V4L2_STD_625_50@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	4(%r12), %eax
	jne	LBB0_2
## %bb.1:
	movq	_NTSC_VBI_LINES@GOTPCREL(%rip), %rax
	jmp	LBB0_3
LBB0_2:
	movq	_PAL_VBI_LINES@GOTPCREL(%rip), %rax
LBB0_3:
	movl	(%rax), %eax
	movl	%eax, 96(%r12)
	movq	$0, 88(%r12)
	movq	80(%r12), %rax
	movups	%xmm0, 48(%rax)
	movups	%xmm0, 32(%rax)
	movups	%xmm0, 16(%rax)
	movups	%xmm0, (%rax)
	movq	_GFP_KERNEL@GOTPCREL(%rip), %r15
	movl	(%r15), %edx
	movl	%r13d, %edi
	movl	$8, %esi
	callq	_kcalloc
	movq	%rax, 32(%r12)
	testq	%rax, %rax
	je	LBB0_15
## %bb.4:
	movl	(%r15), %edx
	movl	%r13d, %edi
	movl	$8, %esi
	callq	_kcalloc
	movq	%rax, 40(%r12)
	testq	%rax, %rax
	je	LBB0_16
## %bb.5:
	movl	%r14d, 28(%r12)
	movq	$0, 48(%r12)
	cmpl	$0, 24(%r12)
	jle	LBB0_10
## %bb.6:
	leaq	64(%r12), %rax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	imull	-44(%rbp), %r14d                ## 4-byte Folded Reload
	xorl	%r13d, %r13d
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r15), %esi
	xorl	%edi, %edi
	callq	_usb_alloc_urb
	testq	%rax, %rax
	je	LBB0_17
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	movq	%rax, %rbx
	movq	32(%r12), %rax
	movq	%rbx, (%rax,%r13,8)
	movq	$0, (%rbx)
	movl	(%r15), %esi
	movl	%r14d, %edi
	callq	_kzalloc
	movq	40(%r12), %rcx
	movl	%eax, (%rcx,%r13,4)
	testl	%eax, %eax
	je	LBB0_18
## %bb.9:                               ##   in Loop: Header=BB0_7 Depth=1
	movl	56(%r12), %esi
	movl	128(%r12), %edi
	callq	_usb_rcvbulkpipe
	movl	128(%r12), %esi
	movq	40(%r12), %rcx
	movl	(%rcx,%r13,4), %ecx
	movq	_cx231xx_irq_vbi_callback@GOTPCREL(%rip), %rdx
	movl	(%rdx), %r9d
	movq	-56(%rbp), %rdx                 ## 8-byte Reload
	movq	%rdx, (%rsp)
	movq	%rbx, %rdi
	movl	%eax, %edx
	movl	%r14d, %r8d
	callq	_usb_fill_bulk_urb
	incq	%r13
	movslq	24(%r12), %rax
	cmpq	%rax, %r13
	jl	LBB0_7
LBB0_10:
	leaq	72(%r12), %rdi
	callq	_init_waitqueue_head
	cmpl	$0, 24(%r12)
	jle	LBB0_14
## %bb.11:
	xorl	%ebx, %ebx
	movq	_GFP_ATOMIC@GOTPCREL(%rip), %r14
	.p2align	4, 0x90
LBB0_12:                                ## =>This Inner Loop Header: Depth=1
	movq	32(%r12), %rax
	movq	(%rax,%rbx,8), %rdi
	movl	(%r14), %esi
	callq	_usb_submit_urb
	testl	%eax, %eax
	jne	LBB0_22
## %bb.13:                              ##   in Loop: Header=BB0_12 Depth=1
	incq	%rbx
	movslq	24(%r12), %rax
	cmpq	%rax, %rbx
	jl	LBB0_12
LBB0_14:
	movq	_Vbi@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r12, %rdi
	movl	$1, %esi
	callq	_cx231xx_capture_start
	xorl	%r15d, %r15d
	jmp	LBB0_21
LBB0_15:
	movl	8(%r12), %edi
	leaq	L_.str.1(%rip), %rsi
	xorl	%r15d, %r15d
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_19
LBB0_16:
	movl	8(%r12), %edi
	leaq	L_.str.2(%rip), %rsi
	xorl	%r15d, %r15d
	xorl	%eax, %eax
	callq	_dev_err
	movq	32(%r12), %rdi
	callq	_kfree
	jmp	LBB0_19
LBB0_17:
	movq	%r12, %rdi
	callq	_cx231xx_uninit_vbi_isoc
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	jmp	LBB0_20
LBB0_18:
	movl	8(%r12), %ebx
	xorl	%r15d, %r15d
	xorl	%eax, %eax
	callq	_in_interrupt
	testq	%rax, %rax
	leaq	L_.str.5(%rip), %rax
	leaq	L_.str.4(%rip), %r8
	cmoveq	%rax, %r8
	leaq	L_.str.3(%rip), %rsi
	movl	%ebx, %edi
	movl	%r14d, %edx
	movl	%r13d, %ecx
	xorl	%eax, %eax
	callq	_dev_err
	movq	%r12, %rdi
	callq	_cx231xx_uninit_vbi_isoc
LBB0_19:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
LBB0_20:
	subl	(%rax), %r15d
LBB0_21:
	movl	%r15d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_22:
	movl	%eax, %r15d
	movl	8(%r12), %edi
	leaq	L_.str.6(%rip), %rsi
	movl	%ebx, %edx
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_dev_err
	movq	%r12, %rdi
	callq	_cx231xx_uninit_vbi_isoc
	jmp	LBB0_21
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"called cx231xx_vbi_isoc\n"

	.comm	_V4L2_STD_625_50,4,2            ## @V4L2_STD_625_50
	.comm	_PAL_VBI_LINES,4,2              ## @PAL_VBI_LINES
	.comm	_NTSC_VBI_LINES,4,2             ## @NTSC_VBI_LINES
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
L_.str.1:                               ## @.str.1
	.asciz	"cannot alloc memory for usb buffers\n"

	.comm	_ENOMEM,4,2                     ## @ENOMEM
L_.str.2:                               ## @.str.2
	.asciz	"cannot allocate memory for usbtransfer\n"

L_.str.3:                               ## @.str.3
	.asciz	"unable to allocate %i bytes for transfer buffer %i%s\n"

L_.str.4:                               ## @.str.4
	.asciz	" while in int"

L_.str.5:                               ## @.str.5
	.space	1

	.comm	_cx231xx_irq_vbi_callback,4,2   ## @cx231xx_irq_vbi_callback
	.comm	_GFP_ATOMIC,4,2                 ## @GFP_ATOMIC
L_.str.6:                               ## @.str.6
	.asciz	"submit of urb %i failed (error=%i)\n"

	.comm	_Vbi,4,2                        ## @Vbi
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cx231xx_init_vbi_isoc          ; -- Begin function cx231xx_init_vbi_isoc
	.p2align	2
_cx231xx_init_vbi_isoc:                 ; @cx231xx_init_vbi_isoc
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	mov	x24, x4
	mov	x21, x3
	mov	x23, x2
	mov	x22, x1
	mov	x19, x0
	ldr	w0, [x0, #8]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_dbg
	mov	x0, x19
	bl	_cx231xx_uninit_vbi_isoc
	ldr	w20, [x19, #128]
	ldr	w1, [x19, #56]
	mov	x0, x20
	bl	_usb_rcvbulkpipe
	mov	x1, x0
	mov	x0, x20
	bl	_usb_clear_halt
	mov	w8, #-1
	mov	x20, x19
	str	w8, [x20, #64]!
	str	x24, [x19, #16]
	str	w23, [x19, #24]
	stp	xzr, xzr, [x19, #112]
	str	xzr, [x19, #104]
	ldp	w8, w9, [x19]
	lsl	w8, w8, #1
	str	w8, [x19, #68]
Lloh2:
	adrp	x8, _V4L2_STD_625_50@GOTPAGE
Lloh3:
	ldr	x8, [x8, _V4L2_STD_625_50@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
Lloh5:
	adrp	x10, _PAL_VBI_LINES@GOTPAGE
Lloh6:
	ldr	x10, [x10, _PAL_VBI_LINES@GOTPAGEOFF]
Lloh7:
	adrp	x11, _NTSC_VBI_LINES@GOTPAGE
Lloh8:
	ldr	x11, [x11, _NTSC_VBI_LINES@GOTPAGEOFF]
	tst	w8, w9
	csel	x8, x11, x10, eq
	ldr	w8, [x8]
	str	w8, [x19, #96]
	str	xzr, [x19, #88]
	ldr	x8, [x19, #80]
	movi.2d	v0, #0000000000000000
	stp	q0, q0, [x8]
	stp	q0, q0, [x8, #32]
Lloh9:
	adrp	x24, _GFP_KERNEL@GOTPAGE
Lloh10:
	ldr	x24, [x24, _GFP_KERNEL@GOTPAGEOFF]
	ldr	w2, [x24]
	mov	x0, x23
	mov	w1, #8
	bl	_kcalloc
	str	x0, [x19, #32]
	cbz	x0, LBB0_12
; %bb.1:
	ldr	w2, [x24]
	mov	x0, x23
	mov	w1, #8
	bl	_kcalloc
	str	x0, [x19, #40]
	cbz	x0, LBB0_13
; %bb.2:
	str	w21, [x19, #28]
	str	xzr, [x19, #48]
	ldr	w8, [x19, #24]
	cmp	w8, #1
	b.lt	LBB0_7
; %bb.3:
	mov	x23, #0
	mul	w21, w21, w22
Lloh11:
	adrp	x25, _cx231xx_irq_vbi_callback@GOTPAGE
Lloh12:
	ldr	x25, [x25, _cx231xx_irq_vbi_callback@GOTPAGEOFF]
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w1, [x24]
	mov	w0, #0
	bl	_usb_alloc_urb
	cbz	x0, LBB0_15
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x22, x0
	ldr	x8, [x19, #32]
	str	x0, [x8, x23, lsl #3]
	str	xzr, [x0]
	ldr	w1, [x24]
	mov	x0, x21
	bl	_kzalloc
	ldr	x8, [x19, #40]
	str	w0, [x8, x23, lsl #2]
	cbz	w0, LBB0_14
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w0, [x19, #128]
	ldr	w1, [x19, #56]
	bl	_usb_rcvbulkpipe
	mov	x2, x0
	ldr	w1, [x19, #128]
	ldr	x8, [x19, #40]
	ldr	w3, [x8, x23, lsl #2]
	ldr	w5, [x25]
	mov	x0, x22
	mov	x4, x21
	mov	x6, x20
	bl	_usb_fill_bulk_urb
	add	x23, x23, #1
	ldrsw	x8, [x19, #24]
	cmp	x23, x8
	b.lt	LBB0_4
LBB0_7:
	add	x0, x19, #72
	bl	_init_waitqueue_head
	ldr	w8, [x19, #24]
	cmp	w8, #1
	b.lt	LBB0_11
; %bb.8:
	mov	x21, #0
Lloh13:
	adrp	x22, _GFP_ATOMIC@GOTPAGE
Lloh14:
	ldr	x22, [x22, _GFP_ATOMIC@GOTPAGEOFF]
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #32]
	ldr	x0, [x8, x21, lsl #3]
	ldr	w1, [x22]
	bl	_usb_submit_urb
	cbnz	w0, LBB0_18
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	add	x21, x21, #1
	ldrsw	x8, [x19, #24]
	cmp	x21, x8
	b.lt	LBB0_9
LBB0_11:
Lloh15:
	adrp	x8, _Vbi@GOTPAGE
Lloh16:
	ldr	x8, [x8, _Vbi@GOTPAGEOFF]
Lloh17:
	ldr	w2, [x8]
	mov	x0, x19
	mov	w1, #1
	bl	_cx231xx_capture_start
	mov	w20, #0
	b	LBB0_17
LBB0_12:
	ldr	w0, [x19, #8]
Lloh18:
	adrp	x1, l_.str.1@PAGE
Lloh19:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_dev_err
	b	LBB0_16
LBB0_13:
	ldr	w0, [x19, #8]
Lloh20:
	adrp	x1, l_.str.2@PAGE
Lloh21:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_dev_err
	ldr	x0, [x19, #32]
	bl	_kfree
	b	LBB0_16
LBB0_14:
	ldr	w20, [x19, #8]
	bl	_in_interrupt
Lloh22:
	adrp	x8, l_.str.4@PAGE
Lloh23:
	add	x8, x8, l_.str.4@PAGEOFF
Lloh24:
	adrp	x9, l_.str.5@PAGE
Lloh25:
	add	x9, x9, l_.str.5@PAGEOFF
	cmp	x0, #0
	csel	x8, x9, x8, eq
	stp	x23, x8, [sp, #8]
	str	x21, [sp]
Lloh26:
	adrp	x1, l_.str.3@PAGE
Lloh27:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x20
	bl	_dev_err
LBB0_15:
	mov	x0, x19
	bl	_cx231xx_uninit_vbi_isoc
LBB0_16:
Lloh28:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh29:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh30:
	ldr	w8, [x8]
	neg	w20, w8
LBB0_17:
	mov	x0, x20
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_18:
	mov	x20, x0
	ldr	w0, [x19, #8]
	stp	x21, x20, [sp]
Lloh31:
	adrp	x1, l_.str.6@PAGE
Lloh32:
	add	x1, x1, l_.str.6@PAGEOFF
	bl	_dev_err
	mov	x0, x19
	bl	_cx231xx_uninit_vbi_isoc
	b	LBB0_17
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpAdd	Lloh31, Lloh32
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"called cx231xx_vbi_isoc\n"

	.comm	_V4L2_STD_625_50,4,2            ; @V4L2_STD_625_50
	.comm	_PAL_VBI_LINES,4,2              ; @PAL_VBI_LINES
	.comm	_NTSC_VBI_LINES,4,2             ; @NTSC_VBI_LINES
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
l_.str.1:                               ; @.str.1
	.asciz	"cannot alloc memory for usb buffers\n"

	.comm	_ENOMEM,4,2                     ; @ENOMEM
l_.str.2:                               ; @.str.2
	.asciz	"cannot allocate memory for usbtransfer\n"

l_.str.3:                               ; @.str.3
	.asciz	"unable to allocate %i bytes for transfer buffer %i%s\n"

l_.str.4:                               ; @.str.4
	.asciz	" while in int"

l_.str.5:                               ; @.str.5
	.space	1

	.comm	_cx231xx_irq_vbi_callback,4,2   ; @cx231xx_irq_vbi_callback
	.comm	_GFP_ATOMIC,4,2                 ; @GFP_ATOMIC
l_.str.6:                               ; @.str.6
	.asciz	"submit of urb %i failed (error=%i)\n"

	.comm	_Vbi,4,2                        ; @Vbi
.subsections_via_symbols
