	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function tda10071_get_frontend
_tda10071_get_frontend:                 ## @tda10071_get_frontend
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	(%rdi), %r12
	movq	16(%r12), %r14
	xorl	%ebx, %ebx
	cmpl	$0, 8(%r12)
	je	LBB0_16
## %bb.1:
	movq	_FE_HAS_LOCK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r12)
	je	LBB0_16
## %bb.2:
	movq	%rsi, %r15
	movl	4(%r12), %edi
	leaq	-80(%rbp), %rdx
	movl	$48, %esi
	movl	$5, %ecx
	callq	_regmap_bulk_read
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_16
## %bb.3:
	movq	%r14, -88(%rbp)                 ## 8-byte Spill
	movl	-80(%rbp), %ebx
	movq	_TDA10071_MODCOD@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	callq	_ARRAY_SIZE
	testl	%eax, %eax
	jle	LBB0_8
## %bb.4:
	andl	$63, %ebx
	movl	$12, %r14d
	xorl	%r13d, %r13d
	jmp	LBB0_5
	.p2align	4, 0x90
LBB0_7:                                 ##   in Loop: Header=BB0_5 Depth=1
	incq	%r13
	callq	_ARRAY_SIZE
	cltq
	addq	$16, %r14
	cmpq	%rax, %r13
	jge	LBB0_8
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	_TDA10071_MODCOD@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	cmpl	-12(%rdi,%r14), %ebx
	jne	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	movl	(%rdi,%r14), %eax
	movl	%eax, 24(%r15)
	movl	-4(%rdi,%r14), %eax
	movl	%eax, 20(%r15)
	movl	-8(%rdi,%r14), %eax
	movl	%eax, 16(%r15)
	jmp	LBB0_7
LBB0_8:
	movl	-76(%rbp), %eax
	testb	$1, %al
	jne	LBB0_9
## %bb.10:
	movq	_INVERSION_ON@GOTPCREL(%rip), %rcx
	jmp	LBB0_11
LBB0_9:
	movq	_INVERSION_OFF@GOTPCREL(%rip), %rcx
LBB0_11:
	movl	(%rcx), %ecx
	movl	%ecx, 12(%r15)
	testb	$-128, %al
	movq	-88(%rbp), %r14                 ## 8-byte Reload
	jne	LBB0_12
## %bb.13:
	movq	_PILOT_OFF@GOTPCREL(%rip), %rax
	jmp	LBB0_14
LBB0_12:
	movq	_PILOT_ON@GOTPCREL(%rip), %rax
LBB0_14:
	movl	(%rax), %eax
	movl	%eax, 8(%r15)
	movl	-72(%rbp), %eax
	movl	-68(%rbp), %ecx
	shll	$16, %eax
	shll	$8, %ecx
	orl	%eax, %ecx
	orl	-64(%rbp), %ecx
	movl	%ecx, (%r15)
	movl	4(%r12), %edi
	leaq	-80(%rbp), %rdx
	movl	$82, %esi
	movl	$3, %ecx
	callq	_regmap_bulk_read
	movl	%eax, %ebx
	testl	%eax, %eax
	je	LBB0_15
LBB0_16:
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	movl	%ebx, %edx
	callq	_dev_dbg
LBB0_17:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_19
## %bb.18:
	movl	%ebx, %eax
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_15:
	movl	-80(%rbp), %eax
	movl	-76(%rbp), %ecx
	shll	$16, %eax
	shll	$8, %ecx
	orl	%eax, %ecx
	orl	-72(%rbp), %ecx
	imull	$1000, %ecx, %eax               ## imm = 0x3E8
	movl	%eax, 4(%r15)
	xorl	%ebx, %ebx
	jmp	LBB0_17
