	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ac97_aux_prepare
_ac97_aux_prepare:                      ## @ac97_aux_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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	8(%rdi), %rax
	movq	16(%rdi), %r15
	movq	(%rax), %rax
	movq	(%rax), %rax
	movq	(%rax), %rbx
	movq	_AC97_EXTENDED_STATUS@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movq	%rbx, %rdi
	callq	_ac97_read
	movl	(%r12), %esi
	orl	$1, %eax
	movq	%rbx, %rdi
	movl	%eax, %edx
	callq	_ac97_write
	movq	_AC97_PCI_SID@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movq	%rbx, %rdi
	callq	_ac97_read
	movl	(%r12), %esi
	orl	$32768, %eax                    ## imm = 0x8000
	movq	%rbx, %rdi
	movl	%eax, %edx
	callq	_ac97_write
	movq	(%r14), %rax
	movq	_SNDRV_PCM_STREAM_PLAYBACK@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_1
## %bb.2:
	movq	_AC97_PCM_SURR_DAC_RATE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	(%r15), %edx
	movq	%rbx, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ac97_write                     ## TAILCALL
LBB0_1:
	movq	_ENODEV@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AC97_EXTENDED_STATUS,4,2       ## @AC97_EXTENDED_STATUS
	.comm	_AC97_PCI_SID,4,2               ## @AC97_PCI_SID
	.comm	_SNDRV_PCM_STREAM_PLAYBACK,8,3  ## @SNDRV_PCM_STREAM_PLAYBACK
	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_AC97_PCM_SURR_DAC_RATE,4,2     ## @AC97_PCM_SURR_DAC_RATE
	.no_dead_strip	_ac97_aux_prepare
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ac97_aux_prepare
_ac97_aux_prepare:                      ; @ac97_aux_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
	ldp	x8, x21, [x0, #8]
	ldr	x8, [x8]
	ldr	x8, [x8]
	ldr	x19, [x8]
Lloh0:
	adrp	x22, _AC97_EXTENDED_STATUS@GOTPAGE
Lloh1:
	ldr	x22, [x22, _AC97_EXTENDED_STATUS@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x19
	bl	_ac97_read
	ldr	w1, [x22]
	orr	w2, w0, #0x1
	mov	x0, x19
	bl	_ac97_write
Lloh2:
	adrp	x22, _AC97_PCI_SID@GOTPAGE
Lloh3:
	ldr	x22, [x22, _AC97_PCI_SID@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x19
	bl	_ac97_read
	ldr	w1, [x22]
	orr	w2, w0, #0x8000
	mov	x0, x19
	bl	_ac97_write
	ldr	x8, [x20]
Lloh4:
	adrp	x9, _SNDRV_PCM_STREAM_PLAYBACK@GOTPAGE
Lloh5:
	ldr	x9, [x9, _SNDRV_PCM_STREAM_PLAYBACK@GOTPAGEOFF]
Lloh6:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_2
; %bb.1:
Lloh7:
	adrp	x8, _AC97_PCM_SURR_DAC_RATE@GOTPAGE
Lloh8:
	ldr	x8, [x8, _AC97_PCM_SURR_DAC_RATE@GOTPAGEOFF]
Lloh9:
	ldr	w1, [x8]
	ldr	w2, [x21]
	mov	x0, x19
	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	_ac97_write
LBB0_2:
Lloh10:
	adrp	x8, _ENODEV@GOTPAGE
Lloh11:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	neg	w0, w8
	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	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_AC97_EXTENDED_STATUS,4,2       ; @AC97_EXTENDED_STATUS
	.comm	_AC97_PCI_SID,4,2               ; @AC97_PCI_SID
	.comm	_SNDRV_PCM_STREAM_PLAYBACK,8,3  ; @SNDRV_PCM_STREAM_PLAYBACK
	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_AC97_PCM_SURR_DAC_RATE,4,2     ; @AC97_PCM_SURR_DAC_RATE
	.no_dead_strip	_ac97_aux_prepare
.subsections_via_symbols
