	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function stv090x_srate_srch_coarse
_stv090x_srate_srch_coarse:             ## @stv090x_srate_srch_coarse
	.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	%r13
	pushq	%r12
	pushq	%rbx
	subq	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r13
	movq	16(%rdi), %rax
	cmpl	$48, (%rax)
	movl	$11776, %eax                    ## imm = 0x2E00
	movl	$7936, %r15d                    ## imm = 0x1F00
	cmovgel	%eax, %r15d
	movq	_DMDISTATE@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	callq	_STV090x_READ_DEMOD
	movl	%eax, %ebx
	movl	%eax, -44(%rbp)
	movq	_I2C_DEMOD_MODE_FIELD@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%ebx, %edi
	movl	$31, %edx
	callq	_STV090x_SETFIELD_Px
	movl	(%r12), %esi
	movq	%r13, %rdi
	movl	%ebx, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.1:
	movq	_TMGCFG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$18, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.2:
	movq	_TMGCFG2@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$192, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.3:
	movq	_TMGTHRISE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$240, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.4:
	movq	_TMGTHFALL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$224, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.5:
	movq	_DMDCFGMD@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	movq	%r13, %rdi
	callq	_STV090x_READ_DEMOD
	movl	%eax, %ebx
	movl	%eax, -44(%rbp)
	movq	_SCAN_ENABLE_FIELD@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%ebx, %edi
	movl	$1, %edx
	callq	_STV090x_SETFIELD_Px
	movq	_CFR_AUTOSCAN_FIELD@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%ebx, %edi
	xorl	%edx, %edx
	callq	_STV090x_SETFIELD_Px
	movl	(%r14), %esi
	movq	%r13, %rdi
	movl	%ebx, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.6:
	movq	_SFRUP1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$131, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.7:
	movq	_SFRUP0@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$192, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.8:
	movq	_SFRLOW1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$130, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.9:
	movq	_SFRLOW0@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$160, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.10:
	movq	_DMDTOM@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	xorl	%edx, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.11:
	movq	_AGC2REF@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$80, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.12:
	movq	16(%r13), %rax
	movl	(%rax), %eax
	cmpl	$48, %eax
	jl	LBB0_15
## %bb.13:
	movq	_CARFREQ@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$153, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.14:
	movq	_SFRSTEP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$152, %edx
	jmp	LBB0_18
LBB0_15:
	cmpl	$32, %eax
	jl	LBB0_19
## %bb.16:
	movq	_CARFREQ@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$106, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.17:
	movq	_SFRSTEP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$149, %edx
LBB0_18:
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
LBB0_19:
	movl	(%r13), %eax
	movl	$1000, %edi                     ## imm = 0x3E8
	cmpl	$2000001, %eax                  ## imm = 0x1E8481
	jl	LBB0_22
## %bb.20:
	movl	$2000, %edi                     ## imm = 0x7D0
	cmpl	$5000001, %eax                  ## imm = 0x4C4B41
	jb	LBB0_22
## %bb.21:
	cmpl	$12000001, %eax                 ## imm = 0xB71B01
	movl	$3000, %eax                     ## imm = 0xBB8
	movl	$5000, %edi                     ## imm = 0x1388
	cmovbl	%eax, %edi
LBB0_22:
	movslq	4(%r13), %rsi
	imulq	$274877907, %rsi, %rax          ## imm = 0x10624DD3
	movq	%rax, %rcx
	shrq	$63, %rcx
	sarq	$38, %rax
	addl	%ecx, %eax
                                        ## kill: def $eax killed $eax killed $rax
	cltd
	idivl	%edi
	decl	%eax
	movzwl	%ax, %eax
	movl	%eax, %ecx
	shrl	$15, %ecx
	addl	%eax, %ecx
	movswl	%cx, %edx
	andl	$-2, %edx
	orl	$1, %edx
	movl	$1, %ecx
	js	LBB0_23
## %bb.24:
	cmpl	$11, %edx
	jb	LBB0_26
## %bb.25:
	movslq	%esi, %rax
	imulq	$1759218605, %rax, %rdi         ## imm = 0x68DB8BAD
	movq	%rdi, %rax
	shrq	$63, %rax
	sarq	$44, %rdi
	addl	%eax, %edi
	movl	$11, %edx
	jmp	LBB0_26
LBB0_23:
	movl	$1, %edx
