	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_armada_fb_create               ## -- Begin function armada_fb_create
	.p2align	4, 0x90
_armada_fb_create:                      ## @armada_fb_create
	.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, %rbx
	movq	%rsi, %r15
	movq	%rdi, %r14
	movq	%rdx, %rsi
	callq	_drm_get_format_info
	movq	%rax, %r12
	movl	28(%rbx), %esi
	movl	24(%rbx), %edx
	movl	20(%rbx), %ecx
	movl	16(%rbx), %r8d
	movq	8(%rbx), %rax
	movl	(%rax), %r9d
	movl	4(%rax), %r10d
	movl	8(%rax), %eax
	leaq	L_.str(%rip), %rdi
	pushq	%rax
	pushq	%r10
	callq	_DRM_DEBUG_DRIVER
	addq	$16, %rsp
	cmpl	$2, (%r12)
	movq	(%rbx), %rax
	movq	(%rax), %rsi
	jl	LBB0_5
## %bb.1:
	cmpq	8(%rax), %rsi
	jne	LBB0_3
## %bb.2:
	cmpq	16(%rax), %rsi
	jne	LBB0_3
LBB0_5:
	movq	%r15, %rdi
	callq	_armada_gem_object_lookup
	testq	%rax, %rax
	je	LBB0_6
## %bb.7:
	movq	%rax, %r15
	cmpq	$0, (%rax)
	je	LBB0_10
## %bb.8:
	cmpl	$0, 12(%r15)
	je	LBB0_9
LBB0_10:
	cmpl	$0, 8(%r15)
	je	LBB0_11
## %bb.13:
	movq	%r14, %rdi
	movq	%rbx, %rsi
	movq	%r15, %rdx
	callq	_armada_framebuffer_create
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_16
## %bb.14:
	movq	%rbx, %rdi
	callq	_PTR_ERR
	movl	%eax, %r12d
	jmp	LBB0_15
LBB0_3:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_6:
	movq	_ENOENT@GOTPCREL(%rip), %rax
LBB0_4:
	xorl	%r12d, %r12d
	subl	(%rax), %r12d
	jmp	LBB0_15
LBB0_11:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%r12d, %r12d
	subl	(%rax), %r12d
	jmp	LBB0_12
LBB0_9:
	movq	%r15, %rdi
	callq	_armada_gem_map_import
	movl	%eax, %r12d
	testl	%eax, %eax
	je	LBB0_10
LBB0_12:
	movq	%r15, %rdi
	callq	_drm_gem_object_put_unlocked
LBB0_15:
	leaq	L_.str.1(%rip), %rdi
	movl	%r12d, %esi
	callq	_DRM_ERROR
	movl	%r12d, %edi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ERR_PTR                        ## TAILCALL
LBB0_16:
	movq	%r15, %rdi
	callq	_drm_gem_object_put_unlocked
	movq	%rbx, %rax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"w%u h%u pf%08x f%u p%u,%u,%u\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_ENOENT,4,2                     ## @ENOENT
L_.str.1:                               ## @.str.1
	.asciz	"failed to initialize framebuffer: %d\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_armada_fb_create               ; -- Begin function armada_fb_create
	.p2align	2
_armada_fb_create:                      ; @armada_fb_create
	.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	x19, x2
	mov	x21, x1
	mov	x20, x0
	mov	x1, x2
	bl	_drm_get_format_info
	mov	x22, x0
	ldp	w2, w1, [x19, #24]
	ldp	w4, w3, [x19, #16]
	ldr	x8, [x19, #8]
	ldp	w5, w6, [x8]
	ldr	w7, [x8, #8]
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_DEBUG_DRIVER
	ldr	w9, [x22]
	ldr	x8, [x19]
	ldr	x1, [x8]
	cmp	w9, #2
	b.lt	LBB0_3
; %bb.1:
	ldr	x9, [x8, #8]
	cmp	x1, x9
	b.ne	LBB0_9
; %bb.2:
	ldr	x8, [x8, #16]
	cmp	x1, x8
	b.ne	LBB0_9
LBB0_3:
	mov	x0, x21
	bl	_armada_gem_object_lookup
	cbz	x0, LBB0_10
; %bb.4:
	mov	x21, x0
	ldr	x8, [x0]
	cbz	x8, LBB0_6
; %bb.5:
	ldr	w8, [x21, #12]
	cbz	w8, LBB0_13
LBB0_6:
	ldr	w8, [x21, #8]
	cbz	w8, LBB0_12
; %bb.7:
	mov	x0, x20
	mov	x1, x19
	mov	x2, x21
	bl	_armada_framebuffer_create
	mov	x19, x0
	bl	_IS_ERR
	cbz	x0, LBB0_16
; %bb.8:
	mov	x0, x19
	bl	_PTR_ERR
	mov	x22, x0
	b	LBB0_15
LBB0_9:
Lloh2:
	adrp	x8, _EINVAL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_11
LBB0_10:
Lloh4:
	adrp	x8, _ENOENT@GOTPAGE
Lloh5:
	ldr	x8, [x8, _ENOENT@GOTPAGEOFF]
LBB0_11:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_15
LBB0_12:
Lloh6:
	adrp	x8, _EINVAL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_14
LBB0_13:
	mov	x0, x21
	bl	_armada_gem_map_import
	mov	x22, x0
	cbz	w0, LBB0_6
LBB0_14:
	mov	x0, x21
	bl	_drm_gem_object_put_unlocked
LBB0_15:
Lloh9:
	adrp	x0, l_.str.1@PAGE
Lloh10:
	add	x0, x0, l_.str.1@PAGEOFF
	mov	x1, x22
	bl	_DRM_ERROR
	mov	x0, x22
	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	_ERR_PTR
LBB0_16:
	mov	x0, x21
	bl	_drm_gem_object_put_unlocked
	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
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"w%u h%u pf%08x f%u p%u,%u,%u\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_ENOENT,4,2                     ; @ENOENT
l_.str.1:                               ; @.str.1
	.asciz	"failed to initialize framebuffer: %d\n"

.subsections_via_symbols
