	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function set_input_clock
_set_input_clock:                       ## @set_input_clock
	.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	%esi, %r14d
	movq	%rdi, %r15
	leaq	L_.str(%rip), %rdi
	callq	_DE_ACT
	movq	16(%r15), %rax
	movl	4(%rax), %edi
	callq	_le32_to_cpu
	movl	%eax, %ebx
	movq	_E3G_CLOCK_CLEAR_MASK@GOTPCREL(%rip), %rax
	andl	(%rax), %ebx
	movq	16(%r15), %rax
	movl	(%rax), %edi
	callq	_le32_to_cpu
	movl	%eax, %r13d
	leal	-128(%r14), %eax
	cmpl	$3, %eax
	ja	LBB0_14
## %bb.1:
	leaq	LJTI0_0(%rip), %rcx
	movslq	(%rcx,%rax,4), %rax
	addq	%rcx, %rax
	jmpq	*%rax
LBB0_13:
	leaq	L_.str.4(%rip), %rdi
	callq	_DE_ACT
	movq	_E3G_WORD_CLOCK@GOTPCREL(%rip), %rax
	orl	(%rax), %ebx
	movq	_E3G_CLOCK_DETECT_BIT_WORD96@GOTPCREL(%rip), %rax
	jmp	LBB0_7
LBB0_2:
	leaq	L_.str.1(%rip), %rdi
	callq	_DE_ACT
	movl	$130, (%r15)
	movl	8(%r15), %esi
	movq	%r15, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_set_sample_rate                ## TAILCALL
LBB0_10:
	movl	4(%r15), %eax
	movq	_DIGITAL_MODE_ADAT@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_4
## %bb.11:
	leaq	L_.str.3(%rip), %rdi
	callq	_DE_ACT
	movq	_E3G_ADAT_CLOCK@GOTPCREL(%rip), %rax
	orl	(%rax), %ebx
	movq	_E3G_DOUBLE_SPEED_MODE@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	jmp	LBB0_12
LBB0_14:
	movslq	%r14d, %rdi
	callq	_DE_ACT
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	jmp	LBB0_5
LBB0_3:
	movl	4(%r15), %eax
	movq	_DIGITAL_MODE_ADAT@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_6
LBB0_4:
	movq	_EAGAIN@GOTPCREL(%rip), %rcx
LBB0_5:
	xorl	%eax, %eax
	subl	(%rcx), %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	leaq	L_.str.2(%rip), %rdi
	callq	_DE_ACT
	movq	_E3G_SPDIF_CLOCK@GOTPCREL(%rip), %rax
	orl	(%rax), %ebx
	movq	_E3G_CLOCK_DETECT_BIT_SPDIF96@GOTPCREL(%rip), %rax
LBB0_7:
	movq	_E3G_DOUBLE_SPEED_MODE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r12d
	testl	%r13d, (%rax)
	je	LBB0_12
## %bb.8:
	orl	%ebx, %r12d
	jmp	LBB0_9
LBB0_12:
	notl	%r12d
	andl	%ebx, %r12d
LBB0_9:
	movl	%r14d, (%r15)
	movq	%r15, %rdi
	callq	_get_frq_reg
	movq	%r15, %rdi
	movl	%r12d, %esi
	movl	%eax, %edx
	movl	$1, %ecx
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_write_control_reg              ## TAILCALL
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_13, LBB0_13-LJTI0_0
.set L0_0_set_3, LBB0_3-LJTI0_0
.set L0_0_set_2, LBB0_2-LJTI0_0
.set L0_0_set_10, LBB0_10-LJTI0_0
LJTI0_0:
	.long	L0_0_set_13
	.long	L0_0_set_3
	.long	L0_0_set_2
	.long	L0_0_set_10
	.end_data_region
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"set_input_clock:\n"

	.comm	_E3G_CLOCK_CLEAR_MASK,4,2       ## @E3G_CLOCK_CLEAR_MASK
L_.str.1:                               ## @.str.1
	.asciz	"Set Echo3G clock to INTERNAL\n"

	.comm	_DIGITAL_MODE_ADAT,4,2          ## @DIGITAL_MODE_ADAT
	.comm	_EAGAIN,4,2                     ## @EAGAIN
