	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_stv0910_attach                 ## -- Begin function stv0910_attach
	.p2align	4, 0x90
_stv0910_attach:                        ## @stv0910_attach
	.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
	movl	%edx, %r12d
	movq	%rsi, %r15
	movq	%rdi, %r13
	movq	_GFP_KERNEL@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	movl	$112, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_7
## %bb.1:
	movq	%rax, %rbx
	movl	(%r15), %eax
	xorl	%ecx, %ecx
	testl	%eax, %eax
	sete	%cl
	shll	$6, %ecx
	orl	$32, %ecx
	movl	%ecx, (%rbx)
	xorl	%ecx, %ecx
	cmpl	$2, %eax
	sete	%cl
	addl	%ecx, %ecx
	movl	%ecx, 4(%rbx)
	movl	4(%r15), %eax
	shll	$4, %eax
	andl	$112, %eax
	orl	$10, %eax
	movl	%eax, 8(%rbx)
	movl	8(%r15), %eax
	testl	%eax, %eax
	movl	$40, %ecx
	cmovnel	%eax, %ecx
	movl	%ecx, 12(%rbx)
	movl	%r12d, 16(%rbx)
	xorl	%eax, %eax
	testl	%r12d, %r12d
	sete	%al
	shll	$9, %eax
	movl	%eax, 20(%rbx)
	movabsq	$68735476736, %rax              ## imm = 0x1000F42400
	movq	%rax, 24(%rbx)
	movq	_RCVMODE_NONE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 104(%rbx)
	movl	$-1, 32(%rbx)
	xorl	%eax, %eax
	cmpq	$0, 24(%r15)
	setne	%al
	movl	%eax, 36(%rbx)
	movl	16(%r15), %esi
	movq	%r13, %rdi
	callq	_match_base
	testq	%rax, %rax
	movq	%r13, -48(%rbp)                 ## 8-byte Spill
	je	LBB0_3
## %bb.2:
	incl	40(%rax)
	movq	%rax, 72(%rbx)
LBB0_9:
	movq	%rbx, %r13
	addq	$48, %r13
	movq	_stv0910_ops@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movl	%r14d, 48(%rbx)
	movq	%rbx, 56(%rbx)
	movl	%r12d, 16(%rbx)
	movl	16(%r15), %r15d
	movq	-48(%rbp), %r12                 ## 8-byte Reload
	movq	%r12, %rdi
	callq	_dev_name
	leaq	L_.str.1(%rip), %rsi
	movq	%r12, %rdi
	movl	%r14d, %edx
	movl	%r15d, %ecx
	movl	%eax, %r8d
	xorl	%eax, %eax
	callq	_dev_info
	movq	%rbx, %rdi
	callq	_stv0910_init_stats
	jmp	LBB0_10
LBB0_3:
	movl	(%r14), %esi
	movl	$112, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_6
## %bb.4:
	movq	%rax, %r13
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, 96(%rax)
	movl	16(%r15), %eax
	movl	%eax, 88(%r13)
	movl	$1, 40(%r13)
	movl	12(%r15), %eax
	testl	%eax, %eax
	movl	$30000000, %ecx                 ## imm = 0x1C9C380
	cmovnel	%eax, %ecx
	movl	%ecx, 44(%r13)
	leaq	84(%r13), %rdi
	callq	_mutex_init
	leaq	80(%r13), %rdi
	callq	_mutex_init
	movq	%r13, 72(%rbx)
	movq	%rbx, %rdi
	callq	_probe
	testq	%rax, %rax
	js	LBB0_5
## %bb.8:
	addq	$64, %r13
	movq	_stvlist@GOTPCREL(%rip), %rsi
	movq	%r13, %rdi
	callq	_list_add
	jmp	LBB0_9
LBB0_5:
	movl	16(%r15), %r15d
	movq	%r14, %rdi
	callq	_dev_name
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	movl	%r15d, %edx
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_dev_info
	movq	%r13, %rdi
	callq	_kfree
LBB0_6:
	movq	%rbx, %rdi
	callq	_kfree
LBB0_7:
	xorl	%r13d, %r13d
LBB0_10:
	movq	%r13, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_RCVMODE_NONE,4,2               ## @RCVMODE_NONE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"No demod found at adr %02X on %s\n"

	.comm	_stvlist,4,2                    ## @stvlist
	.comm	_stv0910_ops,4,2                ## @stv0910_ops
L_.str.1:                               ## @.str.1
	.asciz	"%s demod found at adr %02X on %s\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ; -- Begin function stv0910_attach
lCPI0_0:
	.long	0                               ; 0x0
	.long	2                               ; 0x2
lCPI0_1:
	.long	32                              ; 0x20
	.long	0                               ; 0x0
lCPI0_2:
	.long	96                              ; 0x60
	.long	2                               ; 0x2
lCPI0_3:
	.long	16000000                        ; 0xf42400
	.long	16                              ; 0x10
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_stv0910_attach
	.p2align	2
_stv0910_attach:                        ; @stv0910_attach
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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	x22, x2
	mov	x21, x1
	mov	x20, x0
