	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function set_sample_rate
_set_sample_rate:                       ## @set_sample_rate
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %ebx
	movq	%rdi, %r14
	xorl	%edi, %edi
	cmpl	$50000, %esi                    ## imm = 0xC350
	jl	LBB0_2
## %bb.1:
	movq	(%r14), %rax
	movq	_DIGITAL_MODE_ADAT@GOTPCREL(%rip), %rcx
	xorl	%edi, %edi
	cmpq	(%rcx), %rax
	sete	%dil
LBB0_2:
	callq	_snd_BUG_ON
	testq	%rax, %rax
	je	LBB0_5
LBB0_3:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_4
LBB0_5:
	movq	8(%r14), %rax
	movq	_ECHO_CLOCK_INTERNAL@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_6
## %bb.7:
	movq	24(%r14), %rax
	movl	8(%rax), %edi
	callq	_le32_to_cpu
	movl	%eax, %r15d
	movq	_GML_CLOCK_CLEAR_MASK@GOTPCREL(%rip), %rax
	andl	(%rax), %r15d
	movq	_GML_SPDIF_RATE_CLEAR_MASK@GOTPCREL(%rip), %rax
	andl	(%rax), %r15d
	cmpl	$31999, %ebx                    ## imm = 0x7CFF
	jle	LBB0_8
## %bb.15:
	cmpl	$47999, %ebx                    ## imm = 0xBB7F
	jle	LBB0_16
## %bb.20:
	cmpl	$48000, %ebx                    ## imm = 0xBB80
	je	LBB0_24
## %bb.21:
	cmpl	$88200, %ebx                    ## imm = 0x15888
	je	LBB0_29
## %bb.22:
	cmpl	$96000, %ebx                    ## imm = 0x17700
	jne	LBB0_28
## %bb.23:
	movq	_GML_96KHZ@GOTPCREL(%rip), %rax
	jmp	LBB0_30
LBB0_6:
	leaq	L_.str(%rip), %rdi
	callq	_DE_ACT
	movl	%ebx, %edi
	callq	_cpu_to_le32
	movq	24(%r14), %rcx
	movq	%rax, (%rcx)
	movl	%ebx, 16(%r14)
	xorl	%eax, %eax
LBB0_4:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_8:
	cmpl	$15999, %ebx                    ## imm = 0x3E7F
	jg	LBB0_12
## %bb.9:
	cmpl	$8000, %ebx                     ## imm = 0x1F40
	je	LBB0_27
## %bb.10:
	cmpl	$11025, %ebx                    ## imm = 0x2B11
	jne	LBB0_28
## %bb.11:
	movq	_GML_11KHZ@GOTPCREL(%rip), %rax
	jmp	LBB0_30
LBB0_16:
	cmpl	$32000, %ebx                    ## imm = 0x7D00
	je	LBB0_25
## %bb.17:
	cmpl	$44100, %ebx                    ## imm = 0xAC44
	jne	LBB0_28
## %bb.18:
	movq	_GML_44KHZ@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	movq	_GML_SPDIF_PRO_MODE@GOTPCREL(%rip), %rax
	testl	%r15d, (%rax)
	je	LBB0_31
## %bb.19:
	movq	_GML_SPDIF_SAMPLE_RATE0@GOTPCREL(%rip), %rax
	orl	(%rax), %r12d
	jmp	LBB0_31
LBB0_12:
	cmpl	$16000, %ebx                    ## imm = 0x3E80
	je	LBB0_26
## %bb.13:
	cmpl	$22050, %ebx                    ## imm = 0x5622
	jne	LBB0_28
## %bb.14:
	movq	_GML_22KHZ@GOTPCREL(%rip), %rax
	jmp	LBB0_30
LBB0_24:
	movq	_GML_48KHZ@GOTPCREL(%rip), %rax
	movq	_GML_SPDIF_SAMPLE_RATE1@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r12d
	orl	(%rax), %r12d
	jmp	LBB0_31
LBB0_29:
	movq	_GML_88KHZ@GOTPCREL(%rip), %rax
	jmp	LBB0_30
LBB0_27:
	movq	_GML_8KHZ@GOTPCREL(%rip), %rax
	jmp	LBB0_30
LBB0_25:
	movq	_GML_32KHZ@GOTPCREL(%rip), %rax
	movq	_GML_SPDIF_SAMPLE_RATE0@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r12d
	orl	(%rax), %r12d
	movq	_GML_SPDIF_SAMPLE_RATE1@GOTPCREL(%rip), %rax
	orl	(%rax), %r12d
	jmp	LBB0_31
