	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function coda_enum_fmt
_coda_enum_fmt:                         ## @coda_enum_fmt
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r15
	movq	%rsi, %rbx
	callq	_video_devdata
	movq	%rax, %rdi
	callq	_to_coda_video_device
	movq	%rax, %r14
	movq	%rbx, %rdi
	callq	_fh_to_ctx
	movq	(%r15), %rcx
	movq	_V4L2_BUF_TYPE_VIDEO_OUTPUT@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	je	LBB0_3
## %bb.1:
	movq	_V4L2_BUF_TYPE_VIDEO_CAPTURE@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jne	LBB0_8
## %bb.2:
	addq	$8, %r14
LBB0_3:
	movq	8(%r15), %rdx
	movq	_CODA_MAX_FORMATS@GOTPCREL(%rip), %rsi
	cmpq	(%rsi), %rdx
	jae	LBB0_8
## %bb.4:
	movq	(%r14), %rsi
	movq	(%rsi,%rdx,8), %rdx
	testq	%rdx, %rdx
	je	LBB0_8
## %bb.5:
	cmpl	$0, (%rax)
	je	LBB0_6
LBB0_9:
	movq	%rdx, 16(%r15)
	xorl	%eax, %eax
	jmp	LBB0_10
LBB0_6:
	movq	_V4L2_BUF_TYPE_VIDEO_CAPTURE@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rcx
	jne	LBB0_9
## %bb.7:
	movq	_V4L2_PIX_FMT_YUYV@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rdx
	jne	LBB0_9
LBB0_8:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_10:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_V4L2_BUF_TYPE_VIDEO_OUTPUT,8,3 ## @V4L2_BUF_TYPE_VIDEO_OUTPUT
	.comm	_V4L2_BUF_TYPE_VIDEO_CAPTURE,8,3 ## @V4L2_BUF_TYPE_VIDEO_CAPTURE
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_CODA_MAX_FORMATS,8,3           ## @CODA_MAX_FORMATS
	.comm	_V4L2_PIX_FMT_YUYV,8,3          ## @V4L2_PIX_FMT_YUYV
	.no_dead_strip	_coda_enum_fmt
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function coda_enum_fmt
_coda_enum_fmt:                         ; @coda_enum_fmt
	.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	x19, x2
	mov	x21, x1
	bl	_video_devdata
	bl	_to_coda_video_device
	mov	x20, x0
	mov	x0, x21
	bl	_fh_to_ctx
	ldr	x8, [x19]
Lloh0:
	adrp	x9, _V4L2_BUF_TYPE_VIDEO_OUTPUT@GOTPAGE
Lloh1:
	ldr	x9, [x9, _V4L2_BUF_TYPE_VIDEO_OUTPUT@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.eq	LBB0_3
; %bb.1:
Lloh3:
	adrp	x9, _V4L2_BUF_TYPE_VIDEO_CAPTURE@GOTPAGE
Lloh4:
	ldr	x9, [x9, _V4L2_BUF_TYPE_VIDEO_CAPTURE@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_8
; %bb.2:
	add	x20, x20, #8
LBB0_3:
	ldr	x9, [x19, #8]
Lloh6:
	adrp	x10, _CODA_MAX_FORMATS@GOTPAGE
Lloh7:
	ldr	x10, [x10, _CODA_MAX_FORMATS@GOTPAGEOFF]
Lloh8:
	ldr	x10, [x10]
	cmp	x9, x10
	b.hs	LBB0_8
; %bb.4:
	ldr	x10, [x20]
	ldr	x9, [x10, x9, lsl #3]
	cbz	x9, LBB0_8
; %bb.5:
	ldr	w10, [x0]
	cbnz	w10, LBB0_7
; %bb.6:
Lloh9:
	adrp	x10, _V4L2_BUF_TYPE_VIDEO_CAPTURE@GOTPAGE
Lloh10:
	ldr	x10, [x10, _V4L2_BUF_TYPE_VIDEO_CAPTURE@GOTPAGEOFF]
Lloh11:
	ldr	x10, [x10]
Lloh12:
	adrp	x11, _V4L2_PIX_FMT_YUYV@GOTPAGE
Lloh13:
	ldr	x11, [x11, _V4L2_PIX_FMT_YUYV@GOTPAGEOFF]
Lloh14:
	ldr	x11, [x11]
	cmp	x8, x10
	ccmp	x9, x11, #0, eq
	b.eq	LBB0_8
LBB0_7:
	mov	w0, #0
	str	x9, [x19, #16]
	b	LBB0_9
LBB0_8:
Lloh15:
	adrp	x8, _EINVAL@GOTPAGE
Lloh16:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_9:
	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	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_V4L2_BUF_TYPE_VIDEO_OUTPUT,8,3 ; @V4L2_BUF_TYPE_VIDEO_OUTPUT
	.comm	_V4L2_BUF_TYPE_VIDEO_CAPTURE,8,3 ; @V4L2_BUF_TYPE_VIDEO_CAPTURE
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_CODA_MAX_FORMATS,8,3           ; @CODA_MAX_FORMATS
	.comm	_V4L2_PIX_FMT_YUYV,8,3          ; @V4L2_PIX_FMT_YUYV
	.no_dead_strip	_coda_enum_fmt
.subsections_via_symbols
