	.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, %r13
	leaq	L_.str(%rip), %rdi
	callq	_DE_ACT
	leaq	24(%r13), %rdi
	callq	_atomic_read
	testq	%rax, %rax
	je	LBB0_4
LBB0_1:
	movq	_EAGAIN@GOTPCREL(%rip), %rax
LBB0_2:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_3:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	movq	16(%r13), %rax
	movl	4(%rax), %edi
	callq	_le32_to_cpu
	movl	%eax, %r15d
	movq	_GML_CLOCK_CLEAR_MASK@GOTPCREL(%rip), %rax
	andl	(%rax), %r15d
	movq	16(%r13), %rax
	movl	(%rax), %edi
	callq	_le32_to_cpu
	movl	%eax, %ebx
	leal	-128(%r14), %eax
	cmpl	$3, %eax
	ja	LBB0_8
## %bb.5:
	leaq	LJTI0_0(%rip), %rcx
	movslq	(%rcx,%rax,4), %rax
	addq	%rcx, %rax
	jmpq	*%rax
LBB0_6:
	leaq	L_.str.3(%rip), %rdi
	callq	_DE_ACT
	leaq	8(%r13), %r12
	movq	%r12, %rdi
	callq	_spin_unlock_irq
	movq	_GML_CLOCK_DETECT_BIT_WORD96@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	andl	%ebx, %esi
	movq	%r13, %rdi
	callq	_switch_asic
	movl	%ebx, -44(%rbp)                 ## 4-byte Spill
	movl	%eax, %ebx
	movq	%r12, %rdi
	callq	_spin_lock_irq
	testl	%ebx, %ebx
	js	LBB0_3
## %bb.7:
	movq	_GML_WORD_CLOCK@GOTPCREL(%rip), %rax
	orl	(%rax), %r15d
	movq	_GML_DOUBLE_SPEED_MODE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_GML_CLOCK_DETECT_BIT_WORD96@GOTPCREL(%rip), %rax
	jmp	LBB0_12
LBB0_8:
	movslq	%r14d, %rdi
	callq	_DE_ACT
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_2
LBB0_9:
	movl	4(%r13), %eax
	movq	_DIGITAL_MODE_ADAT@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	je	LBB0_1
## %bb.10:
	leaq	8(%r13), %r12
	movq	%r12, %rdi
	callq	_spin_unlock_irq
	movq	_GML_CLOCK_DETECT_BIT_SPDIF96@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	andl	%ebx, %esi
	movq	%r13, %rdi
	callq	_switch_asic
	movl	%ebx, -44(%rbp)                 ## 4-byte Spill
	movl	%eax, %ebx
	movq	%r12, %rdi
	callq	_spin_lock_irq
	testl	%ebx, %ebx
	js	LBB0_3
## %bb.11:
	leaq	L_.str.2(%rip), %rdi
	callq	_DE_ACT
	movq	_GML_SPDIF_CLOCK@GOTPCREL(%rip), %rax
	orl	(%rax), %r15d
	movq	_GML_DOUBLE_SPEED_MODE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_GML_CLOCK_DETECT_BIT_SPDIF96@GOTPCREL(%rip), %rax
LBB0_12:
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	testl	%ecx, (%rax)
	je	LBB0_17
## %bb.13:
	orl	%r15d, %esi
	jmp	LBB0_18
LBB0_14:
	leaq	L_.str.1(%rip), %rdi
	callq	_DE_ACT
	movl	$130, (%r13)
	movl	12(%r13), %esi
	movq	%r13, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_set_sample_rate                ## TAILCALL
LBB0_15:
	leaq	L_.str.4(%rip), %rdi
	callq	_DE_ACT
	movl	4(%r13), %eax
	movq	_DIGITAL_MODE_ADAT@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_1
## %bb.16:
	movq	_GML_ADAT_CLOCK@GOTPCREL(%rip), %rax
	orl	(%rax), %r15d
	movq	_GML_DOUBLE_SPEED_MODE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
LBB0_17:
	notl	%esi
	andl	%r15d, %esi
LBB0_18:
	movl	%r14d, (%r13)
	movq	_TRUE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r13, %rdi
	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_6, LBB0_6-LJTI0_0
.set L0_0_set_9, LBB0_9-LJTI0_0
.set L0_0_set_14, LBB0_14-LJTI0_0
.set L0_0_set_15, LBB0_15-LJTI0_0
LJTI0_0:
	.long	L0_0_set_6
	.long	L0_0_set_9
	.long	L0_0_set_14
	.long	L0_0_set_15
	.end_data_region
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"set_input_clock:\n"

	.comm	_EAGAIN,4,2                     ## @EAGAIN
	.comm	_GML_CLOCK_CLEAR_MASK,4,2       ## @GML_CLOCK_CLEAR_MASK
