	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_etnaviv_buffer_init            ## -- Begin function etnaviv_buffer_init
	.p2align	4, 0x90
_etnaviv_buffer_init:                   ## @etnaviv_buffer_init
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	leaq	12(%rdi), %r14
	addq	$8, %rdi
	callq	_lockdep_assert_held
	movl	$0, 12(%rbx)
	movq	%r14, %rdi
	callq	_CMD_WAIT
	movq	(%rbx), %rsi
	movq	%r14, %rdi
	callq	_etnaviv_cmdbuf_get_va
	movslq	12(%rbx), %rcx
	leaq	(%rax,%rcx), %rdx
	addq	$-4, %rdx
	movq	%r14, %rdi
	movl	$2, %esi
	callq	_CMD_LINK
	movl	12(%rbx), %ecx
	leal	7(%rcx), %eax
	testl	%ecx, %ecx
	cmovnsl	%ecx, %eax
	sarl	$3, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_etnaviv_buffer_init            ; -- Begin function etnaviv_buffer_init
	.p2align	2
_etnaviv_buffer_init:                   ; @etnaviv_buffer_init
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	add	x0, x0, #8
	bl	_lockdep_assert_held
	mov	x20, x19
	str	wzr, [x20, #12]!
	mov	x0, x20
	bl	_CMD_WAIT
	ldr	x1, [x19]
	mov	x0, x20
	bl	_etnaviv_cmdbuf_get_va
	ldrsw	x8, [x20]
	add	x8, x0, x8
	sub	x2, x8, #4
	mov	x0, x20
	mov	w1, #2
	bl	_CMD_LINK
	ldr	w8, [x20]
	add	w9, w8, #7
	cmp	w8, #0
	csel	w8, w9, w8, lt
	asr	w0, w8, #3
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.cfi_endproc
                                        ; -- End function
.subsections_via_symbols
