	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function set_tvnorm
_set_tvnorm:                            ## @set_tvnorm
	.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	%rsi, %r14
	movq	%rdi, %rbx
	movl	32(%rsi), %esi
	leaq	L_.str(%rip), %rdi
	callq	_video_dbg
	movq	%r14, 72(%rbx)
	movq	16(%r14), %rax
	movq	%rax, 64(%rbx)
	movq	%rax, 16(%rbx)
	movq	24(%r14), %rcx
	subq	%rax, %rcx
	incq	%rcx
	movq	%rcx, 56(%rbx)
	movq	%rcx, 8(%rbx)
	movl	(%r14), %ecx
	addl	%ecx, %ecx
	addl	$2, %ecx
	movl	%ecx, 48(%rbx)
	movl	4(%r14), %edx
	leal	(%rdx,%rdx), %esi
	movl	%esi, (%rbx)
	movq	_V4L2_STD_525_60@GOTPCREL(%rip), %rsi
	movl	(%rsi), %esi
	andl	8(%r14), %esi
	movl	$624, %esi                      ## imm = 0x270
	movl	$524, %edi                      ## imm = 0x20C
	cmovel	%esi, %edi
	subl	%ecx, %edi
	movl	%edi, 52(%rbx)
	movl	12(%r14), %ecx
	subl	%edx, %ecx
	addl	%ecx, %ecx
	addl	$2, %ecx
	movl	%ecx, 4(%rbx)
	movq	%rax, 40(%rbx)
	movl	(%rbx), %eax
	movl	%eax, 24(%rbx)
	movl	4(%rbx), %eax
	movl	%eax, 28(%rbx)
	movq	8(%rbx), %rax
	movq	%rax, 32(%rbx)
	movq	%rbx, %rdi
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_saa7134_set_tvnorm_hw          ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"set tv norm = %s\n"

	.comm	_V4L2_STD_525_60,4,2            ## @V4L2_STD_525_60
	.no_dead_strip	_set_tvnorm
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function set_tvnorm
_set_tvnorm:                            ; @set_tvnorm
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x1
	mov	x20, x0
	ldr	w1, [x1, #32]
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_video_dbg
	str	x19, [x20, #72]
	ldp	x8, x9, [x19, #16]
	sub	x9, x9, x8
	add	x9, x9, #1
	stp	x9, x8, [x20, #56]
	stp	x9, x8, [x20, #8]
	ldp	w9, w10, [x19]
	lsl	w9, w9, #1
	add	w9, w9, #2
	lsl	w11, w10, #1
	ldp	w12, w13, [x19, #8]
	sub	w10, w13, w10
	lsl	w10, w10, #1
	add	w10, w10, #2
	str	w11, [x20]
Lloh2:
	adrp	x11, _V4L2_STD_525_60@GOTPAGE
Lloh3:
	ldr	x11, [x11, _V4L2_STD_525_60@GOTPAGEOFF]
Lloh4:
	ldr	w11, [x11]
	tst	w11, w12
	mov	w11, #524
	mov	w12, #624
	csel	w11, w12, w11, eq
	sub	w11, w11, w9
	stp	w9, w11, [x20, #48]
	str	w10, [x20, #4]
	str	x8, [x20, #40]
	ldr	q0, [x20]
	stur	q0, [x20, #24]
	mov	x0, x20
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_saa7134_set_tvnorm_hw
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"set tv norm = %s\n"

	.comm	_V4L2_STD_525_60,4,2            ; @V4L2_STD_525_60
	.no_dead_strip	_set_tvnorm
.subsections_via_symbols
