	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function fops_open
_fops_open:                             ## @fops_open
	.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
	movq	%rdi, %r12
	callq	_video_devdata
	movq	%rax, %rbx
	movq	%r12, %rdi
	callq	_video_drvdata
	movq	%rax, %r14
	movq	%rbx, %rdi
	callq	_video_device_node_name
	movslq	%eax, %rdi
	callq	_DEB_EE
	movq	_saa7146_devices_lock@GOTPCREL(%rip), %rdi
	callq	_mutex_lock_interruptible
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movq	_ERESTARTSYS@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_23
LBB0_2:
	movq	%r14, %rdi
	callq	_DEB_D
	movq	(%rbx), %rax
	movq	_VFL_TYPE_GRABBER@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_3
## %bb.4:
	movq	_V4L2_BUF_TYPE_VIDEO_CAPTURE@GOTPCREL(%rip), %rax
	cmpq	$0, (%r14)
	je	LBB0_6
LBB0_8:
	movq	(%rax), %rbx
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$16, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_9
## %bb.10:
	movq	%rax, %r15
	movq	%rax, (%r12)
	movq	%r14, 8(%rax)
	movl	%ebx, (%rax)
	movslq	%ebx, %rax
	movq	_V4L2_BUF_TYPE_VBI_CAPTURE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_16
## %bb.11:
	leaq	L_.str.4(%rip), %rdi
	callq	_DEB_S
	movq	8(%r14), %rax
	movq	_V4L2_CAP_VBI_CAPTURE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	testl	%ecx, (%rax)
	je	LBB0_12
## %bb.13:
	movq	_saa7146_vbi_uops@GOTPCREL(%rip), %rax
	movq	%r14, %rdi
	movq	%r12, %rsi
	callq	*(%rax)
	movl	%eax, %ebx
	movq	8(%r14), %rax
	jmp	LBB0_14
LBB0_3:
	movq	_V4L2_BUF_TYPE_VBI_CAPTURE@GOTPCREL(%rip), %rax
	cmpq	$0, (%r14)
	jne	LBB0_8
LBB0_6:
	leaq	L_.str.2(%rip), %rdi
	callq	_DEB_S
	movq	_ENODEV@GOTPCREL(%rip), %rax
	jmp	LBB0_7
LBB0_9:
	leaq	L_.str.3(%rip), %rdi
	callq	_DEB_S
	movq	_ENOMEM@GOTPCREL(%rip), %rax
LBB0_7:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_22
LBB0_16:
	leaq	L_.str.5(%rip), %rdi
	callq	_DEB_S
	movq	_saa7146_video_uops@GOTPCREL(%rip), %rax
	movq	%r14, %rdi
	movq	%r12, %rsi
	callq	*(%rax)
	movl	%eax, %ebx
	jmp	LBB0_17
LBB0_12:
	xorl	%ebx, %ebx
LBB0_14:
	movq	8(%rax), %rcx
	testq	%rcx, %rcx
	je	LBB0_17
## %bb.15:
	movq	%r12, %rdi
	callq	*%rcx
LBB0_17:
	testl	%ebx, %ebx
	je	LBB0_18
LBB0_21:
	movq	%r15, %rdi
	callq	_kfree
	movq	$0, (%r12)
	jmp	LBB0_22
LBB0_18:
	movq	(%r14), %rax
	movl	(%rax), %edi
	callq	_try_module_get
	xorl	%ebx, %ebx
	testq	%rax, %rax
	je	LBB0_19
LBB0_22:
	movq	_saa7146_devices_lock@GOTPCREL(%rip), %rdi
	callq	_mutex_unlock
LBB0_23:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_19:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, %eax
	je	LBB0_22
## %bb.20:
	negl	%eax
	movl	%eax, %ebx
	jmp	LBB0_21
	.cfi_endproc
                                        ## -- End function
	.comm	_saa7146_devices_lock,4,2       ## @saa7146_devices_lock
	.comm	_ERESTARTSYS,4,2                ## @ERESTARTSYS
	.comm	_VFL_TYPE_GRABBER,8,3           ## @VFL_TYPE_GRABBER
	.comm	_V4L2_BUF_TYPE_VIDEO_CAPTURE,8,3 ## @V4L2_BUF_TYPE_VIDEO_CAPTURE
	.comm	_V4L2_BUF_TYPE_VBI_CAPTURE,8,3  ## @V4L2_BUF_TYPE_VBI_CAPTURE
	.section	__TEXT,__cstring,cstring_literals