LBB0_26:
	movq	%rdi, -104(%rbp)                ## 8-byte Spill
	leaq	36(%r13), %rax
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movl	8(%r13), %ebx
	movl	$-1, -48(%rbp)                  ## 4-byte Folded Spill
	xorl	%eax, %eax
	movq	%rax, -96(%rbp)                 ## 8-byte Spill
	xorl	%r14d, %r14d
	movl	$0, -60(%rbp)                   ## 4-byte Folded Spill
	movl	%edx, -56(%rbp)                 ## 4-byte Spill
	movl	%r15d, -76(%rbp)                ## 4-byte Spill
	jmp	LBB0_27
LBB0_40:                                ##   in Loop: Header=BB0_27 Depth=1
	movl	%eax, %r14d
	movl	-52(%rbp), %ebx                 ## 4-byte Reload
LBB0_52:                                ##   in Loop: Header=BB0_27 Depth=1
	xorl	%eax, %eax
	movl	-48(%rbp), %ecx                 ## 4-byte Reload
	movl	-80(%rbp), %edx                 ## 4-byte Reload
	movl	%edx, -48(%rbp)                 ## 4-byte Spill
	movl	-56(%rbp), %edx                 ## 4-byte Reload
	cmpl	%edx, %r14d
	jge	LBB0_56
LBB0_27:                                ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_34 Depth 2
	movl	%ebx, -52(%rbp)                 ## 4-byte Spill
	movl	%r14d, -84(%rbp)                ## 4-byte Spill
	movl	%ecx, -80(%rbp)                 ## 4-byte Spill
	movl	(%r12), %esi
	movq	%r13, %rdi
	movl	$95, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.28:                              ##   in Loop: Header=BB0_27 Depth=1
	movq	_CFRINIT1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	xorl	%edx, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.29:                              ##   in Loop: Header=BB0_27 Depth=1
	movq	_CFRINIT0@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	xorl	%edx, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.30:                              ##   in Loop: Header=BB0_27 Depth=1
	movq	_SFRINIT1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	xorl	%edx, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.31:                              ##   in Loop: Header=BB0_27 Depth=1
	movq	_SFRINIT0@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	xorl	%edx, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.32:                              ##   in Loop: Header=BB0_27 Depth=1
	movl	(%r12), %esi
	movq	%r13, %rdi
	movl	$64, %edx
	callq	_STV090x_WRITE_DEMOD
	testq	%rax, %rax
	js	LBB0_55
## %bb.33:                              ##   in Loop: Header=BB0_27 Depth=1
	movl	$50, %edi
	callq	_msleep
	movl	$10, %r12d
	movq	-96(%rbp), %r14                 ## 8-byte Reload
	movl	-60(%rbp), %r15d                ## 4-byte Reload
LBB0_34:                                ##   Parent Loop BB0_27 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	_DSTATUS@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_STV090x_READ_DEMOD
	movl	%eax, -44(%rbp)
	movq	_TMGLOCK_QUALITY_FIELD@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movl	%eax, %edi
	callq	_STV090x_GETFIELD_Px
	xorl	%ecx, %ecx
	cmpl	$2, %eax
	setge	%cl
	addl	%ecx, %r15d
	movq	_AGC2I1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_STV090x_READ_DEMOD
	movl	%eax, %ebx
	shll	$8, %ebx
	movq	_AGC2I0@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_STV090x_READ_DEMOD
	orl	%ebx, %eax
	addl	%eax, %r14d
	decl	%r12d
	jne	LBB0_34
## %bb.35:                              ##   in Loop: Header=BB0_27 Depth=1
	movslq	%r14d, %rax
	imulq	$1717986919, %rax, %rbx         ## imm = 0x66666667
	movq	%rbx, %rax
	shrq	$63, %rax
	sarq	$34, %rbx
	addl	%eax, %ebx
	movq	16(%r13), %rax
	movl	4(%rax), %esi
	movq	%r13, %rdi
	callq	_stv090x_get_srate
	cmpl	$5, %r15d
	jl	LBB0_39
## %bb.36:                              ##   in Loop: Header=BB0_27 Depth=1
	cmpl	-76(%rbp), %ebx                 ## 4-byte Folded Reload
	jge	LBB0_39
## %bb.37:                              ##   in Loop: Header=BB0_27 Depth=1
	cmpl	$49999999, %eax                 ## imm = 0x2FAF07F
	jg	LBB0_39
## %bb.38:                              ##   in Loop: Header=BB0_27 Depth=1
	cmpl	$850000, %eax                   ## imm = 0xCF850
	jg	LBB0_53
LBB0_39:                                ##   in Loop: Header=BB0_27 Depth=1
	movq	%rbx, -96(%rbp)                 ## 8-byte Spill
	movl	-84(%rbp), %eax                 ## 4-byte Reload
	incl	%eax
	cmpl	-56(%rbp), %eax                 ## 4-byte Folded Reload
	movq	_DMDISTATE@GOTPCREL(%rip), %r12
	movl	%r15d, -60(%rbp)                ## 4-byte Spill
	jge	LBB0_40