L_.str.1:                               ## @.str.1
	.asciz	"Set Mona clock to INTERNAL\n"

	.comm	_DIGITAL_MODE_ADAT,4,2          ## @DIGITAL_MODE_ADAT
	.comm	_GML_CLOCK_DETECT_BIT_SPDIF96,4,2 ## @GML_CLOCK_DETECT_BIT_SPDIF96
L_.str.2:                               ## @.str.2
	.asciz	"Set Mona clock to SPDIF\n"

	.comm	_GML_SPDIF_CLOCK,4,2            ## @GML_SPDIF_CLOCK
	.comm	_GML_DOUBLE_SPEED_MODE,4,2      ## @GML_DOUBLE_SPEED_MODE
L_.str.3:                               ## @.str.3
	.asciz	"Set Mona clock to WORD\n"

	.comm	_GML_CLOCK_DETECT_BIT_WORD96,4,2 ## @GML_CLOCK_DETECT_BIT_WORD96
	.comm	_GML_WORD_CLOCK,4,2             ## @GML_WORD_CLOCK
L_.str.4:                               ## @.str.4
	.asciz	"Set Mona clock to ADAT\n"

	.comm	_GML_ADAT_CLOCK,4,2             ## @GML_ADAT_CLOCK
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_TRUE,4,2                       ## @TRUE
	.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	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DE_ACT
	add	x0, x19, #24
	bl	_atomic_read
	cbz	x0, LBB0_4
LBB0_1:
Lloh2:
	adrp	x8, _EAGAIN@GOTPAGE
Lloh3:
	ldr	x8, [x8, _EAGAIN@GOTPAGEOFF]
LBB0_2:
	ldr	w8, [x8]
	neg	w22, w8
