	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function idt_init_isr
_idt_init_isr:                          ## @idt_init_isr
	.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
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	(%rdi), %r15
	movq	_PCI_IRQ_MSI@GOTPCREL(%rip), %rax
	movq	_PCI_IRQ_LEGACY@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	movq	%r15, %rdi
	movl	$1, %esi
	movl	$1, %edx
	callq	_pci_alloc_irq_vectors
	cmpl	$1, %eax
	jne	LBB0_1
## %bb.2:
	movq	%r15, %rdi
	xorl	%esi, %esi
	callq	_pci_irq_vector
	movl	%eax, %r12d
	testl	%eax, %eax
	js	LBB0_3
## %bb.4:
	movq	_idt_thread_isr@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	_IRQF_ONESHOT@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	movq	_NTB_IRQNAME@GOTPCREL(%rip), %rax
	movl	(%rax), %r9d
	movq	%r14, (%rsp)
	xorl	%ebx, %ebx
	movq	%r15, %rdi
	movl	%r12d, %esi
	xorl	%edx, %edx
	callq	_devm_request_threaded_irq
	testl	%eax, %eax
	je	LBB0_8
## %bb.5:
	movl	%eax, %r12d
	leaq	L_.str.2(%rip), %rsi
	movq	%r15, %rdi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_6
LBB0_1:
	movl	%eax, %ebx
	leaq	L_.str(%rip), %rsi
	movq	%r15, %rdi
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_7
LBB0_3:
	leaq	L_.str.1(%rip), %rsi
	movq	%r15, %rdi
	xorl	%eax, %eax
	callq	_dev_err
LBB0_6:
	movq	%r15, %rdi
	callq	_pci_free_irq_vectors
	movl	%r12d, %ebx
	jmp	LBB0_7
LBB0_8:
	movq	_IDT_NT_NTINTMSK@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movq	%r14, %rdi
	callq	_idt_nt_read
	movq	_IDT_NTINTMSK_ALL@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	notl	%edx
	andl	%eax, %edx
	movl	(%r12), %esi
	movq	%r14, %rdi
	callq	_idt_nt_write
	leaq	L_.str.3(%rip), %rsi
	movq	%r15, %rdi
	callq	_dev_dbg
LBB0_7:
	movl	%ebx, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PCI_IRQ_MSI,4,2                ## @PCI_IRQ_MSI
	.comm	_PCI_IRQ_LEGACY,4,2             ## @PCI_IRQ_LEGACY
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Failed to allocate IRQ vector"

L_.str.1:                               ## @.str.1
	.asciz	"Failed to get IRQ vector"

	.comm	_idt_thread_isr,4,2             ## @idt_thread_isr
	.comm	_IRQF_ONESHOT,4,2               ## @IRQF_ONESHOT
	.comm	_NTB_IRQNAME,4,2                ## @NTB_IRQNAME
L_.str.2:                               ## @.str.2
	.asciz	"Failed to set MSI IRQ handler, %d"

	.comm	_IDT_NT_NTINTMSK,4,2            ## @IDT_NT_NTINTMSK
	.comm	_IDT_NTINTMSK_ALL,4,2           ## @IDT_NTINTMSK_ALL
L_.str.3:                               ## @.str.3
	.asciz	"NTB interrupts initialized"

	.no_dead_strip	_idt_init_isr
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function idt_init_isr
_idt_init_isr:                          ; @idt_init_isr
	.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	x20, x0
Lloh0:
	adrp	x8, _PCI_IRQ_MSI@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PCI_IRQ_MSI@GOTPAGEOFF]
	ldr	x19, [x0]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, _PCI_IRQ_LEGACY@GOTPAGE
