	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ttm_bo_add_ttm
_ttm_bo_add_ttm:                        ## @ttm_bo_add_ttm
	.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
	movl	%esi, %r15d
	movq	%rdi, %rbx
	movq	32(%rdi), %r12
	movq	40(%rdi), %r14
	addq	$24, %rdi
	callq	_TTM_ASSERT_LOCKED
	movq	$0, 16(%rbx)
	xorl	%edx, %edx
	cmpq	$0, 8(%r14)
	je	LBB0_2
## %bb.1:
	movq	_TTM_PAGE_FLAG_DMA32@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
LBB0_2:
	movl	(%rbx), %eax
	cmpl	$128, %eax
	je	LBB0_9
## %bb.3:
	cmpl	$129, %eax
	je	LBB0_7
## %bb.4:
	cmpl	$130, %eax
	jne	LBB0_12
## %bb.5:
	testl	%r15d, %r15d
	je	LBB0_7
## %bb.6:
	movq	_TTM_PAGE_FLAG_ZERO_ALLOC@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
LBB0_7:
	movq	(%r14), %rax
	movl	4(%rbx), %esi
	movq	_PAGE_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	shll	%cl, %esi
	movl	(%r12), %ecx
	movq	%r14, %rdi
	callq	*(%rax)
	movq	%rax, 16(%rbx)
	xorl	%edi, %edi
	testq	%rax, %rax
	sete	%dil
	callq	_unlikely
	testl	%eax, %eax
	jne	LBB0_10
## %bb.8:
	xorl	%eax, %eax
	jmp	LBB0_14
LBB0_9:
	movq	(%r14), %rax
	movl	4(%rbx), %esi
	movq	_PAGE_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	shll	%cl, %esi
	movq	_TTM_PAGE_FLAG_SG@GOTPCREL(%rip), %rcx
	orl	(%rcx), %edx
	movl	(%r12), %ecx
	movq	%r14, %rdi
	callq	*(%rax)
	movq	%rax, 16(%rbx)
	xorl	%edi, %edi
	testq	%rax, %rax
	sete	%dil
	callq	_unlikely
	testl	%eax, %eax
	je	LBB0_11
LBB0_10:
	movq	_ENOMEM@GOTPCREL(%rip), %rcx
	jmp	LBB0_13
LBB0_12:
	leaq	L_.str(%rip), %rdi
	callq	_pr_err
	movq	_EINVAL@GOTPCREL(%rip), %rcx
LBB0_13:
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_14:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_11:
	movl	8(%rbx), %eax
	movq	16(%rbx), %rcx
	movl	%eax, (%rcx)
	xorl	%eax, %eax
	jmp	LBB0_14
	.cfi_endproc
                                        ## -- End function
	.comm	_TTM_PAGE_FLAG_DMA32,4,2        ## @TTM_PAGE_FLAG_DMA32
	.comm	_TTM_PAGE_FLAG_ZERO_ALLOC,4,2   ## @TTM_PAGE_FLAG_ZERO_ALLOC
	.comm	_PAGE_SHIFT,4,2                 ## @PAGE_SHIFT
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_TTM_PAGE_FLAG_SG,4,2           ## @TTM_PAGE_FLAG_SG
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Illegal buffer object type\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_ttm_bo_add_ttm
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ttm_bo_add_ttm
_ttm_bo_add_ttm:                        ; @ttm_bo_add_ttm
	.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	x21, x1
	mov	x19, x0
	ldp	x22, x20, [x0, #32]
	add	x0, x0, #24
	bl	_TTM_ASSERT_LOCKED
	str	xzr, [x19, #16]
Lloh0:
	adrp	x8, _TTM_PAGE_FLAG_DMA32@GOTPAGE
Lloh1:
	ldr	x8, [x8, _TTM_PAGE_FLAG_DMA32@GOTPAGEOFF]
	ldr	x9, [x20, #8]
Lloh2:
	ldr	w8, [x8]
	cmp	x9, #0
	csel	w2, wzr, w8, eq
	ldr	w8, [x19]
	cmp	w8, #128
	b.eq	LBB0_6
; %bb.1:
	cmp	w8, #129
	b.eq	LBB0_5
; %bb.2:
	cmp	w8, #130
	b.ne	LBB0_8
; %bb.3:
	cbz	w21, LBB0_5
; %bb.4:
Lloh3:
	adrp	x8, _TTM_PAGE_FLAG_ZERO_ALLOC@GOTPAGE
Lloh4:
	ldr	x8, [x8, _TTM_PAGE_FLAG_ZERO_ALLOC@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	orr	w2, w8, w2
LBB0_5:
	ldr	x8, [x20]
	ldr	x8, [x8]
	ldr	w9, [x19, #4]
Lloh6:
	adrp	x10, _PAGE_SHIFT@GOTPAGE
Lloh7:
	ldr	x10, [x10, _PAGE_SHIFT@GOTPAGEOFF]
Lloh8:
	ldr	w10, [x10]
	lsl	w1, w9, w10
	ldr	w3, [x22]
	mov	x0, x20
	blr	x8
	str	x0, [x19, #16]
	cmp	x0, #0
	cset	w0, eq
	bl	_unlikely
	cbnz	w0, LBB0_7
	b	LBB0_10
LBB0_6:
	ldr	x8, [x20]
	ldr	x8, [x8]
	ldr	w9, [x19, #4]
Lloh9:
	adrp	x10, _PAGE_SHIFT@GOTPAGE
Lloh10:
	ldr	x10, [x10, _PAGE_SHIFT@GOTPAGEOFF]
Lloh11:
	ldr	w10, [x10]
	lsl	w1, w9, w10
Lloh12:
	adrp	x9, _TTM_PAGE_FLAG_SG@GOTPAGE
Lloh13:
	ldr	x9, [x9, _TTM_PAGE_FLAG_SG@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
	orr	w2, w9, w2
	ldr	w3, [x22]
	mov	x0, x20
	blr	x8
	str	x0, [x19, #16]
	cmp	x0, #0
	cset	w0, eq
	bl	_unlikely
	cbz	w0, LBB0_11
LBB0_7:
Lloh15:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh16:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_9
LBB0_8:
Lloh17:
	adrp	x0, l_.str@PAGE
Lloh18:
	add	x0, x0, l_.str@PAGEOFF
	bl	_pr_err
Lloh19:
	adrp	x8, _EINVAL@GOTPAGE
Lloh20:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_9:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_10:
	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
LBB0_11:
	ldr	w8, [x19, #8]
	ldr	x9, [x19, #16]
	str	w8, [x9]
	b	LBB0_10
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpAdd	Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_TTM_PAGE_FLAG_DMA32,4,2        ; @TTM_PAGE_FLAG_DMA32
	.comm	_TTM_PAGE_FLAG_ZERO_ALLOC,4,2   ; @TTM_PAGE_FLAG_ZERO_ALLOC
	.comm	_PAGE_SHIFT,4,2                 ; @PAGE_SHIFT
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_TTM_PAGE_FLAG_SG,4,2           ; @TTM_PAGE_FLAG_SG
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Illegal buffer object type\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_ttm_bo_add_ttm
.subsections_via_symbols
