	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function arm_smmu_setup_irqs
_arm_smmu_setup_irqs:                   ## @arm_smmu_setup_irqs
	.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, %r15
	movq	_IRQ_CTRL_EVTQ_IRQEN@GOTPCREL(%rip), %rax
	movq	_IRQ_CTRL_GERROR_IRQEN@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ebx
	orl	(%rax), %ebx
	movq	_ARM_SMMU_IRQ_CTRL@GOTPCREL(%rip), %r12
	movl	(%r12), %edx
	movq	_ARM_SMMU_IRQ_CTRLACK@GOTPCREL(%rip), %r13
	movl	(%r13), %ecx
	xorl	%esi, %esi
	callq	_arm_smmu_write_reg_sync
	movl	%eax, %r14d
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	movl	8(%r15), %edi
	leaq	L_.str(%rip), %rsi
	callq	_dev_err
	jmp	LBB0_10
LBB0_2:
	movl	(%r15), %esi
	testl	%esi, %esi
	je	LBB0_5
## %bb.3:
	movl	8(%r15), %edi
	movq	_arm_smmu_combined_irq_handler@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_arm_smmu_combined_irq_thread@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	_IRQF_ONESHOT@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	movq	%r15, (%rsp)
	leaq	L_.str.1(%rip), %r9
	callq	_devm_request_threaded_irq
	testl	%eax, %eax
	jns	LBB0_6
## %bb.4:
	movl	8(%r15), %edi
	leaq	L_.str.2(%rip), %rsi
	callq	_dev_warn
	jmp	LBB0_6
LBB0_5:
	movq	%r15, %rdi
	callq	_arm_smmu_setup_unique_irqs
LBB0_6:
	movq	_ARM_SMMU_FEAT_PRI@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	4(%r15), %eax
	je	LBB0_8
## %bb.7:
	movq	_IRQ_CTRL_PRIQ_IRQEN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_8:
	orl	%eax, %ebx
	movl	(%r12), %edx
	movl	(%r13), %ecx
	movq	%r15, %rdi
	movl	%ebx, %esi
	callq	_arm_smmu_write_reg_sync
	testl	%eax, %eax
	je	LBB0_10
## %bb.9:
	movl	8(%r15), %edi
	leaq	L_.str.3(%rip), %rsi
	callq	_dev_warn
LBB0_10:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IRQ_CTRL_EVTQ_IRQEN,4,2        ## @IRQ_CTRL_EVTQ_IRQEN
	.comm	_IRQ_CTRL_GERROR_IRQEN,4,2      ## @IRQ_CTRL_GERROR_IRQEN
	.comm	_ARM_SMMU_IRQ_CTRL,4,2          ## @ARM_SMMU_IRQ_CTRL
	.comm	_ARM_SMMU_IRQ_CTRLACK,4,2       ## @ARM_SMMU_IRQ_CTRLACK
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"failed to disable irqs\n"

	.comm	_arm_smmu_combined_irq_handler,4,2 ## @arm_smmu_combined_irq_handler
	.comm	_arm_smmu_combined_irq_thread,4,2 ## @arm_smmu_combined_irq_thread
	.comm	_IRQF_ONESHOT,4,2               ## @IRQF_ONESHOT
L_.str.1:                               ## @.str.1
	.asciz	"arm-smmu-v3-combined-irq"

L_.str.2:                               ## @.str.2
	.asciz	"failed to enable combined irq\n"

	.comm	_ARM_SMMU_FEAT_PRI,4,2          ## @ARM_SMMU_FEAT_PRI
	.comm	_IRQ_CTRL_PRIQ_IRQEN,4,2        ## @IRQ_CTRL_PRIQ_IRQEN
L_.str.3:                               ## @.str.3
	.asciz	"failed to enable irqs\n"

	.no_dead_strip	_arm_smmu_setup_irqs
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function arm_smmu_setup_irqs
_arm_smmu_setup_irqs:                   ; @arm_smmu_setup_irqs
	.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	x19, x0
Lloh0:
	adrp	x8, _IRQ_CTRL_EVTQ_IRQEN@GOTPAGE
Lloh1:
	ldr	x8, [x8, _IRQ_CTRL_EVTQ_IRQEN@GOTPAGEOFF]
Lloh2:
	ldr	w23, [x8]
Lloh3:
	adrp	x8, _IRQ_CTRL_GERROR_IRQEN@GOTPAGE
Lloh4:
	ldr	x8, [x8, _IRQ_CTRL_GERROR_IRQEN@GOTPAGEOFF]
Lloh5:
	ldr	w24, [x8]
Lloh6:
	adrp	x21, _ARM_SMMU_IRQ_CTRL@GOTPAGE
Lloh7:
	ldr	x21, [x21, _ARM_SMMU_IRQ_CTRL@GOTPAGEOFF]
	ldr	w2, [x21]
