	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function drm_client_buffer_addfb
_drm_client_buffer_addfb:               ## @drm_client_buffer_addfb
	.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
	subq	$48, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r14
	movq	%rsi, %r15
	movq	%rdi, %rbx
	movq	8(%rdi), %r12
	xorps	%xmm0, %xmm0
	movaps	%xmm0, -64(%rbp)
	movaps	%xmm0, -80(%rbp)
	movq	$0, -48(%rbp)
	movq	%rcx, %rdi
	callq	_drm_format_info
	movq	(%rax), %rcx
	movl	(%rcx), %ecx
	shll	$3, %ecx
	movl	%ecx, -80(%rbp)
	movl	8(%rax), %eax
	movl	%eax, -48(%rbp)
	movq	%r15, -56(%rbp)
	movq	%r14, -64(%rbp)
	movl	20(%rbx), %eax
	movl	%eax, -68(%rbp)
	movl	16(%rbx), %eax
	movl	%eax, -72(%rbp)
	movl	4(%r12), %edx
	movl	8(%r12), %edi
	leaq	-80(%rbp), %rsi
	callq	_drm_mode_addfb
	testl	%eax, %eax
	jne	LBB0_4
## %bb.1:
	movl	8(%r12), %edi
	movq	8(%rbx), %rax
	movl	4(%rax), %esi
	movl	-76(%rbp), %edx
	callq	_drm_framebuffer_lookup
	movq	%rax, (%rbx)
	xorl	%edi, %edi
	testq	%rax, %rax
	sete	%dil
	callq	_WARN_ON
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	movq	_ENOENT@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_4
LBB0_3:
	movq	(%rbx), %rdi
	callq	_drm_framebuffer_put
	movq	(%rbx), %rax
	movl	(%rax), %edi
	movl	(%r12), %esi
	movq	_TASK_COMM_LEN@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_strscpy
	xorl	%eax, %eax
LBB0_4:
	addq	$48, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOENT,4,2                     ## @ENOENT
	.comm	_TASK_COMM_LEN,4,2              ## @TASK_COMM_LEN
	.no_dead_strip	_drm_client_buffer_addfb
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function drm_client_buffer_addfb
_drm_client_buffer_addfb:               ; @drm_client_buffer_addfb
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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	x21, x1
	mov	x19, x0
	ldr	x22, [x0, #8]
	str	xzr, [sp, #32]
	movi.2d	v0, #0000000000000000
	stp	q0, q0, [sp]
	mov	x0, x3
	bl	_drm_format_info
	ldr	x8, [x0]
	ldr	w8, [x8]
	lsl	w8, w8, #3
	str	w8, [sp]
	ldr	w8, [x0, #8]
	str	w8, [sp, #32]
	stp	x20, x21, [sp, #16]
	ldr	d0, [x19, #16]
	str	d0, [sp, #8]
	ldp	w2, w0, [x22, #4]
	mov	x1, sp
	bl	_drm_mode_addfb
	cbnz	w0, LBB0_4
; %bb.1:
	ldr	w0, [x22, #8]
	ldr	x8, [x19, #8]
	ldr	w1, [x8, #4]
	ldr	w2, [sp, #4]
	bl	_drm_framebuffer_lookup
	str	x0, [x19]
	cmp	x0, #0
	cset	w0, eq
	bl	_WARN_ON
	cbz	x0, LBB0_3
; %bb.2:
Lloh0:
	adrp	x8, _ENOENT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ENOENT@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_4
LBB0_3:
	ldr	x0, [x19]
	bl	_drm_framebuffer_put
	ldr	x8, [x19]
	ldr	w0, [x8]
	ldr	w1, [x22]
Lloh3:
	adrp	x8, _TASK_COMM_LEN@GOTPAGE
Lloh4:
	ldr	x8, [x8, _TASK_COMM_LEN@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	bl	_strscpy
	mov	w0, #0
LBB0_4:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOENT,4,2                     ; @ENOENT
	.comm	_TASK_COMM_LEN,4,2              ; @TASK_COMM_LEN
	.no_dead_strip	_drm_client_buffer_addfb
.subsections_via_symbols
