	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function snd_cmipci_capture_spdif_open
_snd_cmipci_capture_spdif_open:         ## @snd_cmipci_capture_spdif_open
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	callq	_snd_pcm_substream_chip
	movq	%rax, %r15
	movq	(%rbx), %r14
	movq	_CM_OPEN_SPDIF_CAPTURE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movq	%rbx, %rdx
	callq	_open_device_check
	testl	%eax, %eax
	js	LBB0_1
## %bb.2:
	movq	_snd_cmipci_capture_spdif@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, (%r14)
	cmpq	$0, 8(%r15)
	je	LBB0_5
## %bb.3:
	cmpl	$68, (%r15)
	je	LBB0_5
## %bb.4:
	movq	_SNDRV_PCM_RATE_88200@GOTPCREL(%rip), %rcx
	movq	_SNDRV_PCM_RATE_96000@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	orl	(%rcx), %edx
	orl	%eax, %edx
	movl	%edx, (%r14)
	movl	$96000, 4(%r14)                 ## imm = 0x17700
LBB0_5:
	movq	_SNDRV_PCM_HW_PARAM_BUFFER_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%ebx, %ebx
	movq	%r14, %rdi
	xorl	%edx, %edx
	movl	$262144, %ecx                   ## imm = 0x40000
	callq	_snd_pcm_hw_constraint_minmax
	jmp	LBB0_6
LBB0_1:
	movl	%eax, %ebx
LBB0_6:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_CM_OPEN_SPDIF_CAPTURE,4,2      ## @CM_OPEN_SPDIF_CAPTURE
	.comm	_snd_cmipci_capture_spdif,8,2   ## @snd_cmipci_capture_spdif
	.comm	_SNDRV_PCM_RATE_88200,4,2       ## @SNDRV_PCM_RATE_88200
	.comm	_SNDRV_PCM_RATE_96000,4,2       ## @SNDRV_PCM_RATE_96000
	.comm	_SNDRV_PCM_HW_PARAM_BUFFER_SIZE,4,2 ## @SNDRV_PCM_HW_PARAM_BUFFER_SIZE
	.no_dead_strip	_snd_cmipci_capture_spdif_open
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function snd_cmipci_capture_spdif_open
_snd_cmipci_capture_spdif_open:         ; @snd_cmipci_capture_spdif_open
	.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	x21, x0
	bl	_snd_pcm_substream_chip
	mov	x20, x0
	ldr	x19, [x21]
Lloh0:
	adrp	x8, _CM_OPEN_SPDIF_CAPTURE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _CM_OPEN_SPDIF_CAPTURE@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x2, x21
	bl	_open_device_check
	tbnz	w0, #31, LBB0_5
; %bb.1:
Lloh3:
	adrp	x8, _snd_cmipci_capture_spdif@GOTPAGE
Lloh4:
	ldr	x8, [x8, _snd_cmipci_capture_spdif@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	str	x8, [x19]
	ldr	x9, [x20, #8]
	cbz	x9, LBB0_4
; %bb.2:
	ldr	w9, [x20]
	cmp	w9, #68
	b.eq	LBB0_4
; %bb.3:
Lloh6:
	adrp	x9, _SNDRV_PCM_RATE_88200@GOTPAGE
Lloh7:
	ldr	x9, [x9, _SNDRV_PCM_RATE_88200@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
Lloh9:
	adrp	x10, _SNDRV_PCM_RATE_96000@GOTPAGE
Lloh10:
	ldr	x10, [x10, _SNDRV_PCM_RATE_96000@GOTPAGEOFF]
Lloh11:
	ldr	w10, [x10]
	orr	w9, w10, w9
	orr	w8, w9, w8
	mov	w9, #30464
	movk	w9, #1, lsl #16
	stp	w8, w9, [x19]
LBB0_4:
Lloh12:
	adrp	x8, _SNDRV_PCM_HW_PARAM_BUFFER_SIZE@GOTPAGE
Lloh13:
	ldr	x8, [x8, _SNDRV_PCM_HW_PARAM_BUFFER_SIZE@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #0
	mov	w3, #262144
	bl	_snd_pcm_hw_constraint_minmax
	mov	w0, #0
LBB0_5:
	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
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_CM_OPEN_SPDIF_CAPTURE,4,2      ; @CM_OPEN_SPDIF_CAPTURE
	.comm	_snd_cmipci_capture_spdif,8,2   ; @snd_cmipci_capture_spdif
	.comm	_SNDRV_PCM_RATE_88200,4,2       ; @SNDRV_PCM_RATE_88200
	.comm	_SNDRV_PCM_RATE_96000,4,2       ; @SNDRV_PCM_RATE_96000
	.comm	_SNDRV_PCM_HW_PARAM_BUFFER_SIZE,4,2 ; @SNDRV_PCM_HW_PARAM_BUFFER_SIZE
	.no_dead_strip	_snd_cmipci_capture_spdif_open
.subsections_via_symbols
