	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function domain_prepare_identity_map
_domain_prepare_identity_map:           ## @domain_prepare_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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %r15
	movq	%rdx, %r14
	movq	%rsi, %rbx
	movq	_si_domain@GOTPCREL(%rip), %rax
	cmpq	%rsi, (%rax)
	jne	LBB0_4
## %bb.1:
	movq	_hw_pass_through@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_4
## %bb.2:
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdx
	movq	%r15, %rcx
	callq	_dev_warn
	xorl	%ebx, %ebx
	jmp	LBB0_3
LBB0_4:
	leaq	L_.str.1(%rip), %rsi
	movq	%r14, %rdx
	movq	%r15, %rcx
	callq	_dev_info
	cmpq	%r14, %r15
	jae	LBB0_7
## %bb.5:
	movq	_DMI_BIOS_VENDOR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_dmi_get_system_info
	movslq	%eax, %r14
	movq	_DMI_BIOS_VERSION@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_dmi_get_system_info
	movl	%eax, %r15d
	movq	_DMI_PRODUCT_VERSION@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_dmi_get_system_info
	leaq	L_.str.2(%rip), %rsi
	xorl	%ebx, %ebx
	movl	$1, %edi
	movq	%r14, %rdx
	movl	%r15d, %ecx
	movl	%eax, %r8d
	xorl	%eax, %eax
	callq	_WARN
	jmp	LBB0_6
LBB0_7:
	movl	(%rbx), %edi
	callq	_agaw_to_width
	movq	%r15, %rdx
	movl	%eax, %ecx
	shrq	%cl, %rdx
	testq	%rdx, %rdx
	je	LBB0_9
## %bb.8:
	movl	(%rbx), %edi
	callq	_agaw_to_width
	movq	%rax, %r14
	movq	_DMI_BIOS_VENDOR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_dmi_get_system_info
	movl	%eax, %r15d
	movq	_DMI_BIOS_VERSION@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_dmi_get_system_info
	movl	%eax, %r12d
	movq	_DMI_PRODUCT_VERSION@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_dmi_get_system_info
	leaq	L_.str.3(%rip), %rsi
	xorl	%ebx, %ebx
	movl	$1, %edi
	movq	%r14, %rdx
	movl	%r15d, %ecx
	movl	%r12d, %r8d
	movl	%eax, %r9d
	xorl	%eax, %eax
	callq	_WARN
LBB0_6:
	movq	_EIO@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
LBB0_3:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_9:
	movq	%rbx, %rdi
	movq	%r14, %rsi
	movq	%r15, %rdx
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_iommu_domain_identity_map      ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_si_domain,8,3                  ## @si_domain
	.comm	_hw_pass_through,8,3            ## @hw_pass_through
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Ignoring identity map for HW passthrough [0x%Lx - 0x%Lx]\n"

L_.str.1:                               ## @.str.1
	.asciz	"Setting identity map [0x%Lx - 0x%Lx]\n"

L_.str.2:                               ## @.str.2
	.asciz	"Your BIOS is broken; RMRR ends before it starts!\nBIOS vendor: %s; Ver: %s; Product Version: %s\n"

	.comm	_DMI_BIOS_VENDOR,4,2            ## @DMI_BIOS_VENDOR
	.comm	_DMI_BIOS_VERSION,4,2           ## @DMI_BIOS_VERSION
	.comm	_DMI_PRODUCT_VERSION,4,2        ## @DMI_PRODUCT_VERSION
	.comm	_EIO,4,2                        ## @EIO
L_.str.3:                               ## @.str.3
	.asciz	"Your BIOS is broken; RMRR exceeds permitted address width (%d bits)\nBIOS vendor: %s; Ver: %s; Product Version: %s\n"

	.no_dead_strip	_domain_prepare_identity_map
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function domain_prepare_identity_map
_domain_prepare_identity_map:           ; @domain_prepare_identity_map
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x19, x3
	mov	x20, x2
Lloh0:
	adrp	x8, _si_domain@GOTPAGE
