	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_intel_svm_enable_prq           ## -- Begin function intel_svm_enable_prq
	.p2align	4, 0x90
_intel_svm_enable_prq:                  ## @intel_svm_enable_prq
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movq	___GFP_ZERO@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	orl	(%rax), %edi
	movq	_PRQ_ORDER@GOTPCREL(%rip), %r13
	movq	(%r13), %rsi
	callq	_alloc_pages
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %rdi
	callq	_page_address
	movq	%rax, 8(%rbx)
	movq	_DMAR_UNITS_SUPPORTED@GOTPCREL(%rip), %rax
	movl	(%rbx), %edi
	movl	32(%rbx), %esi
	addl	(%rax), %edi
	movq	%rbx, %rdx
	callq	_dmar_alloc_hwirq
	testl	%eax, %eax
	jle	LBB0_3
## %bb.5:
	movl	%eax, %r15d
	movl	%eax, 4(%rbx)
	movl	(%rbx), %ecx
	movl	28(%rbx), %edi
	leaq	L_.str.2(%rip), %rdx
	movl	$4, %esi
	callq	_snprintf
	movq	_prq_event_thread@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_IRQF_ONESHOT@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	28(%rbx), %r8d
	xorl	%r14d, %r14d
	movl	%r15d, %edi
	xorl	%esi, %esi
	movq	%rbx, %r9
	callq	_request_threaded_irq
	testl	%eax, %eax
	je	LBB0_7
## %bb.6:
	movl	%eax, %r12d
	movl	24(%rbx), %esi
	leaq	L_.str.3(%rip), %rdi
	callq	_pr_err
	movl	%r15d, %edi
	callq	_dmar_free_hwirq
	movl	$0, 4(%rbx)
	movl	%r12d, %r14d
	jmp	LBB0_4
LBB0_1:
	movl	24(%rbx), %esi
	leaq	L_.str(%rip), %rdi
	callq	_pr_warn
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
	jmp	LBB0_8
LBB0_3:
	movl	24(%rbx), %esi
	leaq	L_.str.1(%rip), %rdi
	callq	_pr_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
LBB0_4:
	movq	8(%rbx), %rdi
	movq	(%r13), %rsi
	callq	_free_pages
	movq	$0, 8(%rbx)
	jmp	LBB0_8
LBB0_7:
	movq	_DMAR_PQH_REG@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	16(%rbx), %rdi
	xorl	%esi, %esi
	callq	_dmar_writeq
	movq	_DMAR_PQT_REG@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	16(%rbx), %rdi
	xorl	%esi, %esi
	callq	_dmar_writeq
	movq	_DMAR_PQA_REG@GOTPCREL(%rip), %rax
	movq	(%rax), %r15
	addq	16(%rbx), %r15
	movq	8(%rbx), %rdi
	callq	_virt_to_phys
	orq	(%r13), %rax
	movq	%r15, %rdi
	movq	%rax, %rsi
	callq	_dmar_writeq
LBB0_8:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	___GFP_ZERO,4,2                 ## @__GFP_ZERO
	.comm	_PRQ_ORDER,8,3                  ## @PRQ_ORDER
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"IOMMU: %s: Failed to allocate page request queue\n"

	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_DMAR_UNITS_SUPPORTED,4,2       ## @DMAR_UNITS_SUPPORTED
L_.str.1:                               ## @.str.1
	.asciz	"IOMMU: %s: Failed to create IRQ vector for page request queue\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
L_.str.2:                               ## @.str.2
	.asciz	"dmar%d-prq"

	.comm	_prq_event_thread,4,2           ## @prq_event_thread
	.comm	_IRQF_ONESHOT,4,2               ## @IRQF_ONESHOT
L_.str.3:                               ## @.str.3
	.asciz	"IOMMU: %s: Failed to request IRQ for page request queue\n"

	.comm	_DMAR_PQH_REG,8,3               ## @DMAR_PQH_REG
	.comm	_DMAR_PQT_REG,8,3               ## @DMAR_PQT_REG
	.comm	_DMAR_PQA_REG,8,3               ## @DMAR_PQA_REG
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_intel_svm_enable_prq           ; -- Begin function intel_svm_enable_prq
	.p2align	2
_intel_svm_enable_prq:                  ; @intel_svm_enable_prq
	.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, x0
Lloh0:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh2:
	adrp	x9, ___GFP_ZERO@GOTPAGE
