	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function snd_harmony_playback_prepare
_snd_harmony_playback_prepare:          ## @snd_harmony_playback_prepare
	.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, %r14
	callq	_snd_pcm_substream_chip
	cmpq	$0, 48(%rax)
	je	LBB0_2
## %bb.1:
	movq	_EBUSY@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
	jmp	LBB0_8
LBB0_2:
	movq	%rax, %rbx
	movq	(%r14), %r15
	movq	%r14, %rdi
	callq	_snd_pcm_lib_buffer_bytes
	movq	%rax, (%rbx)
	movq	%r14, %rdi
	callq	_snd_pcm_lib_period_bytes
	movl	%eax, 20(%rbx)
	movq	8(%rbx), %rax
	cmpq	(%rbx), %rax
	jl	LBB0_4
## %bb.3:
	movq	$0, 8(%rbx)
LBB0_4:
	movq	$0, 40(%rbx)
	movl	12(%r15), %edi
	callq	_snd_harmony_rate_bits
	movl	%eax, 32(%rbx)
	movl	8(%r15), %esi
	xorl	%r14d, %r14d
	movq	%rbx, %rdi
	xorl	%edx, %edx
	callq	_snd_harmony_set_data_format
	movl	%eax, 28(%rbx)
	cmpl	$2, (%r15)
	jne	LBB0_5
## %bb.6:
	movq	_HARMONY_SS_STEREO@GOTPCREL(%rip), %rax
	jmp	LBB0_7
LBB0_5:
	movq	_HARMONY_SS_MONO@GOTPCREL(%rip), %rax
LBB0_7:
	movl	(%rax), %eax
	movl	%eax, 24(%rbx)
	movq	%rbx, %rdi
	callq	_harmony_set_control
	movl	4(%r15), %eax
	movl	%eax, 16(%rbx)
LBB0_8:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EBUSY,4,2                      ## @EBUSY
	.comm	_HARMONY_SS_STEREO,4,2          ## @HARMONY_SS_STEREO
	.comm	_HARMONY_SS_MONO,4,2            ## @HARMONY_SS_MONO
	.no_dead_strip	_snd_harmony_playback_prepare
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function snd_harmony_playback_prepare
_snd_harmony_playback_prepare:          ; @snd_harmony_playback_prepare
	.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, x0
	bl	_snd_pcm_substream_chip
	ldr	x8, [x0, #48]
	cbz	x8, LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _EBUSY@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_5
LBB0_2:
	mov	x19, x0
	ldr	x21, [x20]
	mov	x0, x20
	bl	_snd_pcm_lib_buffer_bytes
	str	x0, [x19]
	mov	x0, x20
	bl	_snd_pcm_lib_period_bytes
	str	w0, [x19, #20]
	ldp	x9, x8, [x19]
	cmp	x8, x9
	b.lt	LBB0_4
; %bb.3:
	str	xzr, [x19, #8]
LBB0_4:
	str	xzr, [x19, #40]
	ldr	w0, [x21, #12]
	bl	_snd_harmony_rate_bits
	str	w0, [x19, #32]
	ldr	w1, [x21, #8]
	mov	x0, x19
	mov	w2, #0
	bl	_snd_harmony_set_data_format
	str	w0, [x19, #28]
	ldr	w8, [x21]
Lloh3:
	adrp	x9, _HARMONY_SS_STEREO@GOTPAGE
Lloh4:
	ldr	x9, [x9, _HARMONY_SS_STEREO@GOTPAGEOFF]
Lloh5:
	adrp	x10, _HARMONY_SS_MONO@GOTPAGE
Lloh6:
	ldr	x10, [x10, _HARMONY_SS_MONO@GOTPAGEOFF]
	cmp	w8, #2
	csel	x8, x9, x10, eq
	ldr	w8, [x8]
	str	w8, [x19, #24]
	mov	x0, x19
	bl	_harmony_set_control
	mov	w0, #0
	ldr	w8, [x21, #4]
	str	w8, [x19, #16]
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 AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_EBUSY,4,2                      ; @EBUSY
	.comm	_HARMONY_SS_STEREO,4,2          ; @HARMONY_SS_STEREO
	.comm	_HARMONY_SS_MONO,4,2            ; @HARMONY_SS_MONO
	.no_dead_strip	_snd_harmony_playback_prepare
.subsections_via_symbols
