	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ca0106_spdif_enable
_ca0106_spdif_enable:                   ## @ca0106_spdif_enable
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	movq	8(%rdi), %r14
	movq	_SPDIF_SELECT1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%edx, %edx
	movl	$15, %ecx
	callq	_snd_ca0106_ptr_write
	movq	_SPDIF_SELECT2@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	testq	%r14, %r14
	je	LBB0_2
## %bb.1:
	movl	$184549376, %ecx                ## imm = 0xB000000
	callq	_snd_ca0106_ptr_write
	movq	_CAPTURE_CONTROL@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	callq	_snd_ca0106_ptr_read
	andl	$-4097, %eax                    ## imm = 0xEFFF
	movl	(%r14), %esi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	movl	%eax, %ecx
	callq	_snd_ca0106_ptr_write
	movq	_GPIO@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	(%rbx), %rdi
	callq	_inl
	andl	$-258, %eax                     ## imm = 0xFEFE
	jmp	LBB0_3
LBB0_2:
	movl	$983040, %ecx                   ## imm = 0xF0000
	callq	_snd_ca0106_ptr_write
	movq	_CAPTURE_CONTROL@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	callq	_snd_ca0106_ptr_read
	orl	$4096, %eax                     ## imm = 0x1000
	movl	(%r14), %esi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	movl	%eax, %ecx
	callq	_snd_ca0106_ptr_write
	movq	_GPIO@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	(%rbx), %rdi
	callq	_inl
	orl	$257, %eax                      ## imm = 0x101
LBB0_3:
	movq	_GPIO@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rsi
	addq	(%rbx), %rsi
	movl	%eax, %edi
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_outl                           ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_SPDIF_SELECT1,4,2              ## @SPDIF_SELECT1
	.comm	_SPDIF_SELECT2,4,2              ## @SPDIF_SELECT2
	.comm	_CAPTURE_CONTROL,4,2            ## @CAPTURE_CONTROL
	.comm	_GPIO,8,3                       ## @GPIO
	.no_dead_strip	_ca0106_spdif_enable
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ca0106_spdif_enable
_ca0106_spdif_enable:                   ; @ca0106_spdif_enable
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	mov	x19, x0
	ldr	x21, [x0, #8]
Lloh0:
	adrp	x8, _SPDIF_SELECT1@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SPDIF_SELECT1@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	w2, #0
	mov	w3, #15
	bl	_snd_ca0106_ptr_write
Lloh3:
	adrp	x8, _SPDIF_SELECT2@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SPDIF_SELECT2@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
Lloh6:
	adrp	x20, _GPIO@GOTPAGE
Lloh7:
	ldr	x20, [x20, _GPIO@GOTPAGEOFF]
	mov	x0, x19
	mov	w2, #0
	cbz	x21, LBB0_2
; %bb.1:
	mov	w3, #184549376
	bl	_snd_ca0106_ptr_write
Lloh8:
	adrp	x21, _CAPTURE_CONTROL@GOTPAGE
Lloh9:
	ldr	x21, [x21, _CAPTURE_CONTROL@GOTPAGEOFF]
	ldr	w1, [x21]
	mov	x0, x19
	mov	w2, #0
	bl	_snd_ca0106_ptr_read
	and	w3, w0, #0xffffefff
	ldr	w1, [x21]
	mov	x0, x19
	mov	w2, #0
	bl	_snd_ca0106_ptr_write
	ldr	x8, [x19]
	ldr	x9, [x20]
	add	x0, x9, x8
	bl	_inl
	mov	w8, #-258
	and	w0, w0, w8
	b	LBB0_3
LBB0_2:
	mov	w3, #983040
	bl	_snd_ca0106_ptr_write
Lloh10:
	adrp	x21, _CAPTURE_CONTROL@GOTPAGE
Lloh11:
	ldr	x21, [x21, _CAPTURE_CONTROL@GOTPAGEOFF]
	ldr	w1, [x21]
	mov	x0, x19
	mov	w2, #0
	bl	_snd_ca0106_ptr_read
	orr	w3, w0, #0x1000
	ldr	w1, [x21]
	mov	x0, x19
	mov	w2, #0
	bl	_snd_ca0106_ptr_write
	ldr	x8, [x19]
	ldr	x9, [x20]
	add	x0, x9, x8
	bl	_inl
	mov	w8, #257
	orr	w0, w0, w8
LBB0_3:
	ldr	x8, [x19]
	ldr	x9, [x20]
	add	x1, x9, x8
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_outl
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_SPDIF_SELECT1,4,2              ; @SPDIF_SELECT1
	.comm	_SPDIF_SELECT2,4,2              ; @SPDIF_SELECT2
	.comm	_CAPTURE_CONTROL,4,2            ; @CAPTURE_CONTROL
	.comm	_GPIO,8,3                       ; @GPIO
	.no_dead_strip	_ca0106_spdif_enable
.subsections_via_symbols
