	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mt2050_set_tv_freq
_mt2050_set_tv_freq:                    ## @mt2050_set_tv_freq
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	%rdi, %rbx
	movq	_V4L2_STD_525_60@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	(%rsi), %eax
	movl	$38900000, %eax                 ## imm = 0x2519120
	movl	$45750000, %ecx                 ## imm = 0x2BA16F0
	cmovel	%eax, %ecx
	movq	_V4L2_TUNER_DIGITAL_TV@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	8(%rsi), %rax
	movl	$36150000, %edx                 ## imm = 0x2279AF0
	cmovnel	%ecx, %edx
	imull	$62500, 16(%rsi), %esi          ## imm = 0xF424
	callq	_mt2050_set_if_freq
	movq	_tv_antenna@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_mt2050_set_antenna
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_V4L2_STD_525_60,4,2            ## @V4L2_STD_525_60
	.comm	_V4L2_TUNER_DIGITAL_TV,8,3      ## @V4L2_TUNER_DIGITAL_TV
	.comm	_tv_antenna,4,2                 ## @tv_antenna
	.no_dead_strip	_mt2050_set_tv_freq
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mt2050_set_tv_freq
_mt2050_set_tv_freq:                    ; @mt2050_set_tv_freq
	.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, x0
	ldr	w8, [x1]
Lloh0:
	adrp	x9, _V4L2_STD_525_60@GOTPAGE
Lloh1:
	ldr	x9, [x9, _V4L2_STD_525_60@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	mov	w8, #5872
	movk	w8, #698, lsl #16
	mov	w9, #37152
	movk	w9, #593, lsl #16
	csel	w8, w9, w8, eq
Lloh3:
	adrp	x9, _V4L2_TUNER_DIGITAL_TV@GOTPAGE
Lloh4:
	ldr	x9, [x9, _V4L2_TUNER_DIGITAL_TV@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	ldr	x10, [x1, #8]
	cmp	x9, x10
	mov	w9, #39664
	movk	w9, #551, lsl #16
	csel	w2, w9, w8, eq
	ldr	w8, [x1, #16]
	mov	w9, #62500
	mul	w1, w8, w9
	bl	_mt2050_set_if_freq
Lloh6:
	adrp	x8, _tv_antenna@GOTPAGE
Lloh7:
	ldr	x8, [x8, _tv_antenna@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_mt2050_set_antenna
	mov	w0, #0
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_V4L2_STD_525_60,4,2            ; @V4L2_STD_525_60
	.comm	_V4L2_TUNER_DIGITAL_TV,8,3      ; @V4L2_TUNER_DIGITAL_TV
	.comm	_tv_antenna,4,2                 ; @tv_antenna
	.no_dead_strip	_mt2050_set_tv_freq
.subsections_via_symbols