Lloh4:
	ldr	x9, [x9, _PCI_IRQ_LEGACY@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	orr	w3, w9, w8
	mov	x0, x19
	mov	w1, #1
	mov	w2, #1
	bl	_pci_alloc_irq_vectors
	cmp	w0, #1
	b.ne	LBB0_4
; %bb.1:
	mov	x0, x19
	mov	w1, #0
	bl	_pci_irq_vector
	mov	x21, x0
	tbnz	w0, #31, LBB0_5
; %bb.2:
Lloh6:
	adrp	x8, _idt_thread_isr@GOTPAGE
Lloh7:
	ldr	x8, [x8, _idt_thread_isr@GOTPAGEOFF]
Lloh8:
	ldr	w3, [x8]
Lloh9:
	adrp	x8, _IRQF_ONESHOT@GOTPAGE
Lloh10:
	ldr	x8, [x8, _IRQF_ONESHOT@GOTPAGEOFF]
Lloh11:
	ldr	w4, [x8]
Lloh12:
	adrp	x8, _NTB_IRQNAME@GOTPAGE
Lloh13:
	ldr	x8, [x8, _NTB_IRQNAME@GOTPAGEOFF]
Lloh14:
	ldr	w5, [x8]
	mov	x0, x19
	mov	x1, x21
	mov	x2, #0
	mov	x6, x20
	bl	_devm_request_threaded_irq
	cbz	w0, LBB0_7
; %bb.3:
	mov	x21, x0
	str	x21, [sp]
Lloh15:
	adrp	x1, l_.str.2@PAGE
Lloh16:
	add	x1, x1, l_.str.2@PAGEOFF
	b	LBB0_6
LBB0_4:
	mov	x21, x0
Lloh17:
	adrp	x1, l_.str@PAGE
Lloh18:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_dev_err
	b	LBB0_8
LBB0_5:
Lloh19:
	adrp	x1, l_.str.1@PAGE
Lloh20:
	add	x1, x1, l_.str.1@PAGEOFF
LBB0_6:
	mov	x0, x19
	bl	_dev_err
	mov	x0, x19
	bl	_pci_free_irq_vectors
	b	LBB0_8
LBB0_7:
Lloh21:
	adrp	x21, _IDT_NT_NTINTMSK@GOTPAGE
Lloh22:
	ldr	x21, [x21, _IDT_NT_NTINTMSK@GOTPAGEOFF]
	ldr	w1, [x21]
	mov	x0, x20
	bl	_idt_nt_read
Lloh23:
	adrp	x8, _IDT_NTINTMSK_ALL@GOTPAGE
Lloh24:
	ldr	x8, [x8, _IDT_NTINTMSK_ALL@GOTPAGEOFF]
Lloh25:
	ldr	w8, [x8]
	bic	w2, w0, w8
	ldr	w1, [x21]
	mov	x0, x20
	bl	_idt_nt_write
Lloh26:
	adrp	x1, l_.str.3@PAGE
Lloh27:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x19
	bl	_dev_dbg
	mov	w21, #0
LBB0_8:
	mov	x0, x21
	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
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGot	Lloh21, Lloh22
	.cfi_endproc
                                        ; -- End function
	.comm	_PCI_IRQ_MSI,4,2                ; @PCI_IRQ_MSI
	.comm	_PCI_IRQ_LEGACY,4,2             ; @PCI_IRQ_LEGACY
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Failed to allocate IRQ vector"

l_.str.1:                               ; @.str.1
	.asciz	"Failed to get IRQ vector"

	.comm	_idt_thread_isr,4,2             ; @idt_thread_isr
	.comm	_IRQF_ONESHOT,4,2               ; @IRQF_ONESHOT
	.comm	_NTB_IRQNAME,4,2                ; @NTB_IRQNAME
l_.str.2:                               ; @.str.2
	.asciz	"Failed to set MSI IRQ handler, %d"

	.comm	_IDT_NT_NTINTMSK,4,2            ; @IDT_NT_NTINTMSK
	.comm	_IDT_NTINTMSK_ALL,4,2           ; @IDT_NTINTMSK_ALL
l_.str.3:                               ; @.str.3
	.asciz	"NTB interrupts initialized"

	.no_dead_strip	_idt_init_isr
.subsections_via_symbols
