	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function stb0899_get_dev_id
_stb0899_get_dev_id:                    ## @stb0899_get_dev_id
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r12
	movb	$0, -52(%rbp)
	movl	$0, -56(%rbp)
	movb	$0, -44(%rbp)
	movl	$0, -48(%rbp)
	movq	_STB0899_DEV_ID@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_stb0899_read_reg
	movl	%eax, %ebx
	movl	(%r12), %edi
	movq	_FE_DEBUG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rcx
	movl	$1, %edx
	movl	%ebx, %r8d
	xorl	%eax, %eax
	callq	_dprintk
	movq	_CHIP_ID@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	%ebx, %esi
	callq	_STB0899_GETFIELD
	movq	%rax, %r15
	movq	_CHIP_REL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	%ebx, %esi
	callq	_STB0899_GETFIELD
	movl	(%r12), %edi
	movq	_FE_ERROR@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	leaq	L_.str.1(%rip), %rcx
	movl	$1, %edx
	movq	%r15, %r8
	movq	%rax, %r9
	xorl	%eax, %eax
	callq	_dprintk
	movq	_STB0899_S2DEMOD@GOTPCREL(%rip), %r14
	movl	(%r14), %edi
	movq	_DMD_CORE_ID@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_STB0899_READ_S2REG
	leaq	-56(%rbp), %rbx
	movq	%rax, %rdi
	movq	%rbx, %rsi
	callq	_CONVERT32
	movl	(%r14), %edi
	movq	_DMD_VERSION_ID@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_STB0899_READ_S2REG
	movl	(%r12), %edi
	movl	(%r13), %esi
	leaq	L_.str.2(%rip), %rcx
	movl	$1, %edx
	movq	%rbx, %r8
	movq	%rax, %r9
	xorl	%eax, %eax
	callq	_dprintk
	movq	_STB0899_S2FEC@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edi
	movq	_FEC_CORE_ID_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_STB0899_READ_S2REG
	leaq	-48(%rbp), %rsi
	movq	%rax, %rdi
	callq	_CONVERT32
	movl	(%rbx), %edi
	movq	_FEC_VER_ID_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_STB0899_READ_S2REG
	movl	(%r12), %edi
	movl	(%r13), %esi
	testq	%r15, %r15
	jle	LBB0_1
## %bb.2:
	leaq	L_.str.4(%rip), %rcx
	leaq	-48(%rbp), %r8
	movl	$1, %edx
	movq	%rax, %r9
	xorl	%eax, %eax
	callq	_dprintk
	xorl	%eax, %eax
	jmp	LBB0_3
LBB0_1:
	leaq	L_.str.3(%rip), %rcx
	movl	$1, %edx
	xorl	%eax, %eax
	callq	_dprintk
	movq	_ENODEV@GOTPCREL(%rip), %rax
	xorl	%ecx, %ecx
	subl	(%rax), %ecx
	movl	%ecx, %eax
LBB0_3:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_STB0899_DEV_ID,4,2             ## @STB0899_DEV_ID
	.comm	_FE_DEBUG,4,2                   ## @FE_DEBUG
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"ID reg=[0x%02x]"

	.comm	_CHIP_ID,4,2                    ## @CHIP_ID
	.comm	_CHIP_REL,4,2                   ## @CHIP_REL
	.comm	_FE_ERROR,4,2                   ## @FE_ERROR
L_.str.1:                               ## @.str.1
	.asciz	"Device ID=[%d], Release=[%d]"

	.comm	_STB0899_S2DEMOD,4,2            ## @STB0899_S2DEMOD
	.comm	_DMD_CORE_ID,4,2                ## @DMD_CORE_ID
	.comm	_DMD_VERSION_ID,4,2             ## @DMD_VERSION_ID
L_.str.2:                               ## @.str.2
	.asciz	"Demodulator Core ID=[%s], Version=[%d]"

	.comm	_STB0899_S2FEC,4,2              ## @STB0899_S2FEC
	.comm	_FEC_CORE_ID_REG,4,2            ## @FEC_CORE_ID_REG
	.comm	_FEC_VER_ID_REG,4,2             ## @FEC_VER_ID_REG
L_.str.3:                               ## @.str.3
	.asciz	"couldn't find a STB 0899"

	.comm	_ENODEV,4,2                     ## @ENODEV
