	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bttv_g_selection
_bttv_g_selection:                      ## @bttv_g_selection
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movq	8(%rsi), %rax
	movq	(%rdx), %rcx
	movq	_V4L2_BUF_TYPE_VIDEO_CAPTURE@GOTPCREL(%rip), %rdi
	cmpq	(%rdi), %rcx
	je	LBB0_2
## %bb.1:
	movq	_V4L2_BUF_TYPE_VIDEO_OVERLAY@GOTPCREL(%rip), %rdi
	cmpq	(%rdi), %rcx
	je	LBB0_2
LBB0_9:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	popq	%rbp
	retq
LBB0_2:
	movl	8(%rdx), %ecx
	cmpl	$128, %ecx
	je	LBB0_7
## %bb.3:
	cmpl	$129, %ecx
	je	LBB0_8
## %bb.4:
	cmpl	$130, %ecx
	jne	LBB0_9
## %bb.5:
	movq	8(%rax), %rax
	xorl	%ecx, %ecx
	cmpl	$0, (%rsi)
	setne	%cl
	movl	(%rax,%rcx,4), %eax
	jmp	LBB0_6
LBB0_7:
	movq	_bttv_tvnorms@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	(%rax), %rax
	movl	4(%rcx,%rax,8), %eax
	jmp	LBB0_6
LBB0_8:
	movq	_bttv_tvnorms@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	(%rax), %rax
	movl	(%rcx,%rax,8), %eax
LBB0_6:
	movl	%eax, 12(%rdx)
	xorl	%eax, %eax
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_V4L2_BUF_TYPE_VIDEO_CAPTURE,8,3 ## @V4L2_BUF_TYPE_VIDEO_CAPTURE
	.comm	_V4L2_BUF_TYPE_VIDEO_OVERLAY,8,3 ## @V4L2_BUF_TYPE_VIDEO_OVERLAY
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_bttv_tvnorms,8,3               ## @bttv_tvnorms
	.no_dead_strip	_bttv_g_selection
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bttv_g_selection
_bttv_g_selection:                      ; @bttv_g_selection
	.cfi_startproc
; %bb.0:
	ldr	x8, [x2]
Lloh0:
	adrp	x9, _V4L2_BUF_TYPE_VIDEO_CAPTURE@GOTPAGE
Lloh1:
	ldr	x9, [x9, _V4L2_BUF_TYPE_VIDEO_CAPTURE@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
Lloh3:
	adrp	x10, _V4L2_BUF_TYPE_VIDEO_OVERLAY@GOTPAGE
Lloh4:
	ldr	x10, [x10, _V4L2_BUF_TYPE_VIDEO_OVERLAY@GOTPAGEOFF]
Lloh5:
	ldr	x10, [x10]
	cmp	x8, x9
	ccmp	x8, x10, #4, ne
	b.ne	LBB0_5
; %bb.1:
	ldr	x8, [x1, #8]
	ldr	w9, [x2, #8]
	cmp	w9, #128
	b.eq	LBB0_6
; %bb.2:
	cmp	w9, #129
	b.eq	LBB0_7
; %bb.3:
	cmp	w9, #130
	b.ne	LBB0_5
; %bb.4:
	mov	w0, #0
	ldr	x8, [x8, #8]
	ldr	w9, [x1]
	cmp	w9, #0
	cset	w9, ne
	ldr	w8, [x8, w9, uxtw #2]
	str	w8, [x2, #12]
	ret
LBB0_5:
Lloh6:
	adrp	x8, _EINVAL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	neg	w0, w8
	ret
LBB0_6:
	mov	w0, #0
Lloh9:
	adrp	x9, _bttv_tvnorms@GOTPAGE
Lloh10:
	ldr	x9, [x9, _bttv_tvnorms@GOTPAGEOFF]
Lloh11:
	ldr	x9, [x9]
	ldr	x8, [x8]
	add	x8, x9, x8, lsl #3
	ldr	w8, [x8, #4]
	str	w8, [x2, #12]
	ret
LBB0_7:
	mov	w0, #0
Lloh12:
	adrp	x9, _bttv_tvnorms@GOTPAGE
Lloh13:
	ldr	x9, [x9, _bttv_tvnorms@GOTPAGEOFF]
Lloh14:
	ldr	x9, [x9]
	ldr	x8, [x8]
	lsl	x8, x8, #3
	ldr	w8, [x9, x8]
	str	w8, [x2, #12]
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_V4L2_BUF_TYPE_VIDEO_CAPTURE,8,3 ; @V4L2_BUF_TYPE_VIDEO_CAPTURE
	.comm	_V4L2_BUF_TYPE_VIDEO_OVERLAY,8,3 ; @V4L2_BUF_TYPE_VIDEO_OVERLAY
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_bttv_tvnorms,8,3               ; @bttv_tvnorms
	.no_dead_strip	_bttv_g_selection
.subsections_via_symbols