LBB0_3:
	mov	x0, x22
	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
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_4:
	ldr	x8, [x19, #16]
	ldr	w0, [x8, #4]
	bl	_le32_to_cpu
	mov	x22, x0
Lloh4:
	adrp	x8, _GML_CLOCK_CLEAR_MASK@GOTPAGE
Lloh5:
	ldr	x8, [x8, _GML_CLOCK_CLEAR_MASK@GOTPAGEOFF]
Lloh6:
	ldr	w23, [x8]
	ldr	x8, [x19, #16]
	ldr	w0, [x8]
	bl	_le32_to_cpu
	sub	w8, w20, #128
	cmp	w8, #3
	b.hi	LBB0_8
; %bb.5:
	mov	x21, x0
	and	w24, w23, w22
Lloh7:
	adrp	x9, lJTI0_0@PAGE
Lloh8:
	add	x9, x9, lJTI0_0@PAGEOFF
	adr	x10, LBB0_6
	ldrb	w11, [x9, x8]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_6:
Lloh9:
	adrp	x0, l_.str.3@PAGE
Lloh10:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_DE_ACT
	add	x23, x19, #8
	mov	x0, x23
	bl	_spin_unlock_irq
Lloh11:
	adrp	x25, _GML_CLOCK_DETECT_BIT_WORD96@GOTPAGE
Lloh12:
	ldr	x25, [x25, _GML_CLOCK_DETECT_BIT_WORD96@GOTPAGEOFF]
	ldr	w8, [x25]
	and	w1, w8, w21
	mov	x0, x19
	bl	_switch_asic
	mov	x22, x0
	mov	x0, x23
	bl	_spin_lock_irq
	tbnz	w22, #31, LBB0_3
; %bb.7:
Lloh13:
	adrp	x8, _GML_WORD_CLOCK@GOTPAGE
Lloh14:
	ldr	x8, [x8, _GML_WORD_CLOCK@GOTPAGEOFF]
	b	LBB0_12
LBB0_8:
	sxtw	x0, w20
	bl	_DE_ACT
Lloh15:
	adrp	x8, _EINVAL@GOTPAGE
Lloh16:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_2
LBB0_9:
	ldr	w8, [x19, #4]
Lloh17:
	adrp	x9, _DIGITAL_MODE_ADAT@GOTPAGE
Lloh18:
	ldr	x9, [x9, _DIGITAL_MODE_ADAT@GOTPAGEOFF]
Lloh19:
	ldr	w9, [x9]
	cmp	w8, w9
	b.eq	LBB0_1
; %bb.10:
	add	x23, x19, #8
	mov	x0, x23
	bl	_spin_unlock_irq
Lloh20:
	adrp	x25, _GML_CLOCK_DETECT_BIT_SPDIF96@GOTPAGE
Lloh21:
	ldr	x25, [x25, _GML_CLOCK_DETECT_BIT_SPDIF96@GOTPAGEOFF]
	ldr	w8, [x25]
	and	w1, w8, w21
	mov	x0, x19
	bl	_switch_asic
	mov	x22, x0
	mov	x0, x23
	bl	_spin_lock_irq
	tbnz	w22, #31, LBB0_3
; %bb.11:
Lloh22:
	adrp	x0, l_.str.2@PAGE
Lloh23:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_DE_ACT
Lloh24:
	adrp	x8, _GML_SPDIF_CLOCK@GOTPAGE
Lloh25:
	ldr	x8, [x8, _GML_SPDIF_CLOCK@GOTPAGEOFF]
LBB0_12:
	ldr	w8, [x8]
	orr	w8, w8, w24
	ldr	w9, [x25]
	tst	w9, w21
Lloh26:
	adrp	x9, _GML_DOUBLE_SPEED_MODE@GOTPAGE
Lloh27:
	ldr	x9, [x9, _GML_DOUBLE_SPEED_MODE@GOTPAGEOFF]
Lloh28:
	ldr	w9, [x9]
	bic	w10, w8, w9
	orr	w8, w9, w8
	csel	w1, w10, w8, eq
	b	LBB0_16
LBB0_13:
Lloh29:
	adrp	x0, l_.str.1@PAGE
Lloh30:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_DE_ACT
	mov	w8, #130
	str	w8, [x19]
	ldr	w1, [x19, #12]
	mov	x0, x19
	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
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_set_sample_rate
LBB0_14:
Lloh31:
	adrp	x0, l_.str.4@PAGE
Lloh32:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	_DE_ACT
	ldr	w8, [x19, #4]
Lloh33:
	adrp	x9, _DIGITAL_MODE_ADAT@GOTPAGE
Lloh34:
	ldr	x9, [x9, _DIGITAL_MODE_ADAT@GOTPAGEOFF]
Lloh35:
	ldr	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_1
; %bb.15:
Lloh36:
	adrp	x8, _GML_ADAT_CLOCK@GOTPAGE
Lloh37:
	ldr	x8, [x8, _GML_ADAT_CLOCK@GOTPAGEOFF]
Lloh38:
	ldr	w8, [x8]
	orr	w8, w8, w24
Lloh39:
	adrp	x9, _GML_DOUBLE_SPEED_MODE@GOTPAGE
Lloh40:
	ldr	x9, [x9, _GML_DOUBLE_SPEED_MODE@GOTPAGEOFF]
Lloh41:
	ldr	w9, [x9]
	bic	w1, w8, w9
LBB0_16:
	str	w20, [x19]
Lloh42:
	adrp	x8, _TRUE@GOTPAGE
Lloh43:
	ldr	x8, [x8, _TRUE@GOTPAGEOFF]
Lloh44:
	ldr	w2, [x8]
	mov	x0, x19
	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
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_write_control_reg
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpAdd	Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh44
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_6-LBB0_6)>>2
	.byte	(LBB0_9-LBB0_6)>>2
	.byte	(LBB0_13-LBB0_6)>>2
	.byte	(LBB0_14-LBB0_6)>>2
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"set_input_clock:\n"

	.comm	_EAGAIN,4,2                     ; @EAGAIN
	.comm	_GML_CLOCK_CLEAR_MASK,4,2       ; @GML_CLOCK_CLEAR_MASK
l_.str.1:                               ; @.str.1
	.asciz	"Set Mona clock to INTERNAL\n"

	.comm	_DIGITAL_MODE_ADAT,4,2          ; @DIGITAL_MODE_ADAT
	.comm	_GML_CLOCK_DETECT_BIT_SPDIF96,4,2 ; @GML_CLOCK_DETECT_BIT_SPDIF96
l_.str.2:                               ; @.str.2
	.asciz	"Set Mona clock to SPDIF\n"

	.comm	_GML_SPDIF_CLOCK,4,2            ; @GML_SPDIF_CLOCK
	.comm	_GML_DOUBLE_SPEED_MODE,4,2      ; @GML_DOUBLE_SPEED_MODE
l_.str.3:                               ; @.str.3
	.asciz	"Set Mona clock to WORD\n"

	.comm	_GML_CLOCK_DETECT_BIT_WORD96,4,2 ; @GML_CLOCK_DETECT_BIT_WORD96
	.comm	_GML_WORD_CLOCK,4,2             ; @GML_WORD_CLOCK
l_.str.4:                               ; @.str.4
	.asciz	"Set Mona clock to ADAT\n"

	.comm	_GML_ADAT_CLOCK,4,2             ; @GML_ADAT_CLOCK
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_TRUE,4,2                       ; @TRUE
	.no_dead_strip	_set_input_clock
.subsections_via_symbols