## %bb.41:                              ##   in Loop: Header=BB0_27 Depth=1
	movl	%eax, %r14d
	imull	-104(%rbp), %eax                ## 4-byte Folded Reload
	movl	%eax, %ebx
	negl	%ebx
	cmpl	$0, -48(%rbp)                   ## 4-byte Folded Reload
	cmovgl	%eax, %ebx
	movq	%r13, %rdi
	movl	$1, %esi
	callq	_stv090x_i2c_gate_ctrl
	testq	%rax, %rax
	js	LBB0_55
## %bb.42:                              ##   in Loop: Header=BB0_27 Depth=1
	addl	-52(%rbp), %ebx                 ## 4-byte Folded Reload
	movq	24(%r13), %rax
	movq	(%rax), %rcx
	testq	%rcx, %rcx
	je	LBB0_45
## %bb.43:                              ##   in Loop: Header=BB0_27 Depth=1
	movq	-72(%rbp), %rdi                 ## 8-byte Reload
	movl	%ebx, %esi
	callq	*%rcx
	testq	%rax, %rax
	js	LBB0_54
## %bb.44:                              ##   in Loop: Header=BB0_27 Depth=1
	movq	24(%r13), %rax
LBB0_45:                                ##   in Loop: Header=BB0_27 Depth=1
	movq	8(%rax), %rax
	testq	%rax, %rax
	je	LBB0_47
## %bb.46:                              ##   in Loop: Header=BB0_27 Depth=1
	movl	32(%r13), %esi
	movq	-72(%rbp), %rdi                 ## 8-byte Reload
	callq	*%rax
	testq	%rax, %rax
	js	LBB0_54
LBB0_47:                                ##   in Loop: Header=BB0_27 Depth=1
	movq	%r13, %rdi
	xorl	%esi, %esi
	callq	_stv090x_i2c_gate_ctrl
	testq	%rax, %rax
	js	LBB0_55
## %bb.48:                              ##   in Loop: Header=BB0_27 Depth=1
	movl	$50, %edi
	callq	_msleep
	movq	%r13, %rdi
	movl	$1, %esi
	callq	_stv090x_i2c_gate_ctrl
	testq	%rax, %rax
	js	LBB0_55
## %bb.49:                              ##   in Loop: Header=BB0_27 Depth=1
	movq	24(%r13), %rax
	movq	16(%rax), %rax
	testq	%rax, %rax
	je	LBB0_51
## %bb.50:                              ##   in Loop: Header=BB0_27 Depth=1
	movq	-72(%rbp), %rdi                 ## 8-byte Reload
	leaq	-44(%rbp), %rsi
	callq	*%rax
	testq	%rax, %rax
	js	LBB0_54
LBB0_51:                                ##   in Loop: Header=BB0_27 Depth=1
	cmpl	$0, -44(%rbp)
	movq	_FE_DEBUG@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rdx
	leaq	L_.str.1(%rip), %rax
	cmoveq	%rax, %rdx
	movl	$1, %esi
	callq	_dprintk
	movq	%r13, %rdi
	xorl	%esi, %esi
	callq	_stv090x_i2c_gate_ctrl
	testq	%rax, %rax
	jns	LBB0_52
	jmp	LBB0_55
LBB0_54:
	movq	%r13, %rdi
	xorl	%esi, %esi
	callq	_stv090x_i2c_gate_ctrl
LBB0_55:
	movq	_FE_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.2(%rip), %rdx
	movl	$1, %esi
	callq	_dprintk
	movl	$-1, %eax