Lloh0:
	adrp	x23, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x23, [x23, _GFP_KERNEL@GOTPAGEOFF]
	ldr	w1, [x23]
	mov	w0, #112
	bl	_kzalloc
	cbz	x0, LBB0_9
; %bb.1:
	mov	x19, x0
	mov	x8, x21
	ld1r.2s	{ v0 }, [x8], #4
Lloh2:
	adrp	x9, lCPI0_0@PAGE
Lloh3:
	ldr	d1, [x9, lCPI0_0@PAGEOFF]
	cmeq.2s	v0, v0, v1
Lloh4:
	adrp	x9, lCPI0_1@PAGE
Lloh5:
	ldr	d1, [x9, lCPI0_1@PAGEOFF]
Lloh6:
	adrp	x9, lCPI0_2@PAGE
Lloh7:
	ldr	d2, [x9, lCPI0_2@PAGEOFF]
	bsl.8b	v0, v2, v1
	str	d0, [x0]
	ldr	w8, [x8]
	mov	w9, #10
	bfi	w9, w8, #4, #3
	ldr	w8, [x21, #8]
	mov	w10, #40
	cmp	w8, #0
	csel	w8, w10, w8, eq
	stp	w9, w8, [x0, #8]
	cmp	w22, #0
	cset	w8, eq
	lsl	w8, w8, #9
	stp	w22, w8, [x0, #16]
Lloh8:
	adrp	x8, lCPI0_3@PAGE
Lloh9:
	ldr	d0, [x8, lCPI0_3@PAGEOFF]
	str	d0, [x0, #24]
Lloh10:
	adrp	x8, _RCVMODE_NONE@GOTPAGE
Lloh11:
	ldr	x8, [x8, _RCVMODE_NONE@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	str	w8, [x0, #104]
	mov	w8, #-1
	ldr	x9, [x21, #24]
	cmp	x9, #0
	cset	w9, ne
	stp	w8, w9, [x0, #32]
	ldr	w1, [x21, #16]
	mov	x0, x20
	bl	_match_base
	cbz	x0, LBB0_4
; %bb.2:
	ldr	w8, [x0, #40]
	add	w8, w8, #1
	str	w8, [x0, #40]
	str	x0, [x19, #72]
LBB0_3:
Lloh13:
	adrp	x8, _stv0910_ops@GOTPAGE
Lloh14:
	ldr	x8, [x8, _stv0910_ops@GOTPAGEOFF]
Lloh15:
	ldr	w24, [x8]
	mov	x23, x19
	str	w24, [x23, #48]!
	str	x19, [x19, #56]
	str	w22, [x19, #16]
	ldr	w21, [x21, #16]
	mov	x0, x20
	bl	_dev_name
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh16:
	adrp	x1, l_.str.1@PAGE
Lloh17:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x20
	mov	x2, x24
	mov	x3, x21
	bl	_dev_info
	mov	x0, x19
	bl	_stv0910_init_stats
	b	LBB0_10
LBB0_4:
	ldr	w1, [x23]
	mov	w0, #112
	bl	_kzalloc
	cbz	x0, LBB0_8
; %bb.5:
	mov	x23, x0
	str	x20, [x0, #96]
	ldp	w9, w8, [x21, #12]
	str	w8, [x0, #88]
	mov	w8, #1
	mov	w10, #50048
	movk	w10, #457, lsl #16
	cmp	w9, #0
	csel	w9, w10, w9, eq
	stp	w8, w9, [x0, #40]
	add	x0, x0, #84
	bl	_mutex_init
	add	x0, x23, #80
	bl	_mutex_init
	str	x23, [x19, #72]
	mov	x0, x19
	bl	_probe
	tbnz	x0, #63, LBB0_7
; %bb.6:
	add	x0, x23, #64
Lloh18:
	adrp	x1, _stvlist@GOTPAGE
Lloh19:
	ldr	x1, [x1, _stvlist@GOTPAGEOFF]
	bl	_list_add
	b	LBB0_3
LBB0_7:
	ldr	w21, [x21, #16]
	mov	x0, x20
	bl	_dev_name
	mov	x3, x0
Lloh20:
	adrp	x1, l_.str@PAGE
Lloh21:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	mov	x2, x21
	bl	_dev_info
	mov	x0, x23
	bl	_kfree
LBB0_8:
	mov	x0, x19
	bl	_kfree
LBB0_9:
	mov	x23, #0
LBB0_10:
	mov	x0, x23
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdrp	Lloh8, Lloh10
	.loh AdrpLdr	Lloh8, Lloh9
	.loh AdrpLdr	Lloh6, Lloh7
	.loh AdrpAdrp	Lloh4, Lloh6
	.loh AdrpLdr	Lloh4, Lloh5
	.loh AdrpAdrp	Lloh2, Lloh4
	.loh AdrpLdr	Lloh2, Lloh3
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpAdd	Lloh20, Lloh21
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_RCVMODE_NONE,4,2               ; @RCVMODE_NONE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"No demod found at adr %02X on %s\n"

	.comm	_stvlist,4,2                    ; @stvlist
	.comm	_stv0910_ops,4,2                ; @stv0910_ops
l_.str.1:                               ; @.str.1
	.asciz	"%s demod found at adr %02X on %s\n"

.subsections_via_symbols
