	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function snd_hammerfall_get_buffer
_snd_hammerfall_get_buffer:             ## @snd_hammerfall_get_buffer
	.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	%rdx, %r14
	movq	%rsi, %rbx
	movq	%rdi, %r15
	movq	_SNDRV_DMA_TYPE_DEV@GOTPCREL(%rip), %r12
	movl	(%r12), %eax
	movl	%eax, 12(%rsi)
	callq	_snd_dma_pci_data
	movl	%eax, 8(%rbx)
	movq	%r15, %rdi
	callq	_snd_dma_pci_buf_id
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_snd_dma_get_reserved_buf
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	xorl	%eax, %eax
	cmpq	%r14, (%rbx)
	jae	LBB0_4
LBB0_2:
	movl	(%r12), %r12d
	movq	%r15, %rdi
	callq	_snd_dma_pci_data
	movl	%r12d, %edi
	movl	%eax, %esi
	movq	%r14, %rdx
	movq	%rbx, %rcx
	callq	_snd_dma_alloc_pages
	movq	%rax, %rcx
	xorl	%eax, %eax
	testq	%rcx, %rcx
	jns	LBB0_4
## %bb.3:
	movq	_ENOMEM@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_4:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SNDRV_DMA_TYPE_DEV,4,2         ## @SNDRV_DMA_TYPE_DEV
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.no_dead_strip	_snd_hammerfall_get_buffer
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function snd_hammerfall_get_buffer
_snd_hammerfall_get_buffer:             ; @snd_hammerfall_get_buffer
	.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, x2
	mov	x19, x1
	mov	x21, x0
Lloh0:
	adrp	x22, _SNDRV_DMA_TYPE_DEV@GOTPAGE
Lloh1:
	ldr	x22, [x22, _SNDRV_DMA_TYPE_DEV@GOTPAGEOFF]
	ldr	w8, [x22]
	str	w8, [x1, #12]
	bl	_snd_dma_pci_data
	str	w0, [x19, #8]
	mov	x0, x21
	bl	_snd_dma_pci_buf_id
	mov	x1, x0
	mov	x0, x19
	bl	_snd_dma_get_reserved_buf
	cbz	x0, LBB0_2
; %bb.1:
	ldr	x8, [x19]
	cmp	x8, x20
	b.hs	LBB0_3
LBB0_2:
	ldr	w22, [x22]
	mov	x0, x21
	bl	_snd_dma_pci_data
	mov	x1, x0
	mov	x0, x22
	mov	x2, x20
	mov	x3, x19
	bl	_snd_dma_alloc_pages
	tbnz	x0, #63, LBB0_4
LBB0_3:
	mov	w0, #0
	b	LBB0_5
LBB0_4:
Lloh2:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh3:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	neg	w0, w8
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 AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_SNDRV_DMA_TYPE_DEV,4,2         ; @SNDRV_DMA_TYPE_DEV
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.no_dead_strip	_snd_hammerfall_get_buffer
.subsections_via_symbols