Lloh8:
	adrp	x22, _ARM_SMMU_IRQ_CTRLACK@GOTPAGE
Lloh9:
	ldr	x22, [x22, _ARM_SMMU_IRQ_CTRLACK@GOTPAGEOFF]
	ldr	w3, [x22]
	mov	w1, #0
	bl	_arm_smmu_write_reg_sync
	mov	x20, x0
	cbz	w0, LBB0_2
; %bb.1:
	ldr	w0, [x19, #8]
Lloh10:
	adrp	x1, l_.str@PAGE
Lloh11:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err
	b	LBB0_8
LBB0_2:
	orr	w23, w24, w23
	ldr	w1, [x19]
	cbz	w1, LBB0_5
; %bb.3:
	ldr	w0, [x19, #8]
Lloh12:
	adrp	x8, _arm_smmu_combined_irq_handler@GOTPAGE
Lloh13:
	ldr	x8, [x8, _arm_smmu_combined_irq_handler@GOTPAGEOFF]
Lloh14:
	ldr	w2, [x8]
Lloh15:
	adrp	x8, _arm_smmu_combined_irq_thread@GOTPAGE
Lloh16:
	ldr	x8, [x8, _arm_smmu_combined_irq_thread@GOTPAGEOFF]
Lloh17:
	ldr	w3, [x8]
Lloh18:
	adrp	x8, _IRQF_ONESHOT@GOTPAGE
Lloh19:
	ldr	x8, [x8, _IRQF_ONESHOT@GOTPAGEOFF]
Lloh20:
	ldr	w4, [x8]
Lloh21:
	adrp	x5, l_.str.1@PAGE
Lloh22:
	add	x5, x5, l_.str.1@PAGEOFF
	mov	x6, x19
	bl	_devm_request_threaded_irq
	tbz	w0, #31, LBB0_6
; %bb.4:
	ldr	w0, [x19, #8]
Lloh23:
	adrp	x1, l_.str.2@PAGE
Lloh24:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_dev_warn
	b	LBB0_6
LBB0_5:
	mov	x0, x19
	bl	_arm_smmu_setup_unique_irqs
LBB0_6:
	ldr	w8, [x19, #4]
Lloh25:
	adrp	x9, _ARM_SMMU_FEAT_PRI@GOTPAGE
Lloh26:
	ldr	x9, [x9, _ARM_SMMU_FEAT_PRI@GOTPAGEOFF]
Lloh27:
	ldr	w9, [x9]
Lloh28:
	adrp	x10, _IRQ_CTRL_PRIQ_IRQEN@GOTPAGE
Lloh29:
	ldr	x10, [x10, _IRQ_CTRL_PRIQ_IRQEN@GOTPAGEOFF]
Lloh30:
	ldr	w10, [x10]
	tst	w9, w8
	csel	w8, wzr, w10, eq
	orr	w1, w23, w8
	ldr	w2, [x21]
	ldr	w3, [x22]
	mov	x0, x19
	bl	_arm_smmu_write_reg_sync
	cbz	w0, LBB0_8
; %bb.7:
	ldr	w0, [x19, #8]
Lloh31:
	adrp	x1, l_.str.3@PAGE
Lloh32:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_dev_warn
LBB0_8:
	mov	x0, 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
	ret
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpAdd	Lloh31, Lloh32
	.cfi_endproc
                                        ; -- End function
	.comm	_IRQ_CTRL_EVTQ_IRQEN,4,2        ; @IRQ_CTRL_EVTQ_IRQEN
	.comm	_IRQ_CTRL_GERROR_IRQEN,4,2      ; @IRQ_CTRL_GERROR_IRQEN
	.comm	_ARM_SMMU_IRQ_CTRL,4,2          ; @ARM_SMMU_IRQ_CTRL
	.comm	_ARM_SMMU_IRQ_CTRLACK,4,2       ; @ARM_SMMU_IRQ_CTRLACK
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"failed to disable irqs\n"

	.comm	_arm_smmu_combined_irq_handler,4,2 ; @arm_smmu_combined_irq_handler
	.comm	_arm_smmu_combined_irq_thread,4,2 ; @arm_smmu_combined_irq_thread
	.comm	_IRQF_ONESHOT,4,2               ; @IRQF_ONESHOT
l_.str.1:                               ; @.str.1
	.asciz	"arm-smmu-v3-combined-irq"

l_.str.2:                               ; @.str.2
	.asciz	"failed to enable combined irq\n"

	.comm	_ARM_SMMU_FEAT_PRI,4,2          ; @ARM_SMMU_FEAT_PRI
	.comm	_IRQ_CTRL_PRIQ_IRQEN,4,2        ; @IRQ_CTRL_PRIQ_IRQEN
l_.str.3:                               ; @.str.3
	.asciz	"failed to enable irqs\n"

	.no_dead_strip	_arm_smmu_setup_irqs
.subsections_via_symbols
