	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mxl5007t_set_params
_mxl5007t_set_params:                   ## @mxl5007t_set_params
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r13
	movl	16(%rdi), %eax
	movq	8(%rdi), %r14
	movl	20(%rdi), %edx
	leal	-128(%rax), %ecx
	cmpl	$2, %ecx
	jb	LBB0_6
## %bb.1:
	cmpl	$130, %eax
	je	LBB0_5
## %bb.2:
	cmpl	$131, %eax
	jne	LBB0_11
## %bb.3:
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	movq	_MxL_MODE_ATSC@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_6:
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	movq	_MxL_MODE_DVBT@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	movl	24(%r13), %eax
	cmpl	$6000000, %eax                  ## imm = 0x5B8D80
	je	LBB0_7
## %bb.8:
	cmpl	$8000000, %eax                  ## imm = 0x7A1200
	je	LBB0_13
## %bb.9:
	cmpl	$7000000, %eax                  ## imm = 0x6ACFC0
	jne	LBB0_12
## %bb.10:
	movq	_MxL_BW_7MHz@GOTPCREL(%rip), %rax
	jmp	LBB0_14
LBB0_5:
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	movq	_MxL_MODE_CABLE@GOTPCREL(%rip), %rax
LBB0_4:
	movl	(%rax), %r12d
	movq	_MxL_BW_6MHz@GOTPCREL(%rip), %rax
	jmp	LBB0_14
LBB0_11:
	leaq	L_.str(%rip), %rdi
	callq	_mxl_err
LBB0_12:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_21
LBB0_7:
	movq	_MxL_BW_6MHz@GOTPCREL(%rip), %rax
	jmp	LBB0_14
LBB0_13:
	movq	_MxL_BW_8MHz@GOTPCREL(%rip), %rax
LBB0_14:
	movl	(%rax), %eax
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movq	(%r13), %rax
	testq	%rax, %rax
	je	LBB0_16
## %bb.15:
	movq	%r13, %rdi
	movl	$1, %esi
	callq	*%rax
LBB0_16:
	leaq	4(%r14), %r15
	movq	%r15, %rdi
	callq	_mutex_lock
	movq	%r14, %rdi
	movl	%r12d, %esi
	callq	_mxl5007t_tuner_init
	movl	%eax, %ebx
	movl	%eax, %edi
	callq	_mxl_fail
	testq	%rax, %rax
	jne	LBB0_19
## %bb.17:
	movq	%r14, %rdi
	movl	-44(%rbp), %r12d                ## 4-byte Reload
	movl	%r12d, %esi
	movl	-48(%rbp), %edx                 ## 4-byte Reload
	callq	_mxl5007t_tuner_rf_tune
	movl	%eax, %ebx
	movl	%eax, %edi
	callq	_mxl_fail
	testq	%rax, %rax
	jne	LBB0_19
## %bb.18:
	movl	%r12d, (%r14)
	movl	24(%r13), %eax
	movl	%eax, 8(%r14)
LBB0_19:
	movq	%r15, %rdi
	callq	_mutex_unlock
	movq	(%r13), %rcx
	testq	%rcx, %rcx
	je	LBB0_21
## %bb.20:
	movq	%r13, %rdi
	xorl	%esi, %esi
	callq	*%rcx
