	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function tuner_attach_stv6111
_tuner_attach_stv6111:                  ## @tuner_attach_stv6111
	.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
	movq	8(%rdi), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	callq	_i2c_adapter_from_chan
	movq	%rax, %r15
	movl	(%r13), %eax
	movl	4(%r13), %esi
	andl	$1, %eax
	leal	(%rax,%rax,2), %ebx
	orl	$100, %ebx
	movq	_stv6111_attach@GOTPCREL(%rip), %r14
	movl	(%r14), %edi
	movq	%r15, %rdx
	movl	%ebx, %ecx
	callq	_dvb_attach
	xorl	%r12d, %r12d
	testq	%rax, %rax
	jne	LBB0_3
## %bb.1:
	movl	(%r14), %edi
	movl	4(%r13), %esi
	andl	$99, %ebx
	movq	%r15, %rdx
	movl	%ebx, %ecx
	callq	_dvb_attach
	testq	%rax, %rax
	jne	LBB0_3
## %bb.2:
	leaq	L_.str(%rip), %rsi
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_dev_err
	movq	_ENODEV@GOTPCREL(%rip), %rax
	xorl	%r12d, %r12d
	subl	(%rax), %r12d
LBB0_3:
	movl	%r12d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_stv6111_attach,4,2             ## @stv6111_attach
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"stv6111_attach() failed!\n"

	.comm	_ENODEV,4,2                     ## @ENODEV
	.no_dead_strip	_tuner_attach_stv6111
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function tuner_attach_stv6111
_tuner_attach_stv6111:                  ; @tuner_attach_stv6111
	.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	x20, x0
	ldr	x8, [x0, #8]
	ldr	x19, [x8]
	bl	_i2c_adapter_from_chan
	mov	x21, x0
	ldp	w8, w1, [x20]
	tst	w8, #0x1
	mov	w8, #103
	mov	w9, #100
	csel	w22, w9, w8, eq
Lloh0:
	adrp	x23, _stv6111_attach@GOTPAGE
Lloh1:
	ldr	x23, [x23, _stv6111_attach@GOTPAGEOFF]
	ldr	w0, [x23]
	mov	x2, x21
	mov	x3, x22
	bl	_dvb_attach
	cbnz	x0, LBB0_2
; %bb.1:
	ldr	w0, [x23]
	ldr	w1, [x20, #4]
	and	w3, w22, #0xffffffe3
	mov	x2, x21
	bl	_dvb_attach
	cbz	x0, LBB0_4
LBB0_2:
	mov	w0, #0
LBB0_3:
	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_4:
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_dev_err
Lloh4:
	adrp	x8, _ENODEV@GOTPAGE
Lloh5:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh2, Lloh3
	.cfi_endproc
                                        ; -- End function
	.comm	_stv6111_attach,4,2             ; @stv6111_attach
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"stv6111_attach() failed!\n"

	.comm	_ENODEV,4,2                     ; @ENODEV
	.no_dead_strip	_tuner_attach_stv6111
.subsections_via_symbols