L_.str.2:                               ## @.str.2
	.asciz	"Set Echo3G clock to SPDIF\n"

	.comm	_E3G_SPDIF_CLOCK,4,2            ## @E3G_SPDIF_CLOCK
	.comm	_E3G_CLOCK_DETECT_BIT_SPDIF96,4,2 ## @E3G_CLOCK_DETECT_BIT_SPDIF96
	.comm	_E3G_DOUBLE_SPEED_MODE,4,2      ## @E3G_DOUBLE_SPEED_MODE
L_.str.3:                               ## @.str.3
	.asciz	"Set Echo3G clock to ADAT\n"

	.comm	_E3G_ADAT_CLOCK,4,2             ## @E3G_ADAT_CLOCK
L_.str.4:                               ## @.str.4
	.asciz	"Set Echo3G clock to WORD\n"

	.comm	_E3G_WORD_CLOCK,4,2             ## @E3G_WORD_CLOCK
	.comm	_E3G_CLOCK_DETECT_BIT_WORD96,4,2 ## @E3G_CLOCK_DETECT_BIT_WORD96
	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_set_input_clock
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function set_input_clock
_set_input_clock:                       ; @set_input_clock
	.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, x1
	mov	x19, x0
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DE_ACT
	ldr	x8, [x19, #16]
	ldr	w0, [x8, #4]
	bl	_le32_to_cpu
	mov	x22, x0
Lloh2:
	adrp	x8, _E3G_CLOCK_CLEAR_MASK@GOTPAGE
Lloh3:
	ldr	x8, [x8, _E3G_CLOCK_CLEAR_MASK@GOTPAGEOFF]
Lloh4:
	ldr	w23, [x8]
	ldr	x8, [x19, #16]
	ldr	w0, [x8]
	bl	_le32_to_cpu
	sub	w8, w20, #128
	cmp	w8, #3
	b.hi	LBB0_6
; %bb.1:
	mov	x21, x0
	and	w22, w23, w22
Lloh5:
	adrp	x9, lJTI0_0@PAGE
Lloh6:
	add	x9, x9, lJTI0_0@PAGEOFF
	adr	x10, LBB0_2
	ldrb	w11, [x9, x8]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_2:
Lloh7:
	adrp	x0, l_.str.4@PAGE
Lloh8:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	_DE_ACT
Lloh9:
	adrp	x8, _E3G_WORD_CLOCK@GOTPAGE
Lloh10:
	ldr	x8, [x8, _E3G_WORD_CLOCK@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	orr	w8, w8, w22
Lloh12:
	adrp	x9, _E3G_CLOCK_DETECT_BIT_WORD96@GOTPAGE
Lloh13:
	ldr	x9, [x9, _E3G_CLOCK_DETECT_BIT_WORD96@GOTPAGEOFF]
	b	LBB0_11
LBB0_3:
Lloh14:
	adrp	x0, l_.str.1@PAGE
Lloh15:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_DE_ACT
	mov	w8, #130
	str	w8, [x19]
	ldr	w1, [x19, #8]
	mov	x0, x19
	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
	b	_set_sample_rate
LBB0_4:
	ldr	w8, [x19, #4]
Lloh16:
	adrp	x9, _DIGITAL_MODE_ADAT@GOTPAGE
Lloh17:
	ldr	x9, [x9, _DIGITAL_MODE_ADAT@GOTPAGEOFF]
Lloh18:
	ldr	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_8
; %bb.5:
Lloh19:
	adrp	x0, l_.str.3@PAGE
Lloh20:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_DE_ACT
Lloh21:
	adrp	x8, _E3G_ADAT_CLOCK@GOTPAGE
Lloh22:
	ldr	x8, [x8, _E3G_ADAT_CLOCK@GOTPAGEOFF]
Lloh23:
	ldr	w8, [x8]
	orr	w8, w8, w22
Lloh24:
	adrp	x9, _E3G_DOUBLE_SPEED_MODE@GOTPAGE
Lloh25:
	ldr	x9, [x9, _E3G_DOUBLE_SPEED_MODE@GOTPAGEOFF]
Lloh26:
	ldr	w9, [x9]
	bic	w21, w8, w9
	b	LBB0_12
LBB0_6:
	sxtw	x0, w20
	bl	_DE_ACT
Lloh27:
	adrp	x8, _EINVAL@GOTPAGE
Lloh28:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_9
LBB0_7:
	ldr	w8, [x19, #4]
Lloh29:
	adrp	x9, _DIGITAL_MODE_ADAT@GOTPAGE
Lloh30:
	ldr	x9, [x9, _DIGITAL_MODE_ADAT@GOTPAGEOFF]
Lloh31:
	ldr	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_10
LBB0_8:
Lloh32:
	adrp	x8, _EAGAIN@GOTPAGE
Lloh33:
	ldr	x8, [x8, _EAGAIN@GOTPAGEOFF]
LBB0_9:
	ldr	w8, [x8]
	neg	w0, w8
	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_10:
Lloh34:
	adrp	x0, l_.str.2@PAGE
Lloh35:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_DE_ACT
Lloh36:
	adrp	x8, _E3G_SPDIF_CLOCK@GOTPAGE
Lloh37:
	ldr	x8, [x8, _E3G_SPDIF_CLOCK@GOTPAGEOFF]
Lloh38:
	ldr	w8, [x8]
	orr	w8, w8, w22
Lloh39:
	adrp	x9, _E3G_CLOCK_DETECT_BIT_SPDIF96@GOTPAGE
Lloh40:
	ldr	x9, [x9, _E3G_CLOCK_DETECT_BIT_SPDIF96@GOTPAGEOFF]
LBB0_11:
	ldr	w9, [x9]
	tst	w9, w21
Lloh41:
	adrp	x9, _E3G_DOUBLE_SPEED_MODE@GOTPAGE
Lloh42:
	ldr	x9, [x9, _E3G_DOUBLE_SPEED_MODE@GOTPAGEOFF]
Lloh43:
	ldr	w9, [x9]
	bic	w10, w8, w9
	orr	w8, w9, w8
	csel	w21, w10, w8, eq
LBB0_12:
	str	w20, [x19]
	mov	x0, x19
	bl	_get_frq_reg
	mov	x2, x0
	mov	x0, x19
	mov	x1, x21
	mov	w3, #1
	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
	b	_write_control_reg
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGot	Lloh32, Lloh33
	.loh AdrpLdrGot	Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpAdd	Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh41, Lloh42, Lloh43
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_2-LBB0_2)>>2
	.byte	(LBB0_7-LBB0_2)>>2
	.byte	(LBB0_3-LBB0_2)>>2
	.byte	(LBB0_4-LBB0_2)>>2
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"set_input_clock:\n"

	.comm	_E3G_CLOCK_CLEAR_MASK,4,2       ; @E3G_CLOCK_CLEAR_MASK
l_.str.1:                               ; @.str.1
	.asciz	"Set Echo3G clock to INTERNAL\n"

	.comm	_DIGITAL_MODE_ADAT,4,2          ; @DIGITAL_MODE_ADAT
	.comm	_EAGAIN,4,2                     ; @EAGAIN
l_.str.2:                               ; @.str.2
	.asciz	"Set Echo3G clock to SPDIF\n"

	.comm	_E3G_SPDIF_CLOCK,4,2            ; @E3G_SPDIF_CLOCK
	.comm	_E3G_CLOCK_DETECT_BIT_SPDIF96,4,2 ; @E3G_CLOCK_DETECT_BIT_SPDIF96
	.comm	_E3G_DOUBLE_SPEED_MODE,4,2      ; @E3G_DOUBLE_SPEED_MODE
l_.str.3:                               ; @.str.3
	.asciz	"Set Echo3G clock to ADAT\n"

	.comm	_E3G_ADAT_CLOCK,4,2             ; @E3G_ADAT_CLOCK
l_.str.4:                               ; @.str.4
	.asciz	"Set Echo3G clock to WORD\n"

	.comm	_E3G_WORD_CLOCK,4,2             ; @E3G_WORD_CLOCK
	.comm	_E3G_CLOCK_DETECT_BIT_WORD96,4,2 ; @E3G_CLOCK_DETECT_BIT_WORD96
	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_set_input_clock
.subsections_via_symbols