LBB0_56:
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_53:
	movq	16(%r13), %rax
	movl	4(%rax), %esi
	movq	%r13, %rdi
	callq	_stv090x_get_srate
	jmp	LBB0_56
	.cfi_endproc
                                        ## -- End function
	.comm	_DMDISTATE,4,2                  ## @DMDISTATE
	.comm	_I2C_DEMOD_MODE_FIELD,4,2       ## @I2C_DEMOD_MODE_FIELD
	.comm	_TMGCFG,4,2                     ## @TMGCFG
	.comm	_TMGCFG2,4,2                    ## @TMGCFG2
	.comm	_TMGTHRISE,4,2                  ## @TMGTHRISE
	.comm	_TMGTHFALL,4,2                  ## @TMGTHFALL
	.comm	_DMDCFGMD,4,2                   ## @DMDCFGMD
	.comm	_SCAN_ENABLE_FIELD,4,2          ## @SCAN_ENABLE_FIELD
	.comm	_CFR_AUTOSCAN_FIELD,4,2         ## @CFR_AUTOSCAN_FIELD
	.comm	_SFRUP1,4,2                     ## @SFRUP1
	.comm	_SFRUP0,4,2                     ## @SFRUP0
	.comm	_SFRLOW1,4,2                    ## @SFRLOW1
	.comm	_SFRLOW0,4,2                    ## @SFRLOW0
	.comm	_DMDTOM,4,2                     ## @DMDTOM
	.comm	_AGC2REF,4,2                    ## @AGC2REF
	.comm	_CARFREQ,4,2                    ## @CARFREQ
	.comm	_SFRSTEP,4,2                    ## @SFRSTEP
	.comm	_CFRINIT1,4,2                   ## @CFRINIT1
	.comm	_CFRINIT0,4,2                   ## @CFRINIT0
	.comm	_SFRINIT1,4,2                   ## @SFRINIT1
	.comm	_SFRINIT0,4,2                   ## @SFRINIT0
	.comm	_DSTATUS,4,2                    ## @DSTATUS
	.comm	_TMGLOCK_QUALITY_FIELD,4,2      ## @TMGLOCK_QUALITY_FIELD
	.comm	_AGC2I1,4,2                     ## @AGC2I1
	.comm	_AGC2I0,4,2                     ## @AGC2I0
	.comm	_FE_DEBUG,4,2                   ## @FE_DEBUG
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Tuner phase locked"

L_.str.1:                               ## @.str.1
	.asciz	"Tuner unlocked"

	.comm	_FE_ERROR,4,2                   ## @FE_ERROR