L_.str.4:                               ## @.str.4
	.asciz	"FEC Core ID=[%s], Version=[%d]"

	.no_dead_strip	_stb0899_get_dev_id
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function stb0899_get_dev_id
_stb0899_get_dev_id:                    ; @stb0899_get_dev_id
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	strb	wzr, [sp, #28]
	str	wzr, [sp, #24]
	strb	wzr, [sp, #20]
	str	wzr, [sp, #16]
Lloh0:
	adrp	x8, _STB0899_DEV_ID@GOTPAGE
Lloh1:
	ldr	x8, [x8, _STB0899_DEV_ID@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_stb0899_read_reg
	mov	x21, x0
	ldr	w0, [x19]
Lloh3:
	adrp	x8, _FE_DEBUG@GOTPAGE
Lloh4:
	ldr	x8, [x8, _FE_DEBUG@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	str	x21, [sp]
Lloh6:
	adrp	x3, l_.str@PAGE
Lloh7:
	add	x3, x3, l_.str@PAGEOFF
	mov	w2, #1
	bl	_dprintk
Lloh8:
	adrp	x8, _CHIP_ID@GOTPAGE
Lloh9:
	ldr	x8, [x8, _CHIP_ID@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
	mov	x1, x21
	bl	_STB0899_GETFIELD
	mov	x20, x0
Lloh11:
	adrp	x8, _CHIP_REL@GOTPAGE
Lloh12:
	ldr	x8, [x8, _CHIP_REL@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
	mov	x1, x21
	bl	_STB0899_GETFIELD
	ldr	w8, [x19]
Lloh14:
	adrp	x21, _FE_ERROR@GOTPAGE
Lloh15:
	ldr	x21, [x21, _FE_ERROR@GOTPAGEOFF]
	ldr	w1, [x21]
	stp	x20, x0, [sp]
Lloh16:
	adrp	x3, l_.str.1@PAGE
Lloh17:
	add	x3, x3, l_.str.1@PAGEOFF
	mov	x0, x8
	mov	w2, #1
	bl	_dprintk
Lloh18:
	adrp	x22, _STB0899_S2DEMOD@GOTPAGE
Lloh19:
	ldr	x22, [x22, _STB0899_S2DEMOD@GOTPAGEOFF]
	ldr	w0, [x22]
Lloh20:
	adrp	x8, _DMD_CORE_ID@GOTPAGE
Lloh21:
	ldr	x8, [x8, _DMD_CORE_ID@GOTPAGEOFF]
Lloh22:
	ldr	w1, [x8]
	bl	_STB0899_READ_S2REG
	add	x23, sp, #24
	add	x1, sp, #24
	bl	_CONVERT32
	ldr	w0, [x22]
Lloh23:
	adrp	x8, _DMD_VERSION_ID@GOTPAGE
Lloh24:
	ldr	x8, [x8, _DMD_VERSION_ID@GOTPAGEOFF]
Lloh25:
	ldr	w1, [x8]
	bl	_STB0899_READ_S2REG
	ldr	w8, [x19]
	ldr	w1, [x21]
	stp	x23, x0, [sp]
Lloh26:
	adrp	x3, l_.str.2@PAGE
Lloh27:
	add	x3, x3, l_.str.2@PAGEOFF
	mov	x0, x8
	mov	w2, #1
	bl	_dprintk
Lloh28:
	adrp	x23, _STB0899_S2FEC@GOTPAGE
Lloh29:
	ldr	x23, [x23, _STB0899_S2FEC@GOTPAGEOFF]
	ldr	w0, [x23]
Lloh30:
	adrp	x8, _FEC_CORE_ID_REG@GOTPAGE
Lloh31:
	ldr	x8, [x8, _FEC_CORE_ID_REG@GOTPAGEOFF]
Lloh32:
	ldr	w1, [x8]
	bl	_STB0899_READ_S2REG
	add	x22, sp, #16
	add	x1, sp, #16
	bl	_CONVERT32
	ldr	w0, [x23]
Lloh33:
	adrp	x8, _FEC_VER_ID_REG@GOTPAGE
Lloh34:
	ldr	x8, [x8, _FEC_VER_ID_REG@GOTPAGEOFF]
Lloh35:
	ldr	w1, [x8]
	bl	_STB0899_READ_S2REG
	mov	x8, x0
	ldr	w0, [x19]
	ldr	w1, [x21]
	cmp	x20, #0
	b.le	LBB0_2
; %bb.1:
	stp	x22, x8, [sp]
Lloh36:
	adrp	x3, l_.str.4@PAGE
Lloh37:
	add	x3, x3, l_.str.4@PAGEOFF
	mov	w2, #1
	bl	_dprintk
	mov	w0, #0
	b	LBB0_3
LBB0_2:
Lloh38:
	adrp	x3, l_.str.3@PAGE
Lloh39:
	add	x3, x3, l_.str.3@PAGEOFF
	mov	w2, #1
	bl	_dprintk
Lloh40:
	adrp	x8, _ENODEV@GOTPAGE
Lloh41:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
Lloh42:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_3:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGot	Lloh28, Lloh29
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpAdd	Lloh38, Lloh39
	.cfi_endproc
                                        ; -- End function
	.comm	_STB0899_DEV_ID,4,2             ; @STB0899_DEV_ID
	.comm	_FE_DEBUG,4,2                   ; @FE_DEBUG
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"ID reg=[0x%02x]"

	.comm	_CHIP_ID,4,2                    ; @CHIP_ID
	.comm	_CHIP_REL,4,2                   ; @CHIP_REL
	.comm	_FE_ERROR,4,2                   ; @FE_ERROR
l_.str.1:                               ; @.str.1
	.asciz	"Device ID=[%d], Release=[%d]"

	.comm	_STB0899_S2DEMOD,4,2            ; @STB0899_S2DEMOD
	.comm	_DMD_CORE_ID,4,2                ; @DMD_CORE_ID
	.comm	_DMD_VERSION_ID,4,2             ; @DMD_VERSION_ID
l_.str.2:                               ; @.str.2
	.asciz	"Demodulator Core ID=[%s], Version=[%d]"

	.comm	_STB0899_S2FEC,4,2              ; @STB0899_S2FEC
	.comm	_FEC_CORE_ID_REG,4,2            ; @FEC_CORE_ID_REG
	.comm	_FEC_VER_ID_REG,4,2             ; @FEC_VER_ID_REG
l_.str.3:                               ; @.str.3
	.asciz	"couldn't find a STB 0899"

	.comm	_ENODEV,4,2                     ; @ENODEV
l_.str.4:                               ; @.str.4
	.asciz	"FEC Core ID=[%s], Version=[%d]"

	.no_dead_strip	_stb0899_get_dev_id
.subsections_via_symbols