L_.str.2:                               ## @.str.2
	.asciz	"no extension registered for this device.\n"

	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
L_.str.3:                               ## @.str.3
	.asciz	"cannot allocate memory for per open data.\n"

	.comm	_ENOMEM,4,2                     ## @ENOMEM
L_.str.4:                               ## @.str.4
	.asciz	"initializing vbi...\n"

	.comm	_V4L2_CAP_VBI_CAPTURE,4,2       ## @V4L2_CAP_VBI_CAPTURE
	.comm	_saa7146_vbi_uops,8,3           ## @saa7146_vbi_uops
L_.str.5:                               ## @.str.5
	.asciz	"initializing video...\n"

	.comm	_saa7146_video_uops,8,3         ## @saa7146_video_uops
	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_fops_open
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function fops_open
_fops_open:                             ; @fops_open
	.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, x0
	bl	_video_devdata
	mov	x21, x0
	mov	x0, x19
	bl	_video_drvdata
	mov	x20, x0
	mov	x0, x21
	bl	_video_device_node_name
                                        ; kill: def $w0 killed $w0 def $x0
	sxtw	x0, w0
	bl	_DEB_EE
Lloh0:
	adrp	x0, _saa7146_devices_lock@GOTPAGE
Lloh1:
	ldr	x0, [x0, _saa7146_devices_lock@GOTPAGEOFF]
	bl	_mutex_lock_interruptible
	cbz	x0, LBB0_2
; %bb.1:
Lloh2:
	adrp	x8, _ERESTARTSYS@GOTPAGE
