	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function iommu_disable_irq_remapping
_iommu_disable_irq_remapping:           ## @iommu_disable_irq_remapping
	.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	%rdi, %rbx
	movl	20(%rdi), %edi
	callq	_ecap_ir_support
	testl	%eax, %eax
	je	LBB0_4
## %bb.1:
	movq	%rbx, %rdi
	callq	_qi_global_iec
	movq	%rbx, %rdi
	callq	_raw_spin_lock_irqsave
	movq	_DMAR_GSTS_REG@GOTPCREL(%rip), %r15
	movq	(%r15), %rdi
	addq	8(%rbx), %rdi
	callq	_readl
	movq	_DMA_GSTS_IRES@GOTPCREL(%rip), %r12
	testl	%eax, (%r12)
	je	LBB0_3
## %bb.2:
	movl	%eax, %r14d
	movq	_DMA_GCMD_IRE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	notl	%edi
	andl	16(%rbx), %edi
	movl	%edi, 16(%rbx)
	movq	_DMAR_GCMD_REG@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	8(%rbx), %rsi
	callq	_writel
	movq	(%r15), %rsi
	xorl	%ecx, %ecx
	movl	(%r12), %eax
	andl	%r14d, %eax
	sete	%cl
	movq	_readl@GOTPCREL(%rip), %rdx
	movq	%rbx, %rdi
	movl	%r14d, %r8d
	callq	_IOMMU_WAIT_OP
LBB0_3:
	movq	%rbx, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_raw_spin_unlock_irqrestore     ## TAILCALL
LBB0_4:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_DMAR_GSTS_REG,8,3              ## @DMAR_GSTS_REG
	.comm	_DMA_GSTS_IRES,4,2              ## @DMA_GSTS_IRES
	.comm	_DMA_GCMD_IRE,4,2               ## @DMA_GCMD_IRE
	.comm	_DMAR_GCMD_REG,8,3              ## @DMAR_GCMD_REG
	.no_dead_strip	_iommu_disable_irq_remapping
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function iommu_disable_irq_remapping
_iommu_disable_irq_remapping:           ; @iommu_disable_irq_remapping
	.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
	ldr	w0, [x0, #20]
	bl	_ecap_ir_support
	cbz	w0, LBB0_4
; %bb.1:
	mov	x0, x19
	bl	_qi_global_iec
	mov	x0, x19
	bl	_raw_spin_lock_irqsave
	ldr	x8, [x19, #8]
Lloh0:
	adrp	x21, _DMAR_GSTS_REG@GOTPAGE
Lloh1:
	ldr	x21, [x21, _DMAR_GSTS_REG@GOTPAGEOFF]
	ldr	x9, [x21]
	add	x0, x9, x8
	bl	_readl
Lloh2:
	adrp	x22, _DMA_GSTS_IRES@GOTPAGE
Lloh3:
	ldr	x22, [x22, _DMA_GSTS_IRES@GOTPAGEOFF]
	ldr	w8, [x22]
	tst	w8, w0
	b.eq	LBB0_3
; %bb.2:
	mov	x20, x0
Lloh4:
	adrp	x8, _DMA_GCMD_IRE@GOTPAGE
Lloh5:
	ldr	x8, [x8, _DMA_GCMD_IRE@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	ldr	w9, [x19, #16]
	bic	w0, w9, w8
	str	w0, [x19, #16]
	ldr	x8, [x19, #8]
Lloh7:
	adrp	x9, _DMAR_GCMD_REG@GOTPAGE
Lloh8:
	ldr	x9, [x9, _DMAR_GCMD_REG@GOTPAGEOFF]
Lloh9:
	ldr	x9, [x9]
	add	x1, x9, x8
	bl	_writel
	ldr	x1, [x21]
	ldr	w8, [x22]
	tst	w8, w20
	cset	w3, eq
Lloh10:
	adrp	x2, _readl@GOTPAGE
Lloh11:
	ldr	x2, [x2, _readl@GOTPAGEOFF]
	mov	x0, x19
	mov	x4, x20
	bl	_IOMMU_WAIT_OP
LBB0_3:
	mov	x0, x19
	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
	b	_raw_spin_unlock_irqrestore
LBB0_4:
	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	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.comm	_DMAR_GSTS_REG,8,3              ; @DMAR_GSTS_REG
	.comm	_DMA_GSTS_IRES,4,2              ; @DMA_GSTS_IRES
	.comm	_DMA_GCMD_IRE,4,2               ; @DMA_GCMD_IRE
	.comm	_DMAR_GCMD_REG,8,3              ; @DMAR_GCMD_REG
	.no_dead_strip	_iommu_disable_irq_remapping
.subsections_via_symbols