Lloh1:
	ldr	x8, [x8, _si_domain@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
Lloh3:
	adrp	x9, _hw_pass_through@GOTPAGE
Lloh4:
	ldr	x9, [x9, _hw_pass_through@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x8, x1
	ccmp	x9, #0, #4, eq
	b.ne	LBB0_3
; %bb.1:
	mov	x21, x1
Lloh6:
	adrp	x1, l_.str.1@PAGE
Lloh7:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x2, x20
	mov	x3, x19
	bl	_dev_info
	cmp	x19, x20
	b.hs	LBB0_4
; %bb.2:
Lloh8:
	adrp	x8, _DMI_BIOS_VENDOR@GOTPAGE
Lloh9:
	ldr	x8, [x8, _DMI_BIOS_VENDOR@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
	bl	_dmi_get_system_info
                                        ; kill: def $w0 killed $w0 def $x0
	sxtw	x19, w0
Lloh11:
	adrp	x8, _DMI_BIOS_VERSION@GOTPAGE
Lloh12:
	ldr	x8, [x8, _DMI_BIOS_VERSION@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
	bl	_dmi_get_system_info
	mov	x20, x0
Lloh14:
	adrp	x8, _DMI_PRODUCT_VERSION@GOTPAGE
Lloh15:
	ldr	x8, [x8, _DMI_PRODUCT_VERSION@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x8]
	bl	_dmi_get_system_info
	mov	x4, x0
Lloh17:
	adrp	x1, l_.str.2@PAGE
Lloh18:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	w0, #1
	mov	x2, x19
	mov	x3, x20
	b	LBB0_6
LBB0_3:
Lloh19:
	adrp	x1, l_.str@PAGE
Lloh20:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x20
	mov	x3, x19
	bl	_dev_warn
	mov	w0, #0
	b	LBB0_7
LBB0_4:
	ldr	w0, [x21]
	bl	_agaw_to_width
	lsr	x8, x19, x0
	cbz	x8, LBB0_8
; %bb.5:
	ldr	w0, [x21]
	bl	_agaw_to_width
	mov	x19, x0
Lloh21:
	adrp	x8, _DMI_BIOS_VENDOR@GOTPAGE
Lloh22:
	ldr	x8, [x8, _DMI_BIOS_VENDOR@GOTPAGEOFF]
Lloh23:
	ldr	w0, [x8]
	bl	_dmi_get_system_info
	mov	x20, x0
Lloh24:
	adrp	x8, _DMI_BIOS_VERSION@GOTPAGE
Lloh25:
	ldr	x8, [x8, _DMI_BIOS_VERSION@GOTPAGEOFF]
Lloh26:
	ldr	w0, [x8]
	bl	_dmi_get_system_info
	mov	x21, x0
Lloh27:
	adrp	x8, _DMI_PRODUCT_VERSION@GOTPAGE
Lloh28:
	ldr	x8, [x8, _DMI_PRODUCT_VERSION@GOTPAGEOFF]
Lloh29:
	ldr	w0, [x8]
	bl	_dmi_get_system_info
                                        ; kill: def $w0 killed $w0 def $x0
Lloh30:
	adrp	x1, l_.str.3@PAGE
Lloh31:
	add	x1, x1, l_.str.3@PAGEOFF
	str	x0, [sp]
	mov	w0, #1
	mov	x2, x19
	mov	x3, x20
	mov	x4, x21
LBB0_6:
	bl	_WARN
Lloh32:
	adrp	x8, _EIO@GOTPAGE
Lloh33:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh34:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_7:
	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
	add	sp, sp, #64
	ret
LBB0_8:
	mov	x0, x21
	mov	x1, x20
	mov	x2, x19
	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
	add	sp, sp, #64
	b	_iommu_domain_identity_map
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.cfi_endproc
                                        ; -- End function
	.comm	_si_domain,8,3                  ; @si_domain
	.comm	_hw_pass_through,8,3            ; @hw_pass_through
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Ignoring identity map for HW passthrough [0x%Lx - 0x%Lx]\n"

l_.str.1:                               ; @.str.1
	.asciz	"Setting identity map [0x%Lx - 0x%Lx]\n"

l_.str.2:                               ; @.str.2
	.asciz	"Your BIOS is broken; RMRR ends before it starts!\nBIOS vendor: %s; Ver: %s; Product Version: %s\n"

	.comm	_DMI_BIOS_VENDOR,4,2            ; @DMI_BIOS_VENDOR
	.comm	_DMI_BIOS_VERSION,4,2           ; @DMI_BIOS_VERSION
	.comm	_DMI_PRODUCT_VERSION,4,2        ; @DMI_PRODUCT_VERSION
	.comm	_EIO,4,2                        ; @EIO
l_.str.3:                               ; @.str.3
	.asciz	"Your BIOS is broken; RMRR exceeds permitted address width (%d bits)\nBIOS vendor: %s; Ver: %s; Product Version: %s\n"

	.no_dead_strip	_domain_prepare_identity_map
.subsections_via_symbols