Lloh3:
	ldr	x8, [x8, _ERESTARTSYS@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_18
LBB0_2:
	mov	x0, x20
	bl	_DEB_D
	ldr	x8, [x21]
Lloh5:
	adrp	x9, _VFL_TYPE_GRABBER@GOTPAGE
Lloh6:
	ldr	x9, [x9, _VFL_TYPE_GRABBER@GOTPAGEOFF]
Lloh7:
	adrp	x10, _V4L2_BUF_TYPE_VIDEO_CAPTURE@GOTPAGE
Lloh8:
	ldr	x10, [x10, _V4L2_BUF_TYPE_VIDEO_CAPTURE@GOTPAGEOFF]
Lloh9:
	ldr	x9, [x9]
Lloh10:
	adrp	x22, _V4L2_BUF_TYPE_VBI_CAPTURE@GOTPAGE
Lloh11:
	ldr	x22, [x22, _V4L2_BUF_TYPE_VBI_CAPTURE@GOTPAGEOFF]
	cmp	x8, x9
	csel	x8, x10, x22, eq
	ldr	x9, [x20]
	cbz	x9, LBB0_7
; %bb.3:
	ldr	x23, [x8]
Lloh12:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh13:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	mov	w0, #16
	bl	_kzalloc
	cbz	x0, LBB0_8
; %bb.4:
	mov	x21, x0
	str	x0, [x19]
	str	x20, [x0, #8]
	str	w23, [x0]
	ldr	x8, [x22]
	cmp	x8, w23, sxtw
	b.ne	LBB0_10
; %bb.5:
Lloh15:
	adrp	x0, l_.str.4@PAGE
Lloh16:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	_DEB_S
	ldr	x8, [x20, #8]
	ldr	w9, [x8]
Lloh17:
	adrp	x10, _V4L2_CAP_VBI_CAPTURE@GOTPAGE
Lloh18:
	ldr	x10, [x10, _V4L2_CAP_VBI_CAPTURE@GOTPAGEOFF]
Lloh19:
	ldr	w10, [x10]
	tst	w10, w9
	b.eq	LBB0_11
; %bb.6:
Lloh20:
	adrp	x8, _saa7146_vbi_uops@GOTPAGE
Lloh21:
	ldr	x8, [x8, _saa7146_vbi_uops@GOTPAGEOFF]
Lloh22:
	ldr	x8, [x8]
	mov	x0, x20
	mov	x1, x19
	blr	x8
	mov	x22, x0
	ldr	x8, [x20, #8]
	ldr	x8, [x8, #8]
	cbnz	x8, LBB0_12
	b	LBB0_13
LBB0_7:
Lloh23:
	adrp	x0, l_.str.2@PAGE
Lloh24:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_DEB_S
Lloh25:
	adrp	x8, _ENODEV@GOTPAGE
Lloh26:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
	b	LBB0_9
LBB0_8:
Lloh27:
	adrp	x0, l_.str.3@PAGE
Lloh28:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_DEB_S
Lloh29:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh30:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
LBB0_9:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_17
LBB0_10:
Lloh31:
	adrp	x0, l_.str.5@PAGE
Lloh32:
	add	x0, x0, l_.str.5@PAGEOFF
	bl	_DEB_S
Lloh33:
	adrp	x8, _saa7146_video_uops@GOTPAGE
Lloh34:
	ldr	x8, [x8, _saa7146_video_uops@GOTPAGEOFF]
Lloh35:
	ldr	x8, [x8]
	mov	x0, x20
	mov	x1, x19
	blr	x8
	mov	x22, x0
	b	LBB0_13
LBB0_11:
	mov	w22, #0
	ldr	x8, [x8, #8]
	cbz	x8, LBB0_13
LBB0_12:
	mov	x0, x19
	blr	x8
LBB0_13:
	cbz	w22, LBB0_15
LBB0_14:
	mov	x0, x21
	bl	_kfree
	str	xzr, [x19]
	b	LBB0_17
LBB0_15:
	ldr	x8, [x20]
	ldr	w0, [x8]
	bl	_try_module_get
	cbz	x0, LBB0_19
LBB0_16:
	mov	w22, #0
LBB0_17:
Lloh36:
	adrp	x0, _saa7146_devices_lock@GOTPAGE
Lloh37:
	ldr	x0, [x0, _saa7146_devices_lock@GOTPAGEOFF]
	bl	_mutex_unlock
LBB0_18:
	mov	x0, x22
	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_19:
Lloh38:
	adrp	x8, _EINVAL@GOTPAGE
Lloh39:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh40:
	ldr	w8, [x8]
	cbz	w8, LBB0_16
; %bb.20:
	neg	w22, w8
	b	LBB0_14
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh9
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh25, Lloh26
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGot	Lloh29, Lloh30
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpAdd	Lloh31, Lloh32
	.loh AdrpLdrGot	Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh40
	.cfi_endproc
                                        ; -- End function
	.comm	_saa7146_devices_lock,4,2       ; @saa7146_devices_lock
	.comm	_ERESTARTSYS,4,2                ; @ERESTARTSYS
	.comm	_VFL_TYPE_GRABBER,8,3           ; @VFL_TYPE_GRABBER
	.comm	_V4L2_BUF_TYPE_VIDEO_CAPTURE,8,3 ; @V4L2_BUF_TYPE_VIDEO_CAPTURE
	.comm	_V4L2_BUF_TYPE_VBI_CAPTURE,8,3  ; @V4L2_BUF_TYPE_VBI_CAPTURE
	.section	__TEXT,__cstring,cstring_literals
l_.str.2:                               ; @.str.2
	.asciz	"no extension registered for this device.\n"

	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
l_.str.3:                               ; @.str.3
	.asciz	"cannot allocate memory for per open data.\n"

	.comm	_ENOMEM,4,2                     ; @ENOMEM
l_.str.4:                               ; @.str.4
	.asciz	"initializing vbi...\n"

	.comm	_V4L2_CAP_VBI_CAPTURE,4,2       ; @V4L2_CAP_VBI_CAPTURE
	.comm	_saa7146_vbi_uops,8,3           ; @saa7146_vbi_uops
l_.str.5:                               ; @.str.5
	.asciz	"initializing video...\n"

	.comm	_saa7146_video_uops,8,3         ; @saa7146_video_uops
	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_fops_open
.subsections_via_symbols