LBB0_26:
	movq	_GML_16KHZ@GOTPCREL(%rip), %rax
LBB0_30:
	movl	(%rax), %r12d
LBB0_31:
	orl	%r12d, %r15d
	movl	%ebx, %edi
	callq	_cpu_to_le32
	movq	24(%r14), %rcx
	movq	%rax, (%rcx)
	movl	%ebx, 16(%r14)
	movslq	%r12d, %rdi
	callq	_DE_ACT
	movq	_FALSE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	movl	%r15d, %esi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_write_control_reg              ## TAILCALL
LBB0_28:
	movslq	%ebx, %rdi
	callq	_DE_ACT
	jmp	LBB0_3
	.cfi_endproc
                                        ## -- End function
	.comm	_DIGITAL_MODE_ADAT,8,3          ## @DIGITAL_MODE_ADAT
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_ECHO_CLOCK_INTERNAL,8,3        ## @ECHO_CLOCK_INTERNAL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"set_sample_rate: Cannot set sample rate - clock not set to CLK_CLOCKININTERNAL\n"

	.comm	_GML_CLOCK_CLEAR_MASK,4,2       ## @GML_CLOCK_CLEAR_MASK
	.comm	_GML_SPDIF_RATE_CLEAR_MASK,4,2  ## @GML_SPDIF_RATE_CLEAR_MASK
	.comm	_GML_96KHZ,4,2                  ## @GML_96KHZ
	.comm	_GML_88KHZ,4,2                  ## @GML_88KHZ
	.comm	_GML_48KHZ,4,2                  ## @GML_48KHZ
	.comm	_GML_SPDIF_SAMPLE_RATE1,4,2     ## @GML_SPDIF_SAMPLE_RATE1
	.comm	_GML_44KHZ,4,2                  ## @GML_44KHZ
	.comm	_GML_SPDIF_PRO_MODE,4,2         ## @GML_SPDIF_PRO_MODE
	.comm	_GML_SPDIF_SAMPLE_RATE0,4,2     ## @GML_SPDIF_SAMPLE_RATE0
	.comm	_GML_32KHZ,4,2                  ## @GML_32KHZ
	.comm	_GML_22KHZ,4,2                  ## @GML_22KHZ
	.comm	_GML_16KHZ,4,2                  ## @GML_16KHZ
	.comm	_GML_11KHZ,4,2                  ## @GML_11KHZ
	.comm	_GML_8KHZ,4,2                   ## @GML_8KHZ
	.comm	_FALSE,4,2                      ## @FALSE
	.no_dead_strip	_set_sample_rate
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function set_sample_rate
_set_sample_rate:                       ; @set_sample_rate
	.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	x20, x1
	mov	x19, x0
	mov	w8, #50000
	cmp	w1, w8
	b.lt	LBB0_2
; %bb.1:
	ldr	x8, [x19]
Lloh0:
	adrp	x9, _DIGITAL_MODE_ADAT@GOTPAGE
