	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function blackbird_register_video
_blackbird_register_video:              ## @blackbird_register_video
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	movq	24(%rdi), %rdi
	movl	40(%rbx), %esi
	movq	_cx8802_mpeg_template@GOTPCREL(%rip), %rcx
	leaq	L_.str(%rip), %r8
	movq	%rbx, %rdx
	callq	_cx88_vdev_init
	leaq	36(%rbx), %rax
	movq	%rax, 16(%rbx)
	movq	%rbx, %rdi
	movq	%rbx, %rsi
	callq	_video_set_drvdata
	leaq	32(%rbx), %rax
	movq	%rax, 8(%rbx)
	movq	_V4L2_CAP_READWRITE@GOTPCREL(%rip), %rcx
	movq	_V4L2_CAP_STREAMING@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	(%rcx), %eax
	movq	_V4L2_CAP_VIDEO_CAPTURE@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	%eax, (%rbx)
	movq	24(%rbx), %rcx
	movq	(%rcx), %rcx
	movq	_UNSET@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	je	LBB0_2
## %bb.1:
	movq	_V4L2_CAP_TUNER@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	%eax, (%rbx)
LBB0_2:
	movq	_VFL_TYPE_GRABBER@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movl	$-1, %edx
	callq	_video_register_device
	testl	%eax, %eax
	js	LBB0_3
## %bb.4:
	movq	%rbx, %rdi
	callq	_video_device_node_name
	leaq	L_.str.2(%rip), %rdi
	xorl	%r14d, %r14d
	movl	%eax, %esi
	xorl	%eax, %eax
	callq	_pr_info
	jmp	LBB0_5
LBB0_3:
	movl	%eax, %r14d
	leaq	L_.str.1(%rip), %rdi
	xorl	%eax, %eax
	callq	_pr_info
LBB0_5:
	movl	%r14d, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_cx8802_mpeg_template,4,2       ## @cx8802_mpeg_template
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"mpeg"

	.comm	_V4L2_CAP_READWRITE,4,2         ## @V4L2_CAP_READWRITE
	.comm	_V4L2_CAP_STREAMING,4,2         ## @V4L2_CAP_STREAMING
	.comm	_V4L2_CAP_VIDEO_CAPTURE,4,2     ## @V4L2_CAP_VIDEO_CAPTURE
	.comm	_UNSET,8,3                      ## @UNSET
	.comm	_V4L2_CAP_TUNER,4,2             ## @V4L2_CAP_TUNER
	.comm	_VFL_TYPE_GRABBER,4,2           ## @VFL_TYPE_GRABBER
L_.str.1:                               ## @.str.1
	.asciz	"can't register mpeg device\n"

L_.str.2:                               ## @.str.2
	.asciz	"registered device %s [mpeg]\n"

	.no_dead_strip	_blackbird_register_video
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function blackbird_register_video
_blackbird_register_video:              ; @blackbird_register_video
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	mov	x19, x0
	ldr	x0, [x0, #24]
	ldr	w1, [x19, #40]
Lloh0:
	adrp	x3, _cx8802_mpeg_template@GOTPAGE
Lloh1:
	ldr	x3, [x3, _cx8802_mpeg_template@GOTPAGEOFF]
Lloh2:
	adrp	x4, l_.str@PAGE
Lloh3:
	add	x4, x4, l_.str@PAGEOFF
	mov	x2, x19
	bl	_cx88_vdev_init
	add	x8, x19, #36
	str	x8, [x19, #16]
	mov	x0, x19
	mov	x1, x19
	bl	_video_set_drvdata
	add	x8, x19, #32
	str	x8, [x19, #8]
Lloh4:
	adrp	x8, _V4L2_CAP_READWRITE@GOTPAGE
Lloh5:
	ldr	x8, [x8, _V4L2_CAP_READWRITE@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
Lloh7:
	adrp	x9, _V4L2_CAP_STREAMING@GOTPAGE
Lloh8:
	ldr	x9, [x9, _V4L2_CAP_STREAMING@GOTPAGEOFF]
Lloh9:
	ldr	w9, [x9]
	orr	w8, w9, w8
Lloh10:
	adrp	x9, _V4L2_CAP_VIDEO_CAPTURE@GOTPAGE
Lloh11:
	ldr	x9, [x9, _V4L2_CAP_VIDEO_CAPTURE@GOTPAGEOFF]
Lloh12:
	ldr	w9, [x9]
	orr	w8, w8, w9
	str	w8, [x19]
	ldr	x9, [x19, #24]
	ldr	x9, [x9]
Lloh13:
	adrp	x10, _UNSET@GOTPAGE
Lloh14:
	ldr	x10, [x10, _UNSET@GOTPAGEOFF]
Lloh15:
	ldr	x10, [x10]
	cmp	x9, x10
	b.eq	LBB0_2
; %bb.1:
Lloh16:
	adrp	x9, _V4L2_CAP_TUNER@GOTPAGE
Lloh17:
	ldr	x9, [x9, _V4L2_CAP_TUNER@GOTPAGEOFF]
Lloh18:
	ldr	w9, [x9]
	orr	w8, w9, w8
	str	w8, [x19]
LBB0_2:
Lloh19:
	adrp	x8, _VFL_TYPE_GRABBER@GOTPAGE
Lloh20:
	ldr	x8, [x8, _VFL_TYPE_GRABBER@GOTPAGEOFF]
Lloh21:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #-1
	bl	_video_register_device
	tbnz	w0, #31, LBB0_4
; %bb.3:
	mov	x0, x19
	bl	_video_device_node_name
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh22:
	adrp	x0, l_.str.2@PAGE
Lloh23:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_pr_info
	mov	w20, #0
	b	LBB0_5
LBB0_4:
	mov	x20, x0
Lloh24:
	adrp	x0, l_.str.1@PAGE
Lloh25:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_pr_info
LBB0_5:
	mov	x0, x20
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpAdd	Lloh24, Lloh25
	.cfi_endproc
                                        ; -- End function
	.comm	_cx8802_mpeg_template,4,2       ; @cx8802_mpeg_template
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"mpeg"

	.comm	_V4L2_CAP_READWRITE,4,2         ; @V4L2_CAP_READWRITE
	.comm	_V4L2_CAP_STREAMING,4,2         ; @V4L2_CAP_STREAMING
	.comm	_V4L2_CAP_VIDEO_CAPTURE,4,2     ; @V4L2_CAP_VIDEO_CAPTURE
	.comm	_UNSET,8,3                      ; @UNSET
	.comm	_V4L2_CAP_TUNER,4,2             ; @V4L2_CAP_TUNER
	.comm	_VFL_TYPE_GRABBER,4,2           ; @VFL_TYPE_GRABBER
l_.str.1:                               ; @.str.1
	.asciz	"can't register mpeg device\n"

l_.str.2:                               ; @.str.2
	.asciz	"registered device %s [mpeg]\n"

	.no_dead_strip	_blackbird_register_video
.subsections_via_symbols
