	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function msm_ioctl_gem_cpu_prep
_msm_ioctl_gem_cpu_prep:                ## @msm_ioctl_gem_cpu_prep
	.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
	subq	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdx, %r14
	movq	%rsi, %rbx
	movl	8(%rsi), %edi
	callq	_to_ktime
	movl	%eax, -20(%rbp)
	movl	(%rbx), %esi
	movq	_MSM_PREP_FLAGS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	notl	%eax
	testl	%eax, %esi
	je	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rdi
	callq	_DRM_ERROR
	movq	_EINVAL@GOTPCREL(%rip), %rax
LBB0_4:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_6
LBB0_2:
	movl	4(%rbx), %esi
	movq	%r14, %rdi
	callq	_drm_gem_object_lookup
	testq	%rax, %rax
	je	LBB0_3
## %bb.5:
	movq	%rax, %r14
	movl	(%rbx), %esi
	leaq	-20(%rbp), %rdx
	movq	%rax, %rdi
	callq	_msm_gem_cpu_prep
	movl	%eax, %ebx
	movq	%r14, %rdi
	callq	_drm_gem_object_put_unlocked
LBB0_6:
	movl	%ebx, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_3:
	movq	_ENOENT@GOTPCREL(%rip), %rax
	jmp	LBB0_4
	.cfi_endproc
                                        ## -- End function
	.comm	_MSM_PREP_FLAGS,4,2             ## @MSM_PREP_FLAGS
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"invalid op: %08x\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_ENOENT,4,2                     ## @ENOENT
	.no_dead_strip	_msm_ioctl_gem_cpu_prep
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function msm_ioctl_gem_cpu_prep
_msm_ioctl_gem_cpu_prep:                ; @msm_ioctl_gem_cpu_prep
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	mov	x20, x2
	mov	x19, x1
	ldr	w0, [x1, #8]
	bl	_to_ktime
	str	w0, [sp, #12]
	ldr	w1, [x19]
Lloh0:
	adrp	x8, _MSM_PREP_FLAGS@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MSM_PREP_FLAGS@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	bics	wzr, w1, w8
	b.eq	LBB0_3
; %bb.1:
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_ERROR
Lloh5:
	adrp	x8, _EINVAL@GOTPAGE
Lloh6:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_2:
	ldr	w8, [x8]
	neg	w19, w8
	b	LBB0_5
LBB0_3:
	ldr	w1, [x19, #4]
	mov	x0, x20
	bl	_drm_gem_object_lookup
	cbz	x0, LBB0_6
; %bb.4:
	mov	x20, x0
	ldr	w1, [x19]
	add	x2, sp, #12
	bl	_msm_gem_cpu_prep
	mov	x19, x0
	mov	x0, x20
	bl	_drm_gem_object_put_unlocked
LBB0_5:
	mov	x0, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
LBB0_6:
Lloh7:
	adrp	x8, _ENOENT@GOTPAGE
Lloh8:
	ldr	x8, [x8, _ENOENT@GOTPAGEOFF]
	b	LBB0_2
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_MSM_PREP_FLAGS,4,2             ; @MSM_PREP_FLAGS
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"invalid op: %08x\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_ENOENT,4,2                     ; @ENOENT
	.no_dead_strip	_msm_ioctl_gem_cpu_prep
.subsections_via_symbols
