	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function qib_7220_intr_fallback
_qib_7220_intr_fallback:                ## @qib_7220_intr_fallback
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	cmpq	$0, 8(%rdi)
	je	LBB0_1
## %bb.2:
	movq	%rdi, %rbx
	movl	(%rdi), %edi
	leaq	L_.str(%rip), %rsi
	callq	_qib_devinfo
	movq	%rbx, %rdi
	callq	_qib_free_irq
	movq	$0, 8(%rbx)
	movl	(%rbx), %edi
	movq	_PCI_IRQ_LEGACY@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	$1, %r14d
	movl	$1, %esi
	movl	$1, %edx
	callq	_pci_alloc_irq_vectors
	testq	%rax, %rax
	jns	LBB0_4
## %bb.3:
	leaq	L_.str.1(%rip), %rsi
	movq	%rbx, %rdi
	callq	_qib_dev_err
LBB0_4:
	movq	%rbx, %rdi
	callq	_qib_setup_7220_interrupt
	jmp	LBB0_5
LBB0_1:
	xorl	%r14d, %r14d
LBB0_5:
	movl	%r14d, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"MSI interrupt not detected, trying INTx interrupts\n"

	.comm	_PCI_IRQ_LEGACY,4,2             ## @PCI_IRQ_LEGACY
L_.str.1:                               ## @.str.1
	.asciz	"Failed to enable INTx\n"

	.no_dead_strip	_qib_7220_intr_fallback
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function qib_7220_intr_fallback
_qib_7220_intr_fallback:                ; @qib_7220_intr_fallback
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	ldr	x8, [x0, #8]
	cbz	x8, LBB0_4
; %bb.1:
	mov	x19, x0
	ldr	w0, [x0]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	bl	_qib_devinfo
	mov	x0, x19
	bl	_qib_free_irq
	str	xzr, [x19, #8]
	ldr	w0, [x19]
Lloh2:
	adrp	x8, _PCI_IRQ_LEGACY@GOTPAGE
Lloh3:
	ldr	x8, [x8, _PCI_IRQ_LEGACY@GOTPAGEOFF]
Lloh4:
	ldr	w3, [x8]
	mov	w1, #1
	mov	w2, #1
	bl	_pci_alloc_irq_vectors
	tbz	x0, #63, LBB0_3
; %bb.2:
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_qib_dev_err
LBB0_3:
	mov	x0, x19
	bl	_qib_setup_7220_interrupt
	mov	w0, #1
	b	LBB0_5
LBB0_4:
	mov	w0, #0
LBB0_5:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"MSI interrupt not detected, trying INTx interrupts\n"

	.comm	_PCI_IRQ_LEGACY,4,2             ; @PCI_IRQ_LEGACY
l_.str.1:                               ; @.str.1
	.asciz	"Failed to enable INTx\n"

	.no_dead_strip	_qib_7220_intr_fallback
.subsections_via_symbols
