	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function iommu_domain_identity_map
_iommu_domain_identity_map:             ## @iommu_domain_identity_map
	.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	%r13
	pushq	%r12
	pushq	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	_VTD_PAGE_SHIFT@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	movq	%rsi, -48(%rbp)                 ## 8-byte Spill
	shrq	%cl, %r14
	movq	%rdx, %r13
	movq	%rdi, %r12
	movq	%rdx, %rbx
	shrq	%cl, %rbx
	movq	%r14, %rdi
	callq	_dma_to_mm_pfn
	movl	%eax, %r15d
	movq	%rbx, %rdi
	callq	_dma_to_mm_pfn
	movq	%r12, -56(%rbp)                 ## 8-byte Spill
	movq	%r12, %rdi
	movl	%r15d, %esi
	movl	%eax, %edx
	callq	_reserve_iova
	testl	%eax, %eax
	je	LBB0_1
## %bb.2:
	leaq	L_.str.1(%rip), %rdi
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	movq	%r13, %rdx
	callq	_pr_debug
	movq	-56(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rdi
	movq	%r14, %rsi
	movq	%rbx, %rdx
	callq	_dma_pte_clear_range
	subq	%r14, %rbx
	incq	%rbx
	movq	_DMA_PTE_READ@GOTPCREL(%rip), %rax
	movq	_DMA_PTE_WRITE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r9d
	orl	(%rax), %r9d
	movq	%r15, %rdi
	movq	%r14, %rsi
	xorl	%edx, %edx
	movq	%r14, %rcx
	movq	%rbx, %r8
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	___domain_mapping               ## TAILCALL
LBB0_1:
	leaq	L_.str(%rip), %rdi
	callq	_pr_err
	movq	_ENOMEM@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_VTD_PAGE_SHIFT,8,3             ## @VTD_PAGE_SHIFT
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Reserving iova failed\n"

	.comm	_ENOMEM,4,2                     ## @ENOMEM
L_.str.1:                               ## @.str.1
	.asciz	"Mapping reserved region %llx-%llx\n"

	.comm	_DMA_PTE_READ,4,2               ## @DMA_PTE_READ
	.comm	_DMA_PTE_WRITE,4,2              ## @DMA_PTE_WRITE
	.no_dead_strip	_iommu_domain_identity_map
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function iommu_domain_identity_map
_iommu_domain_identity_map:             ; @iommu_domain_identity_map
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x22, x2
	mov	x23, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _VTD_PAGE_SHIFT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _VTD_PAGE_SHIFT@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	lsr	x20, x1, x8
	lsr	x21, x2, x8
	mov	x0, x20
	bl	_dma_to_mm_pfn
	mov	x24, x0
	mov	x0, x21
	bl	_dma_to_mm_pfn
	mov	x2, x0
	mov	x0, x19
	mov	x1, x24
	bl	_reserve_iova
	cbz	w0, LBB0_2
; %bb.1:
Lloh3:
	adrp	x0, l_.str.1@PAGE
Lloh4:
	add	x0, x0, l_.str.1@PAGEOFF
	mov	x1, x23
	mov	x2, x22
	bl	_pr_debug
	mov	x0, x19
	mov	x1, x20
	mov	x2, x21
	bl	_dma_pte_clear_range
	sub	x8, x21, x20
Lloh5:
	adrp	x9, _DMA_PTE_READ@GOTPAGE
Lloh6:
	ldr	x9, [x9, _DMA_PTE_READ@GOTPAGEOFF]
	add	x4, x8, #1
Lloh7:
	ldr	w8, [x9]
Lloh8:
	adrp	x9, _DMA_PTE_WRITE@GOTPAGE
Lloh9:
	ldr	x9, [x9, _DMA_PTE_WRITE@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
	orr	w5, w9, w8
	mov	x0, x19
	mov	x1, x20
	mov	x2, #0
	mov	x3, x20
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	___domain_mapping
LBB0_2:
Lloh11:
	adrp	x0, l_.str@PAGE
Lloh12:
	add	x0, x0, l_.str@PAGEOFF
	bl	_pr_err
Lloh13:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh14:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	neg	w0, w8
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpAdd	Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_VTD_PAGE_SHIFT,8,3             ; @VTD_PAGE_SHIFT
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Reserving iova failed\n"

	.comm	_ENOMEM,4,2                     ; @ENOMEM
l_.str.1:                               ; @.str.1
	.asciz	"Mapping reserved region %llx-%llx\n"

	.comm	_DMA_PTE_READ,4,2               ; @DMA_PTE_READ
	.comm	_DMA_PTE_WRITE,4,2              ; @DMA_PTE_WRITE
	.no_dead_strip	_iommu_domain_identity_map
.subsections_via_symbols