L_.str.2:                               ## @.str.2
	.asciz	"I/O error"

	.no_dead_strip	_stv090x_srate_srch_coarse
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function stv090x_srate_srch_coarse
_stv090x_srate_srch_coarse:             ; @stv090x_srate_srch_coarse
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	stp	x28, x27, [sp, #48]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #64]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #80]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #96]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #112]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #128]            ; 16-byte Folded Spill
	add	x29, sp, #128
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x0
	ldr	x8, [x0, #16]
	ldr	w8, [x8]
	mov	w9, #7936
	mov	w10, #11776
	cmp	w8, #47
	csel	w23, w10, w9, gt
Lloh0:
	adrp	x24, _DMDISTATE@GOTPAGE
Lloh1:
	ldr	x24, [x24, _DMDISTATE@GOTPAGEOFF]
	ldr	w1, [x24]
	bl	_STV090x_READ_DEMOD
	mov	x20, x0
	str	w0, [sp, #44]
Lloh2:
	adrp	x8, _I2C_DEMOD_MODE_FIELD@GOTPAGE
Lloh3:
	ldr	x8, [x8, _I2C_DEMOD_MODE_FIELD@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	mov	w2, #31
	bl	_STV090x_SETFIELD_Px
	ldr	w1, [x24]
	mov	x0, x19
	mov	x2, x20
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.1:
Lloh5:
	adrp	x8, _TMGCFG@GOTPAGE
Lloh6:
	ldr	x8, [x8, _TMGCFG@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #18
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.2:
Lloh8:
	adrp	x8, _TMGCFG2@GOTPAGE
Lloh9:
	ldr	x8, [x8, _TMGCFG2@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #192
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.3:
Lloh11:
	adrp	x8, _TMGTHRISE@GOTPAGE
Lloh12:
	ldr	x8, [x8, _TMGTHRISE@GOTPAGEOFF]
Lloh13:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #240
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.4:
Lloh14:
	adrp	x8, _TMGTHFALL@GOTPAGE
Lloh15:
	ldr	x8, [x8, _TMGTHFALL@GOTPAGEOFF]
Lloh16:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #224
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.5:
Lloh17:
	adrp	x21, _DMDCFGMD@GOTPAGE
Lloh18:
	ldr	x21, [x21, _DMDCFGMD@GOTPAGEOFF]
	ldr	w1, [x21]
	mov	x0, x19
	bl	_STV090x_READ_DEMOD
	mov	x20, x0
	str	w0, [sp, #44]
Lloh19:
	adrp	x8, _SCAN_ENABLE_FIELD@GOTPAGE
Lloh20:
	ldr	x8, [x8, _SCAN_ENABLE_FIELD@GOTPAGEOFF]
Lloh21:
	ldr	w1, [x8]
	mov	w2, #1
	bl	_STV090x_SETFIELD_Px
Lloh22:
	adrp	x8, _CFR_AUTOSCAN_FIELD@GOTPAGE
Lloh23:
	ldr	x8, [x8, _CFR_AUTOSCAN_FIELD@GOTPAGEOFF]
Lloh24:
	ldr	w1, [x8]
	mov	x0, x20
	mov	w2, #0
	bl	_STV090x_SETFIELD_Px
	ldr	w1, [x21]
	mov	x0, x19
	mov	x2, x20
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.6:
Lloh25:
	adrp	x8, _SFRUP1@GOTPAGE
Lloh26:
	ldr	x8, [x8, _SFRUP1@GOTPAGEOFF]
Lloh27:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #131
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.7:
Lloh28:
	adrp	x8, _SFRUP0@GOTPAGE
Lloh29:
	ldr	x8, [x8, _SFRUP0@GOTPAGEOFF]
Lloh30:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #192
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.8:
Lloh31:
	adrp	x8, _SFRLOW1@GOTPAGE
Lloh32:
	ldr	x8, [x8, _SFRLOW1@GOTPAGEOFF]
Lloh33:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #130
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.9:
Lloh34:
	adrp	x8, _SFRLOW0@GOTPAGE
Lloh35:
	ldr	x8, [x8, _SFRLOW0@GOTPAGEOFF]
Lloh36:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #160
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.10:
Lloh37:
	adrp	x8, _DMDTOM@GOTPAGE
Lloh38:
	ldr	x8, [x8, _DMDTOM@GOTPAGEOFF]
Lloh39:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #0
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.11:
Lloh40:
	adrp	x8, _AGC2REF@GOTPAGE
Lloh41:
	ldr	x8, [x8, _AGC2REF@GOTPAGEOFF]
Lloh42:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #80
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.12:
	ldr	x8, [x19, #16]
	ldr	w8, [x8]
	cmp	w8, #48
	b.lt	LBB0_15
; %bb.13:
Lloh43:
	adrp	x8, _CARFREQ@GOTPAGE
Lloh44:
	ldr	x8, [x8, _CARFREQ@GOTPAGEOFF]
Lloh45:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #153
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.14:
Lloh46:
	adrp	x8, _SFRSTEP@GOTPAGE
Lloh47:
	ldr	x8, [x8, _SFRSTEP@GOTPAGEOFF]
Lloh48:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #152
	b	LBB0_18
LBB0_15:
	cmp	w8, #32
	b.lt	LBB0_19
; %bb.16:
Lloh49:
	adrp	x8, _CARFREQ@GOTPAGE
Lloh50:
	ldr	x8, [x8, _CARFREQ@GOTPAGEOFF]
Lloh51:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #106
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.17:
Lloh52:
	adrp	x8, _SFRSTEP@GOTPAGE
Lloh53:
	ldr	x8, [x8, _SFRSTEP@GOTPAGEOFF]
Lloh54:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #149
LBB0_18:
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
LBB0_19:
	ldr	w8, [x19]
	mov	w9, #33921
	movk	w9, #30, lsl #16
	cmp	w8, w9
	b.ge	LBB0_21
; %bb.20:
	mov	w11, #1000
	b	LBB0_24
LBB0_21:
	mov	w9, #19265
	movk	w9, #76, lsl #16
	cmp	w8, w9
	b.hs	LBB0_23
; %bb.22:
	mov	w11, #2000
	b	LBB0_24
LBB0_23:
	mov	w9, #6913
	movk	w9, #183, lsl #16
	mov	w10, #5000
	mov	w11, #3000
	cmp	w8, w9
	csel	w11, w11, w10, lo
LBB0_24:
	add	x8, x19, #36
	str	x8, [sp, #8]                    ; 8-byte Folded Spill
	ldrsw	x8, [x19, #4]
	mov	w9, #19923
	movk	w9, #4194, lsl #16
	mul	x9, x8, x9
	lsr	x10, x9, #63
	asr	x9, x9, #38
	add	w9, w9, w10
	sdiv	w9, w9, w11
	sub	w9, w9, #1
	and	w10, w9, #0x8000
	add	w9, w9, w10, lsr #15
	sxth	w9, w9
	orr	w26, w9, #0x1
	tbnz	w26, #31, LBB0_27
; %bb.25:
	cmp	w26, #11
	b.lo	LBB0_28
; %bb.26:
	mov	w9, #35757
	movk	w9, #26843, lsl #16
	smull	x8, w8, w9
	lsr	x9, x8, #63
	asr	x8, x8, #44
	add	w11, w8, w9
	mov	w26, #11
	b	LBB0_28
LBB0_27:
	mov	w26, #1
LBB0_28:
	str	w11, [sp, #4]                   ; 4-byte Folded Spill
	mov	w20, #0
	mov	w22, #0
	mov	w28, #0
	mov	w8, #-1
	str	w8, [sp, #40]                   ; 4-byte Folded Spill
	mov	w8, #1
	ldr	w9, [x19, #8]
	str	w9, [sp, #20]                   ; 4-byte Folded Spill
Lloh55:
	adrp	x25, _AGC2I1@GOTPAGE
Lloh56:
	ldr	x25, [x25, _AGC2I1@GOTPAGEOFF]
Lloh57:
	adrp	x27, _AGC2I0@GOTPAGE
Lloh58:
	ldr	x27, [x27, _AGC2I0@GOTPAGEOFF]
	stp	w26, w23, [sp, #24]             ; 8-byte Folded Spill
	b	LBB0_31
LBB0_29:                                ;   in Loop: Header=BB0_31 Depth=1
	mov	x22, x9
	mov	x25, x27
	mov	x27, x23
LBB0_30:                                ;   in Loop: Header=BB0_31 Depth=1
	mov	w0, #0
	ldr	w8, [sp, #40]                   ; 4-byte Folded Reload
	ldr	w9, [sp, #32]                   ; 4-byte Folded Reload
	str	w9, [sp, #40]                   ; 4-byte Folded Spill
	cmp	w22, w26
	b.ge	LBB0_54
LBB0_31:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_38 Depth 2
	stp	w8, w22, [sp, #32]              ; 8-byte Folded Spill
	ldr	w1, [x24]
	mov	x0, x19
	mov	w2, #95
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.32:                               ;   in Loop: Header=BB0_31 Depth=1
Lloh59:
	adrp	x8, _CFRINIT1@GOTPAGE
Lloh60:
	ldr	x8, [x8, _CFRINIT1@GOTPAGEOFF]
Lloh61:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #0
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.33:                               ;   in Loop: Header=BB0_31 Depth=1
Lloh62:
	adrp	x8, _CFRINIT0@GOTPAGE
Lloh63:
	ldr	x8, [x8, _CFRINIT0@GOTPAGEOFF]
Lloh64:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #0
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.34:                               ;   in Loop: Header=BB0_31 Depth=1
Lloh65:
	adrp	x8, _SFRINIT1@GOTPAGE
Lloh66:
	ldr	x8, [x8, _SFRINIT1@GOTPAGEOFF]
Lloh67:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #0
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.35:                               ;   in Loop: Header=BB0_31 Depth=1
Lloh68:
	adrp	x8, _SFRINIT0@GOTPAGE
Lloh69:
	ldr	x8, [x8, _SFRINIT0@GOTPAGEOFF]
Lloh70:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #0
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.36:                               ;   in Loop: Header=BB0_31 Depth=1
	ldr	w1, [x24]
	mov	x0, x19
	mov	w2, #64
	bl	_STV090x_WRITE_DEMOD
	tbnz	x0, #63, LBB0_53
; %bb.37:                               ;   in Loop: Header=BB0_31 Depth=1
	mov	w0, #50
	bl	_msleep
	mov	w21, #10
	mov	x23, x27
	mov	x27, x25
Lloh71:
	adrp	x25, _TMGLOCK_QUALITY_FIELD@GOTPAGE
Lloh72:
	ldr	x25, [x25, _TMGLOCK_QUALITY_FIELD@GOTPAGEOFF]
Lloh73:
	adrp	x26, _DSTATUS@GOTPAGE
Lloh74:
	ldr	x26, [x26, _DSTATUS@GOTPAGEOFF]
LBB0_38:                                ;   Parent Loop BB0_31 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	w1, [x26]
	mov	x0, x19
	bl	_STV090x_READ_DEMOD
	str	w0, [sp, #44]
	ldr	w1, [x25]
	bl	_STV090x_GETFIELD_Px
	cmp	w0, #1
	cinc	w28, w28, gt
	ldr	w1, [x27]
	mov	x0, x19
	bl	_STV090x_READ_DEMOD
	mov	x22, x0
	ldr	w1, [x23]
	mov	x0, x19
	bl	_STV090x_READ_DEMOD
	orr	w8, w0, w22, lsl #8
	add	w20, w8, w20
	subs	w21, w21, #1
	b.ne	LBB0_38
; %bb.39:                               ;   in Loop: Header=BB0_31 Depth=1
	mov	w8, #26215
	movk	w8, #26214, lsl #16
	smull	x8, w20, w8
	lsr	x9, x8, #63
	asr	x8, x8, #34
	add	w20, w8, w9
	ldr	x8, [x19, #16]
	ldr	w1, [x8, #4]
	mov	x0, x19
	bl	_stv090x_get_srate
	cmp	w28, #5
	ldr	w8, [sp, #28]                   ; 4-byte Folded Reload
	ccmp	w20, w8, #0, ge
	mov	w8, #61567
	movk	w8, #762, lsl #16
	ccmp	w0, w8, #0, lt
	mov	w8, #63568
	movk	w8, #12, lsl #16
	ccmp	w0, w8, #4, le
	b.gt	LBB0_55
; %bb.40:                               ;   in Loop: Header=BB0_31 Depth=1
	ldr	w9, [sp, #36]                   ; 4-byte Folded Reload
	add	w9, w9, #1
	ldr	w8, [sp, #24]                   ; 4-byte Folded Reload
	mov	x26, x8
	cmp	w9, w8
	b.ge	LBB0_29
; %bb.41:                               ;   in Loop: Header=BB0_31 Depth=1
	ldr	w8, [sp, #4]                    ; 4-byte Folded Reload
	mov	x22, x9
	mul	w8, w9, w8
	ldr	w9, [sp, #40]                   ; 4-byte Folded Reload
	cmp	w9, #0
	cneg	w21, w8, le
	mov	x0, x19
	mov	w1, #1
	bl	_stv090x_i2c_gate_ctrl
	tbnz	x0, #63, LBB0_53
; %bb.42:                               ;   in Loop: Header=BB0_31 Depth=1
	mov	x25, x27
	mov	x27, x23
	ldr	w1, [sp, #20]                   ; 4-byte Folded Reload
	add	w1, w21, w1
	ldr	x8, [x19, #24]
	ldr	x9, [x8]
	str	w1, [sp, #20]                   ; 4-byte Folded Spill
	cbz	x9, LBB0_45
; %bb.43:                               ;   in Loop: Header=BB0_31 Depth=1
	ldr	x0, [sp, #8]                    ; 8-byte Folded Reload
	blr	x9
	tbnz	x0, #63, LBB0_52
; %bb.44:                               ;   in Loop: Header=BB0_31 Depth=1
	ldr	x8, [x19, #24]
LBB0_45:                                ;   in Loop: Header=BB0_31 Depth=1
	ldr	x8, [x8, #8]
	cbz	x8, LBB0_47
; %bb.46:                               ;   in Loop: Header=BB0_31 Depth=1
	ldr	w1, [x19, #32]
	ldr	x0, [sp, #8]                    ; 8-byte Folded Reload
	blr	x8
	tbnz	x0, #63, LBB0_52
LBB0_47:                                ;   in Loop: Header=BB0_31 Depth=1
	mov	x0, x19
	mov	w1, #0
	bl	_stv090x_i2c_gate_ctrl
	tbnz	x0, #63, LBB0_53
; %bb.48:                               ;   in Loop: Header=BB0_31 Depth=1
	mov	w0, #50
	bl	_msleep
	mov	x0, x19
	mov	w1, #1
	bl	_stv090x_i2c_gate_ctrl
	tbnz	x0, #63, LBB0_53
; %bb.49:                               ;   in Loop: Header=BB0_31 Depth=1
	ldr	x8, [x19, #24]
	ldr	x8, [x8, #16]
	cbz	x8, LBB0_51
; %bb.50:                               ;   in Loop: Header=BB0_31 Depth=1
	add	x1, sp, #44
	ldr	x0, [sp, #8]                    ; 8-byte Folded Reload
	blr	x8
	tbnz	x0, #63, LBB0_52
LBB0_51:                                ;   in Loop: Header=BB0_31 Depth=1
	ldr	w8, [sp, #44]
Lloh75:
	adrp	x9, _FE_DEBUG@GOTPAGE
Lloh76:
	ldr	x9, [x9, _FE_DEBUG@GOTPAGEOFF]
Lloh77:
	ldr	w0, [x9]
	cmp	w8, #0
Lloh78:
	adrp	x8, l_.str@PAGE
Lloh79:
	add	x8, x8, l_.str@PAGEOFF
Lloh80:
	adrp	x9, l_.str.1@PAGE
Lloh81:
	add	x9, x9, l_.str.1@PAGEOFF
	csel	x2, x9, x8, eq
	mov	w1, #1
	bl	_dprintk
	mov	x0, x19
	mov	w1, #0
	bl	_stv090x_i2c_gate_ctrl
	tbz	x0, #63, LBB0_30
	b	LBB0_53
LBB0_52:
	mov	x0, x19
	mov	w1, #0
	bl	_stv090x_i2c_gate_ctrl
LBB0_53:
Lloh82:
	adrp	x8, _FE_ERROR@GOTPAGE
Lloh83:
	ldr	x8, [x8, _FE_ERROR@GOTPAGEOFF]
Lloh84:
	ldr	w0, [x8]
Lloh85:
	adrp	x2, l_.str.2@PAGE
Lloh86:
	add	x2, x2, l_.str.2@PAGEOFF
	mov	w1, #1
	bl	_dprintk
	mov	w0, #-1
LBB0_54:
	ldp	x29, x30, [sp, #128]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #112]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #96]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #80]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #64]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #144
	ret
LBB0_55:
	ldr	x8, [x19, #16]
	ldr	w1, [x8, #4]
	mov	x0, x19
	bl	_stv090x_get_srate
	b	LBB0_54
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpLdrGotLdr	Lloh43, Lloh44, Lloh45
	.loh AdrpLdrGotLdr	Lloh46, Lloh47, Lloh48
	.loh AdrpLdrGotLdr	Lloh49, Lloh50, Lloh51
	.loh AdrpLdrGotLdr	Lloh52, Lloh53, Lloh54
	.loh AdrpLdrGot	Lloh57, Lloh58
	.loh AdrpLdrGot	Lloh55, Lloh56
	.loh AdrpLdrGotLdr	Lloh59, Lloh60, Lloh61
	.loh AdrpLdrGotLdr	Lloh62, Lloh63, Lloh64
	.loh AdrpLdrGotLdr	Lloh65, Lloh66, Lloh67
	.loh AdrpLdrGotLdr	Lloh68, Lloh69, Lloh70
	.loh AdrpLdrGot	Lloh73, Lloh74
	.loh AdrpLdrGot	Lloh71, Lloh72
	.loh AdrpAdd	Lloh80, Lloh81
	.loh AdrpAdd	Lloh78, Lloh79
	.loh AdrpLdrGotLdr	Lloh75, Lloh76, Lloh77
	.loh AdrpAdd	Lloh85, Lloh86
	.loh AdrpLdrGotLdr	Lloh82, Lloh83, Lloh84
	.cfi_endproc
                                        ; -- End function
	.comm	_DMDISTATE,4,2                  ; @DMDISTATE
	.comm	_I2C_DEMOD_MODE_FIELD,4,2       ; @I2C_DEMOD_MODE_FIELD
	.comm	_TMGCFG,4,2                     ; @TMGCFG
	.comm	_TMGCFG2,4,2                    ; @TMGCFG2
	.comm	_TMGTHRISE,4,2                  ; @TMGTHRISE
	.comm	_TMGTHFALL,4,2                  ; @TMGTHFALL
	.comm	_DMDCFGMD,4,2                   ; @DMDCFGMD
	.comm	_SCAN_ENABLE_FIELD,4,2          ; @SCAN_ENABLE_FIELD
	.comm	_CFR_AUTOSCAN_FIELD,4,2         ; @CFR_AUTOSCAN_FIELD
	.comm	_SFRUP1,4,2                     ; @SFRUP1
	.comm	_SFRUP0,4,2                     ; @SFRUP0
	.comm	_SFRLOW1,4,2                    ; @SFRLOW1
	.comm	_SFRLOW0,4,2                    ; @SFRLOW0
	.comm	_DMDTOM,4,2                     ; @DMDTOM
	.comm	_AGC2REF,4,2                    ; @AGC2REF
	.comm	_CARFREQ,4,2                    ; @CARFREQ
	.comm	_SFRSTEP,4,2                    ; @SFRSTEP
	.comm	_CFRINIT1,4,2                   ; @CFRINIT1
	.comm	_CFRINIT0,4,2                   ; @CFRINIT0
	.comm	_SFRINIT1,4,2                   ; @SFRINIT1
	.comm	_SFRINIT0,4,2                   ; @SFRINIT0
	.comm	_DSTATUS,4,2                    ; @DSTATUS
	.comm	_TMGLOCK_QUALITY_FIELD,4,2      ; @TMGLOCK_QUALITY_FIELD
	.comm	_AGC2I1,4,2                     ; @AGC2I1
	.comm	_AGC2I0,4,2                     ; @AGC2I0
	.comm	_FE_DEBUG,4,2                   ; @FE_DEBUG
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Tuner phase locked"

l_.str.1:                               ; @.str.1
	.asciz	"Tuner unlocked"

	.comm	_FE_ERROR,4,2                   ; @FE_ERROR
l_.str.2:                               ; @.str.2
	.asciz	"I/O error"

	.no_dead_strip	_stv090x_srate_srch_coarse
.subsections_via_symbols
