	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function snd_echo_digital_mode_put
_snd_echo_digital_mode_put:             ## @snd_echo_digital_mode_put
	.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
	movq	%rsi, %rbx
	callq	_snd_kcontrol_chip
	movq	%rax, %r12
	movq	(%rbx), %rax
	movzwl	(%rax), %eax
	cmpw	(%r12), %ax
	jae	LBB0_1
## %bb.2:
	movq	8(%r12), %rcx
	movzwl	(%rcx,%rax,2), %r15d
	xorl	%ebx, %ebx
	cmpw	16(%r12), %r15w
	je	LBB0_10
## %bb.3:
	leaq	20(%r12), %r14
	movq	%r14, %rdi
	callq	_mutex_lock
	movq	%r12, %rdi
	addq	$36, %rdi
	callq	_atomic_read
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	movq	_EAGAIN@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_9
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_10
LBB0_5:
	movzwl	%r15w, %esi
	movq	%r12, %rdi
	callq	_set_digital_mode
	movl	%eax, %r15d
	testl	%eax, %eax
	jle	LBB0_8
## %bb.6:
	movq	24(%r12), %rdx
	testq	%rdx, %rdx
	je	LBB0_8
## %bb.7:
	movl	32(%r12), %edi
	movq	_SNDRV_CTL_EVENT_MASK_VALUE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_snd_ctl_notify
	movl	%r15d, %edi
	callq	_DE_ACT
LBB0_8:
	testl	%r15d, %r15d
	movl	$1, %ebx
	cmovsl	%r15d, %ebx
LBB0_9:
	movq	%r14, %rdi
	callq	_mutex_unlock
LBB0_10:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_EAGAIN,4,2                     ## @EAGAIN
	.comm	_SNDRV_CTL_EVENT_MASK_VALUE,4,2 ## @SNDRV_CTL_EVENT_MASK_VALUE
	.no_dead_strip	_snd_echo_digital_mode_put
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function snd_echo_digital_mode_put
_snd_echo_digital_mode_put:             ; @snd_echo_digital_mode_put
	.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, x1
	bl	_snd_kcontrol_chip
	ldr	x8, [x19]
	ldrh	w8, [x8]
	ldrh	w9, [x0]
	cmp	w8, w9
	b.hs	LBB0_3
; %bb.1:
	mov	x20, x0
	ldr	x9, [x0, #8]
	ldrh	w21, [x9, x8, lsl #1]
	ldrh	w8, [x0, #16]
	cmp	w21, w8
	b.ne	LBB0_4
; %bb.2:
	mov	w20, #0
	b	LBB0_11
LBB0_3:
Lloh0:
	adrp	x8, _EINVAL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w20, w8
	b	LBB0_11
LBB0_4:
	add	x19, x20, #20
	mov	x0, x19
	bl	_mutex_lock
	add	x0, x20, #36
	bl	_atomic_read
	cbz	x0, LBB0_6
; %bb.5:
Lloh3:
	adrp	x8, _EAGAIN@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EAGAIN@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	neg	w20, w8
	b	LBB0_10
LBB0_6:
	mov	x0, x20
	mov	x1, x21
	bl	_set_digital_mode
	mov	x21, x0
	cmp	w0, #1
	b.lt	LBB0_9
; %bb.7:
	ldr	x2, [x20, #24]
	cbz	x2, LBB0_9
; %bb.8:
	ldr	w0, [x20, #32]
Lloh6:
	adrp	x8, _SNDRV_CTL_EVENT_MASK_VALUE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _SNDRV_CTL_EVENT_MASK_VALUE@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	bl	_snd_ctl_notify
	mov	w0, w21
	bl	_DE_ACT
LBB0_9:
	cmp	w21, #0
	csinc	w20, w21, wzr, lt
LBB0_10:
	mov	x0, x19
	bl	_mutex_unlock
LBB0_11:
	mov	x0, x20
	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	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_EAGAIN,4,2                     ; @EAGAIN
	.comm	_SNDRV_CTL_EVENT_MASK_VALUE,4,2 ; @SNDRV_CTL_EVENT_MASK_VALUE
	.no_dead_strip	_snd_echo_digital_mode_put
.subsections_via_symbols