Lloh3:
	ldr	x9, [x9, ___GFP_ZERO@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
Lloh5:
	ldr	w9, [x9]
	orr	w0, w9, w8
Lloh6:
	adrp	x22, _PRQ_ORDER@GOTPAGE
Lloh7:
	ldr	x22, [x22, _PRQ_ORDER@GOTPAGEOFF]
	ldr	x1, [x22]
	bl	_alloc_pages
	cbz	x0, LBB0_4
; %bb.1:
	bl	_page_address
	str	x0, [x19, #8]
Lloh8:
	adrp	x8, _DMAR_UNITS_SUPPORTED@GOTPAGE
Lloh9:
	ldr	x8, [x8, _DMAR_UNITS_SUPPORTED@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	ldr	w9, [x19]
	add	w0, w9, w8
	ldr	w1, [x19, #32]
	mov	x2, x19
	bl	_dmar_alloc_hwirq
	cmp	w0, #0
	b.le	LBB0_5
; %bb.2:
	mov	x20, x0
	str	w0, [x19, #4]
	ldr	w0, [x19, #28]
	ldr	w3, [x19]
Lloh11:
	adrp	x2, l_.str.2@PAGE
Lloh12:
	add	x2, x2, l_.str.2@PAGEOFF
	mov	w1, #4
	bl	_snprintf
Lloh13:
	adrp	x8, _prq_event_thread@GOTPAGE
Lloh14:
	ldr	x8, [x8, _prq_event_thread@GOTPAGEOFF]
Lloh15:
	ldr	w2, [x8]
Lloh16:
	adrp	x8, _IRQF_ONESHOT@GOTPAGE
Lloh17:
	ldr	x8, [x8, _IRQF_ONESHOT@GOTPAGEOFF]
Lloh18:
	ldr	w3, [x8]
	ldr	w4, [x19, #28]
	mov	x0, x20
	mov	x1, #0
	mov	x5, x19
	bl	_request_threaded_irq
	mov	x21, x0
	cbz	w0, LBB0_7
; %bb.3:
	ldr	w1, [x19, #24]
Lloh19:
	adrp	x0, l_.str.3@PAGE
Lloh20:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_pr_err
	mov	x0, x20
	bl	_dmar_free_hwirq
	str	wzr, [x19, #4]
	b	LBB0_6
LBB0_4:
	ldr	w1, [x19, #24]
Lloh21:
	adrp	x0, l_.str@PAGE
Lloh22:
	add	x0, x0, l_.str@PAGEOFF
	bl	_pr_warn
Lloh23:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh24:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh25:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_8
LBB0_5:
	ldr	w1, [x19, #24]
Lloh26:
	adrp	x0, l_.str.1@PAGE
Lloh27:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_pr_err
Lloh28:
	adrp	x8, _EINVAL@GOTPAGE
Lloh29:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh30:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_6:
	ldr	x0, [x19, #8]
	ldr	x1, [x22]
	bl	_free_pages
	str	xzr, [x19, #8]
	b	LBB0_8
LBB0_7:
	ldr	x8, [x19, #16]
Lloh31:
	adrp	x9, _DMAR_PQH_REG@GOTPAGE
Lloh32:
	ldr	x9, [x9, _DMAR_PQH_REG@GOTPAGEOFF]
Lloh33:
	ldr	x9, [x9]
	add	x0, x9, x8
	mov	x1, #0
	bl	_dmar_writeq
	ldr	x8, [x19, #16]
Lloh34:
	adrp	x9, _DMAR_PQT_REG@GOTPAGE
Lloh35:
	ldr	x9, [x9, _DMAR_PQT_REG@GOTPAGEOFF]
Lloh36:
	ldr	x9, [x9]
	add	x0, x9, x8
	mov	x1, #0
	bl	_dmar_writeq
Lloh37:
	adrp	x8, _DMAR_PQA_REG@GOTPAGE
Lloh38:
	ldr	x8, [x8, _DMAR_PQA_REG@GOTPAGEOFF]
Lloh39:
	ldr	x8, [x8]
	ldp	x0, x9, [x19, #8]
	add	x19, x8, x9
	bl	_virt_to_phys
	ldr	x8, [x22]
	orr	x1, x8, x0
	mov	x0, x19
	bl	_dmar_writeq
LBB0_8:
	mov	x0, x21
	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 AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh4
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	___GFP_ZERO,4,2                 ; @__GFP_ZERO
	.comm	_PRQ_ORDER,8,3                  ; @PRQ_ORDER
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"IOMMU: %s: Failed to allocate page request queue\n"

	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_DMAR_UNITS_SUPPORTED,4,2       ; @DMAR_UNITS_SUPPORTED
l_.str.1:                               ; @.str.1
	.asciz	"IOMMU: %s: Failed to create IRQ vector for page request queue\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
l_.str.2:                               ; @.str.2
	.asciz	"dmar%d-prq"

	.comm	_prq_event_thread,4,2           ; @prq_event_thread
	.comm	_IRQF_ONESHOT,4,2               ; @IRQF_ONESHOT
l_.str.3:                               ; @.str.3
	.asciz	"IOMMU: %s: Failed to request IRQ for page request queue\n"

	.comm	_DMAR_PQH_REG,8,3               ; @DMAR_PQH_REG
	.comm	_DMAR_PQT_REG,8,3               ; @DMAR_PQT_REG
	.comm	_DMAR_PQA_REG,8,3               ; @DMAR_PQA_REG
.subsections_via_symbols