LBB0_19:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_FE_HAS_LOCK,4,2                ## @FE_HAS_LOCK
	.comm	_TDA10071_MODCOD,8,3            ## @TDA10071_MODCOD
	.comm	_INVERSION_ON,4,2               ## @INVERSION_ON
	.comm	_INVERSION_OFF,4,2              ## @INVERSION_OFF
	.comm	_PILOT_OFF,4,2                  ## @PILOT_OFF
	.comm	_PILOT_ON,4,2                   ## @PILOT_ON
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"failed=%d\n"

	.no_dead_strip	_tda10071_get_frontend
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function tda10071_get_frontend
_tda10071_get_frontend:                 ; @tda10071_get_frontend
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #24]
	ldr	x22, [x0]
	ldr	x19, [x22, #16]
	ldr	w8, [x22, #8]
	cbz	w8, LBB0_8
; %bb.1:
	ldr	w8, [x22]
Lloh3:
	adrp	x9, _FE_HAS_LOCK@GOTPAGE
Lloh4:
	ldr	x9, [x9, _FE_HAS_LOCK@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_8
; %bb.2:
	mov	x20, x1
	ldr	w0, [x22, #4]
	add	x2, sp, #4
	mov	w1, #48
	mov	w3, #5
	bl	_regmap_bulk_read
	mov	x21, x0
	cbnz	w0, LBB0_9
; %bb.3:
	ldr	w25, [sp, #4]
Lloh6:
	adrp	x21, _TDA10071_MODCOD@GOTPAGE
Lloh7:
	ldr	x21, [x21, _TDA10071_MODCOD@GOTPAGEOFF]
	ldr	x0, [x21]
	bl	_ARRAY_SIZE
	cmp	w0, #1
	b.lt	LBB0_12
; %bb.4:
	mov	x23, #0
	mov	x24, #0
	and	w25, w25, #0x3f
	b	LBB0_6
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	add	x24, x24, #1
	bl	_ARRAY_SIZE
	add	x23, x23, #16
	cmp	x24, w0, sxtw
	b.ge	LBB0_12
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x0, [x21]
	ldr	w8, [x0, x23]
	cmp	w25, w8
	b.ne	LBB0_5
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	add	x8, x0, x23
	ldr	w9, [x8, #12]
	str	w9, [x20, #24]
	ldur	d0, [x8, #4]
	str	d0, [x20, #16]
	b	LBB0_5
LBB0_8:
	mov	w21, #0
LBB0_9:
Lloh8:
	adrp	x1, l_.str@PAGE
Lloh9:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	mov	x2, x21
	bl	_dev_dbg
LBB0_10:
	ldr	x8, [sp, #24]
Lloh10:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh11:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh12:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_14
; %bb.11:
	mov	x0, x21
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_12:
Lloh13:
	adrp	x8, _INVERSION_ON@GOTPAGE
Lloh14:
	ldr	x8, [x8, _INVERSION_ON@GOTPAGEOFF]
Lloh15:
	adrp	x9, _INVERSION_OFF@GOTPAGE
Lloh16:
	ldr	x9, [x9, _INVERSION_OFF@GOTPAGEOFF]
	ldp	w10, w11, [sp, #8]
	tst	w10, #0x1
	csel	x8, x8, x9, eq
	ldr	w8, [x8]
	str	w8, [x20, #12]
Lloh17:
	adrp	x8, _PILOT_OFF@GOTPAGE
Lloh18:
	ldr	x8, [x8, _PILOT_OFF@GOTPAGEOFF]
	tst	w10, #0x80
Lloh19:
	adrp	x9, _PILOT_ON@GOTPAGE
Lloh20:
	ldr	x9, [x9, _PILOT_ON@GOTPAGEOFF]
	csel	x8, x8, x9, eq
	ldr	w8, [x8]
	str	w8, [x20, #8]
	ldp	w8, w9, [sp, #16]
	lsl	w8, w8, #8
	orr	w8, w8, w11, lsl #16
	orr	w8, w8, w9
	str	w8, [x20]
	ldr	w0, [x22, #4]
	add	x2, sp, #4
	mov	w1, #82
	mov	w3, #3
	bl	_regmap_bulk_read
	mov	x21, x0
	cbnz	w0, LBB0_9
; %bb.13:
	ldp	w8, w9, [sp, #4]
	lsl	w9, w9, #8
	orr	w8, w9, w8, lsl #16
	ldr	w9, [sp, #12]
	orr	w8, w8, w9
	mov	w9, #1000
	mul	w8, w8, w9
	str	w8, [x20, #4]
	b	LBB0_10
LBB0_14:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_FE_HAS_LOCK,4,2                ; @FE_HAS_LOCK
	.comm	_TDA10071_MODCOD,8,3            ; @TDA10071_MODCOD
	.comm	_INVERSION_ON,4,2               ; @INVERSION_ON
	.comm	_INVERSION_OFF,4,2              ; @INVERSION_OFF
	.comm	_PILOT_OFF,4,2                  ; @PILOT_OFF
	.comm	_PILOT_ON,4,2                   ; @PILOT_ON
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"failed=%d\n"

	.no_dead_strip	_tda10071_get_frontend
.subsections_via_symbols