LBB0_21:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MxL_MODE_ATSC,4,2              ## @MxL_MODE_ATSC
	.comm	_MxL_BW_6MHz,4,2                ## @MxL_BW_6MHz
	.comm	_MxL_MODE_CABLE,4,2             ## @MxL_MODE_CABLE
	.comm	_MxL_MODE_DVBT,4,2              ## @MxL_MODE_DVBT
	.comm	_MxL_BW_7MHz,4,2                ## @MxL_BW_7MHz
	.comm	_MxL_BW_8MHz,4,2                ## @MxL_BW_8MHz
	.comm	_EINVAL,4,2                     ## @EINVAL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"modulation type not supported!"

	.no_dead_strip	_mxl5007t_set_params
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mxl5007t_set_params
_mxl5007t_set_params:                   ; @mxl5007t_set_params
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x19, x0
	ldr	x20, [x0, #8]
	ldp	w8, w21, [x0, #16]
	sub	w9, w8, #128
	cmp	w9, #2
	b.lo	LBB0_4
; %bb.1:
	cmp	w8, #130
	b.eq	LBB0_8
; %bb.2:
	cmp	w8, #131
	b.ne	LBB0_18
; %bb.3:
Lloh0:
	adrp	x8, _MxL_MODE_ATSC@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MxL_MODE_ATSC@GOTPAGEOFF]
	b	LBB0_9
LBB0_4:
Lloh2:
	adrp	x8, _MxL_MODE_DVBT@GOTPAGE
Lloh3:
	ldr	x8, [x8, _MxL_MODE_DVBT@GOTPAGEOFF]
Lloh4:
	ldr	w22, [x8]
	ldr	w8, [x19, #24]
	sub	w9, w8, #1464, lsl #12          ; =5996544
	cmp	w9, #3456
	b.eq	LBB0_10
; %bb.5:
	mov	w9, #4608
	movk	w9, #122, lsl #16
	cmp	w8, w9
	b.eq	LBB0_21
; %bb.6:
	mov	w9, #53184
	movk	w9, #106, lsl #16
	cmp	w8, w9
	b.ne	LBB0_19
; %bb.7:
Lloh5:
	adrp	x8, _MxL_BW_7MHz@GOTPAGE
Lloh6:
	ldr	x8, [x8, _MxL_BW_7MHz@GOTPAGEOFF]
	b	LBB0_11
LBB0_8:
Lloh7:
	adrp	x8, _MxL_MODE_CABLE@GOTPAGE
Lloh8:
	ldr	x8, [x8, _MxL_MODE_CABLE@GOTPAGEOFF]
LBB0_9:
	ldr	w22, [x8]
LBB0_10:
Lloh9:
	adrp	x8, _MxL_BW_6MHz@GOTPAGE
Lloh10:
	ldr	x8, [x8, _MxL_BW_6MHz@GOTPAGEOFF]
LBB0_11:
	ldr	w24, [x8]
	ldr	x8, [x19]
	cbz	x8, LBB0_13
; %bb.12:
	mov	x0, x19
	mov	w1, #1
	blr	x8
LBB0_13:
	add	x23, x20, #4
	mov	x0, x23
	bl	_mutex_lock
	mov	x0, x20
	mov	x1, x22
	bl	_mxl5007t_tuner_init
	mov	x22, x0
	bl	_mxl_fail
	cbnz	x0, LBB0_16
; %bb.14:
	mov	x0, x20
	mov	x1, x21
	mov	x2, x24
	bl	_mxl5007t_tuner_rf_tune
	mov	x22, x0
	bl	_mxl_fail
	cbnz	x0, LBB0_16
; %bb.15:
	str	w21, [x20]
	ldr	w8, [x19, #24]
	str	w8, [x20, #8]
LBB0_16:
	mov	x0, x23
	bl	_mutex_unlock
	ldr	x8, [x19]
	cbz	x8, LBB0_20
; %bb.17:
	mov	x0, x19
	mov	w1, #0
	blr	x8
	b	LBB0_20
LBB0_18:
Lloh11:
	adrp	x0, l_.str@PAGE
Lloh12:
	add	x0, x0, l_.str@PAGEOFF
	bl	_mxl_err
LBB0_19:
Lloh13:
	adrp	x8, _EINVAL@GOTPAGE
Lloh14:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	neg	w22, w8
LBB0_20:
	mov	x0, x22
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_21:
Lloh16:
	adrp	x8, _MxL_BW_8MHz@GOTPAGE
Lloh17:
	ldr	x8, [x8, _MxL_BW_8MHz@GOTPAGEOFF]
	b	LBB0_11
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_MxL_MODE_ATSC,4,2              ; @MxL_MODE_ATSC
	.comm	_MxL_BW_6MHz,4,2                ; @MxL_BW_6MHz
	.comm	_MxL_MODE_CABLE,4,2             ; @MxL_MODE_CABLE
	.comm	_MxL_MODE_DVBT,4,2              ; @MxL_MODE_DVBT
	.comm	_MxL_BW_7MHz,4,2                ; @MxL_BW_7MHz
	.comm	_MxL_BW_8MHz,4,2                ; @MxL_BW_8MHz
	.comm	_EINVAL,4,2                     ; @EINVAL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"modulation type not supported!"

	.no_dead_strip	_mxl5007t_set_params
.subsections_via_symbols