Lloh1:
	ldr	x9, [x9, _DIGITAL_MODE_ADAT@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	cset	w0, eq
	bl	_snd_BUG_ON
	cbnz	x0, LBB0_3
	b	LBB0_4
LBB0_2:
	mov	w0, #0
	bl	_snd_BUG_ON
	cbz	x0, LBB0_4
LBB0_3:
Lloh3:
	adrp	x8, _EINVAL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_12
LBB0_4:
	ldr	x8, [x19, #8]
Lloh6:
	adrp	x9, _ECHO_CLOCK_INTERNAL@GOTPAGE
Lloh7:
	ldr	x9, [x9, _ECHO_CLOCK_INTERNAL@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_11
; %bb.5:
	ldr	x8, [x19, #24]
	ldr	w0, [x8, #8]
	bl	_le32_to_cpu
Lloh9:
	adrp	x8, _GML_CLOCK_CLEAR_MASK@GOTPAGE
Lloh10:
	ldr	x8, [x8, _GML_CLOCK_CLEAR_MASK@GOTPAGEOFF]
Lloh11:
	adrp	x9, _GML_SPDIF_RATE_CLEAR_MASK@GOTPAGE
Lloh12:
	ldr	x9, [x9, _GML_SPDIF_RATE_CLEAR_MASK@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
Lloh14:
	ldr	w9, [x9]
	and	w8, w8, w0
	and	w8, w8, w9
	mov	w9, #31999
	cmp	w20, w9
	b.le	LBB0_13
; %bb.6:
	mov	w9, #47999
	cmp	w20, w9
	b.le	LBB0_17
; %bb.7:
	mov	w9, #48000
	cmp	w20, w9
	b.eq	LBB0_24
; %bb.8:
	mov	w9, #22664
	movk	w9, #1, lsl #16
	cmp	w20, w9
	b.eq	LBB0_25
; %bb.9:
	mov	w9, #30464
	movk	w9, #1, lsl #16
	cmp	w20, w9
	b.ne	LBB0_31
; %bb.10:
Lloh15:
	adrp	x9, _GML_96KHZ@GOTPAGE
Lloh16:
	ldr	x9, [x9, _GML_96KHZ@GOTPAGEOFF]
	b	LBB0_29
LBB0_11:
Lloh17:
	adrp	x0, l_.str@PAGE
Lloh18:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DE_ACT
	mov	x0, x20
	bl	_cpu_to_le32
	mov	x8, x0
	mov	w0, #0
	ldr	x9, [x19, #24]
	str	x8, [x9]
	str	w20, [x19, #16]
LBB0_12:
	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
	ret
LBB0_13:
	mov	w9, #15999
	cmp	w20, w9
	b.gt	LBB0_21
; %bb.14:
	mov	w9, #8000
	cmp	w20, w9
	b.eq	LBB0_26
; %bb.15:
	mov	w9, #11025
	cmp	w20, w9
	b.ne	LBB0_31
; %bb.16:
Lloh19:
	adrp	x9, _GML_11KHZ@GOTPAGE
Lloh20:
	ldr	x9, [x9, _GML_11KHZ@GOTPAGEOFF]
	b	LBB0_29
LBB0_17:
	mov	w9, #32000
	cmp	w20, w9
	b.eq	LBB0_27
; %bb.18:
	mov	w9, #44100
	cmp	w20, w9
	b.ne	LBB0_31
; %bb.19:
Lloh21:
	adrp	x9, _GML_44KHZ@GOTPAGE
Lloh22:
	ldr	x9, [x9, _GML_44KHZ@GOTPAGEOFF]
Lloh23:
	ldr	w22, [x9]
Lloh24:
	adrp	x9, _GML_SPDIF_PRO_MODE@GOTPAGE
Lloh25:
	ldr	x9, [x9, _GML_SPDIF_PRO_MODE@GOTPAGEOFF]
Lloh26:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_30
; %bb.20:
Lloh27:
	adrp	x9, _GML_SPDIF_SAMPLE_RATE0@GOTPAGE
Lloh28:
	ldr	x9, [x9, _GML_SPDIF_SAMPLE_RATE0@GOTPAGEOFF]
Lloh29:
	ldr	w9, [x9]
	orr	w22, w9, w22
	b	LBB0_30
LBB0_21:
	mov	w9, #16000
	cmp	w20, w9
	b.eq	LBB0_28
; %bb.22:
	mov	w9, #22050
	cmp	w20, w9
	b.ne	LBB0_31
; %bb.23:
Lloh30:
	adrp	x9, _GML_22KHZ@GOTPAGE
Lloh31:
	ldr	x9, [x9, _GML_22KHZ@GOTPAGEOFF]
	b	LBB0_29
LBB0_24:
Lloh32:
	adrp	x9, _GML_48KHZ@GOTPAGE
Lloh33:
	ldr	x9, [x9, _GML_48KHZ@GOTPAGEOFF]
Lloh34:
	ldr	w9, [x9]
Lloh35:
	adrp	x10, _GML_SPDIF_SAMPLE_RATE1@GOTPAGE
Lloh36:
	ldr	x10, [x10, _GML_SPDIF_SAMPLE_RATE1@GOTPAGEOFF]
Lloh37:
	ldr	w10, [x10]
	orr	w22, w10, w9
	b	LBB0_30
LBB0_25:
Lloh38:
	adrp	x9, _GML_88KHZ@GOTPAGE
Lloh39:
	ldr	x9, [x9, _GML_88KHZ@GOTPAGEOFF]
	b	LBB0_29
LBB0_26:
Lloh40:
	adrp	x9, _GML_8KHZ@GOTPAGE
Lloh41:
	ldr	x9, [x9, _GML_8KHZ@GOTPAGEOFF]
	b	LBB0_29
LBB0_27:
Lloh42:
	adrp	x9, _GML_32KHZ@GOTPAGE
Lloh43:
	ldr	x9, [x9, _GML_32KHZ@GOTPAGEOFF]
Lloh44:
	ldr	w9, [x9]
Lloh45:
	adrp	x10, _GML_SPDIF_SAMPLE_RATE0@GOTPAGE
Lloh46:
	ldr	x10, [x10, _GML_SPDIF_SAMPLE_RATE0@GOTPAGEOFF]
Lloh47:
	ldr	w10, [x10]
	orr	w9, w10, w9
Lloh48:
	adrp	x10, _GML_SPDIF_SAMPLE_RATE1@GOTPAGE
Lloh49:
	ldr	x10, [x10, _GML_SPDIF_SAMPLE_RATE1@GOTPAGEOFF]
Lloh50:
	ldr	w10, [x10]
	orr	w22, w9, w10
	b	LBB0_30
LBB0_28:
Lloh51:
	adrp	x9, _GML_16KHZ@GOTPAGE
Lloh52:
	ldr	x9, [x9, _GML_16KHZ@GOTPAGEOFF]
LBB0_29:
	ldr	w22, [x9]
LBB0_30:
	orr	w21, w22, w8
	mov	x0, x20
	bl	_cpu_to_le32
	ldr	x8, [x19, #24]
	str	x0, [x8]
	str	w20, [x19, #16]
	sxtw	x0, w22
	bl	_DE_ACT
Lloh53:
	adrp	x8, _FALSE@GOTPAGE
Lloh54:
	ldr	x8, [x8, _FALSE@GOTPAGEOFF]
Lloh55:
	ldr	w2, [x8]
	mov	x0, x19
	mov	x1, x21
	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	_write_control_reg
LBB0_31:
	sxtw	x0, w20
	bl	_DE_ACT
	b	LBB0_3
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh13
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGot	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGot	Lloh38, Lloh39
	.loh AdrpLdrGot	Lloh40, Lloh41
	.loh AdrpLdrGotLdr	Lloh48, Lloh49, Lloh50
	.loh AdrpLdrGotLdr	Lloh45, Lloh46, Lloh47
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh44
	.loh AdrpLdrGot	Lloh51, Lloh52
	.loh AdrpLdrGotLdr	Lloh53, Lloh54, Lloh55
	.cfi_endproc
                                        ; -- End function
	.comm	_DIGITAL_MODE_ADAT,8,3          ; @DIGITAL_MODE_ADAT
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_ECHO_CLOCK_INTERNAL,8,3        ; @ECHO_CLOCK_INTERNAL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"set_sample_rate: Cannot set sample rate - clock not set to CLK_CLOCKININTERNAL\n"

	.comm	_GML_CLOCK_CLEAR_MASK,4,2       ; @GML_CLOCK_CLEAR_MASK
	.comm	_GML_SPDIF_RATE_CLEAR_MASK,4,2  ; @GML_SPDIF_RATE_CLEAR_MASK
	.comm	_GML_96KHZ,4,2                  ; @GML_96KHZ
	.comm	_GML_88KHZ,4,2                  ; @GML_88KHZ
	.comm	_GML_48KHZ,4,2                  ; @GML_48KHZ
	.comm	_GML_SPDIF_SAMPLE_RATE1,4,2     ; @GML_SPDIF_SAMPLE_RATE1
	.comm	_GML_44KHZ,4,2                  ; @GML_44KHZ
	.comm	_GML_SPDIF_PRO_MODE,4,2         ; @GML_SPDIF_PRO_MODE
	.comm	_GML_SPDIF_SAMPLE_RATE0,4,2     ; @GML_SPDIF_SAMPLE_RATE0
	.comm	_GML_32KHZ,4,2                  ; @GML_32KHZ
	.comm	_GML_22KHZ,4,2                  ; @GML_22KHZ
	.comm	_GML_16KHZ,4,2                  ; @GML_16KHZ
	.comm	_GML_11KHZ,4,2                  ; @GML_11KHZ
	.comm	_GML_8KHZ,4,2                   ; @GML_8KHZ
	.comm	_FALSE,4,2                      ; @FALSE
	.no_dead_strip	_set_sample_rate
.subsections_via_symbols
