	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function qib_late_7322_initreg
_qib_late_7322_initreg:                 ## @qib_late_7322_initreg
	.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	_kr_rcvhdrentsize@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	(%rdi), %rdx
	callq	_qib_write_kreg
	movq	_kr_rcvhdrsize@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	8(%r15), %rdx
	movq	%r15, %rdi
	callq	_qib_write_kreg
	movq	_kr_rcvhdrcnt@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	16(%r15), %rdx
	movq	%r15, %rdi
	callq	_qib_write_kreg
	movq	_kr_sendpioavailaddr@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	movq	24(%r15), %rdx
	movq	%r15, %rdi
	callq	_qib_write_kreg
	movl	(%rbx), %esi
	movq	%r15, %rdi
	callq	_qib_read_kreg64
	movq	24(%r15), %rdx
	xorl	%ecx, %ecx
	cmpq	%rdx, %rax
	je	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rsi
	movq	%r15, %rdi
	movq	%rax, %rcx
	callq	_qib_dev_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ecx, %ecx
	subl	(%rax), %ecx
LBB0_2:
	movl	%ecx, -44(%rbp)                 ## 4-byte Spill
	movl	36(%r15), %ebx
	addl	32(%r15), %ebx
	movq	_NUM_VL15_BUFS@GOTPCREL(%rip), %rax
	addl	(%rax), %ebx
	movq	_TXCHK_CHG_TYPE_KERN@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r15, %rdi
	xorl	%esi, %esi
	movl	%ebx, %edx
	xorl	%r8d, %r8d
	callq	_qib_7322_txchk_change
	movq	_TXCHK_CHG_TYPE_ENAB1@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r15, %rdi
	xorl	%esi, %esi
	movl	%ebx, %edx
	xorl	%r8d, %r8d
	callq	_qib_7322_txchk_change
	movq	_sendctrl_0_observer@GOTPCREL(%rip), %rsi
	movq	%r15, %rdi
	callq	_qib_register_observer
	movq	_sendctrl_1_observer@GOTPCREL(%rip), %rsi
	movq	%r15, %rdi
	callq	_qib_register_observer
	movq	_QLOGIC_IB_C_SDMAFETCHPRIOEN@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	notq	%rdx
	andq	40(%r15), %rdx
	movq	%rdx, 40(%r15)
	movq	_kr_control@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_qib_write_kreg
	movq	%r15, %rdi
	xorl	%esi, %esi
	callq	_set_no_qsfp_atten
	cmpl	$0, 48(%r15)
	jle	LBB0_7
## %bb.3:
	xorl	%r12d, %r12d
	movq	_QIB_HAS_QSFP@GOTPCREL(%rip), %r13
	xorl	%r14d, %r14d
	jmp	LBB0_4
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_4 Depth=1
	incq	%r14
	movslq	48(%r15), %rax
	addq	$4, %r12
	cmpq	%rax, %r14
	jge	LBB0_7
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	56(%r15), %rbx
	addq	%r12, %rbx
	movq	_krp_senddmaprioritythld@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_sdma_fetch_prio@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	andl	$15, %edx
	movq	%rbx, %rdi
	callq	_qib_write_kreg_port
	movl	(%r13), %eax
	testl	%eax, 52(%r15)
	je	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	%rbx, %rdi
	callq	_qib_init_7322_qsfp
	jmp	LBB0_6
LBB0_7:
	movq	40(%r15), %rdx
	movq	_QLOGIC_IB_C_SDMAFETCHPRIOEN@GOTPCREL(%rip), %rax
	orq	(%rax), %rdx
	movq	%rdx, 40(%r15)
	movq	_kr_control@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_qib_write_kreg
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_kr_rcvhdrentsize,4,2           ## @kr_rcvhdrentsize
	.comm	_kr_rcvhdrsize,4,2              ## @kr_rcvhdrsize
	.comm	_kr_rcvhdrcnt,4,2               ## @kr_rcvhdrcnt
	.comm	_kr_sendpioavailaddr,4,2        ## @kr_sendpioavailaddr
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Catastrophic software error, SendPIOAvailAddr written as %lx, read back as %llx\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_NUM_VL15_BUFS,4,2              ## @NUM_VL15_BUFS
	.comm	_TXCHK_CHG_TYPE_KERN,4,2        ## @TXCHK_CHG_TYPE_KERN
	.comm	_TXCHK_CHG_TYPE_ENAB1,4,2       ## @TXCHK_CHG_TYPE_ENAB1
	.comm	_sendctrl_0_observer,4,2        ## @sendctrl_0_observer
	.comm	_sendctrl_1_observer,4,2        ## @sendctrl_1_observer
	.comm	_QLOGIC_IB_C_SDMAFETCHPRIOEN,8,3 ## @QLOGIC_IB_C_SDMAFETCHPRIOEN
	.comm	_kr_control,4,2                 ## @kr_control
	.comm	_krp_senddmaprioritythld,4,2    ## @krp_senddmaprioritythld
	.comm	_sdma_fetch_prio,4,2            ## @sdma_fetch_prio
	.comm	_QIB_HAS_QSFP,4,2               ## @QIB_HAS_QSFP
	.no_dead_strip	_qib_late_7322_initreg
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function qib_late_7322_initreg
_qib_late_7322_initreg:                 ; @qib_late_7322_initreg
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x0
Lloh0:
	adrp	x8, _kr_rcvhdrentsize@GOTPAGE
Lloh1:
	ldr	x8, [x8, _kr_rcvhdrentsize@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	ldr	x2, [x0]
	bl	_qib_write_kreg
Lloh3:
	adrp	x8, _kr_rcvhdrsize@GOTPAGE
Lloh4:
	ldr	x8, [x8, _kr_rcvhdrsize@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	ldr	x2, [x19, #8]
	mov	x0, x19
	bl	_qib_write_kreg
Lloh6:
	adrp	x8, _kr_rcvhdrcnt@GOTPAGE
Lloh7:
	ldr	x8, [x8, _kr_rcvhdrcnt@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	ldr	x2, [x19, #16]
	mov	x0, x19
	bl	_qib_write_kreg
Lloh9:
	adrp	x20, _kr_sendpioavailaddr@GOTPAGE
Lloh10:
	ldr	x20, [x20, _kr_sendpioavailaddr@GOTPAGEOFF]
	ldr	w1, [x20]
	ldr	x2, [x19, #24]
	mov	x0, x19
	bl	_qib_write_kreg
	ldr	w1, [x20]
	mov	x0, x19
	bl	_qib_read_kreg64
	ldr	x2, [x19, #24]
	cmp	x0, x2
	b.ne	LBB0_2
; %bb.1:
	mov	w20, #0
	b	LBB0_3
LBB0_2:
	mov	x3, x0
Lloh11:
	adrp	x1, l_.str@PAGE
Lloh12:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_qib_dev_err
Lloh13:
	adrp	x8, _EINVAL@GOTPAGE
Lloh14:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	neg	w20, w8
LBB0_3:
	ldp	w8, w9, [x19, #32]
Lloh16:
	adrp	x10, _NUM_VL15_BUFS@GOTPAGE
Lloh17:
	ldr	x10, [x10, _NUM_VL15_BUFS@GOTPAGEOFF]
Lloh18:
	ldr	w10, [x10]
	add	w8, w9, w8
	add	w21, w8, w10
Lloh19:
	adrp	x8, _TXCHK_CHG_TYPE_KERN@GOTPAGE
Lloh20:
	ldr	x8, [x8, _TXCHK_CHG_TYPE_KERN@GOTPAGEOFF]
Lloh21:
	ldr	w3, [x8]
	mov	x0, x19
	mov	w1, #0
	mov	x2, x21
	mov	x4, #0
	bl	_qib_7322_txchk_change
Lloh22:
	adrp	x8, _TXCHK_CHG_TYPE_ENAB1@GOTPAGE
Lloh23:
	ldr	x8, [x8, _TXCHK_CHG_TYPE_ENAB1@GOTPAGEOFF]
Lloh24:
	ldr	w3, [x8]
	mov	x0, x19
	mov	w1, #0
	mov	x2, x21
	mov	x4, #0
	bl	_qib_7322_txchk_change
Lloh25:
	adrp	x1, _sendctrl_0_observer@GOTPAGE
Lloh26:
	ldr	x1, [x1, _sendctrl_0_observer@GOTPAGEOFF]
	mov	x0, x19
	bl	_qib_register_observer
Lloh27:
	adrp	x1, _sendctrl_1_observer@GOTPAGE
Lloh28:
	ldr	x1, [x1, _sendctrl_1_observer@GOTPAGEOFF]
	mov	x0, x19
	bl	_qib_register_observer
Lloh29:
	adrp	x22, _QLOGIC_IB_C_SDMAFETCHPRIOEN@GOTPAGE
Lloh30:
	ldr	x22, [x22, _QLOGIC_IB_C_SDMAFETCHPRIOEN@GOTPAGEOFF]
	ldr	x8, [x22]
	ldr	x9, [x19, #40]
	bic	x2, x9, x8
	str	x2, [x19, #40]
Lloh31:
	adrp	x23, _kr_control@GOTPAGE
Lloh32:
	ldr	x23, [x23, _kr_control@GOTPAGEOFF]
	ldr	w1, [x23]
	mov	x0, x19
	bl	_qib_write_kreg
	mov	x0, x19
	mov	w1, #0
	bl	_set_no_qsfp_atten
	ldr	w8, [x19, #48]
	cmp	w8, #1
	b.lt	LBB0_8
; %bb.4:
	mov	x24, #0
	mov	x25, #0
Lloh33:
	adrp	x26, _krp_senddmaprioritythld@GOTPAGE
Lloh34:
	ldr	x26, [x26, _krp_senddmaprioritythld@GOTPAGEOFF]
Lloh35:
	adrp	x27, _sdma_fetch_prio@GOTPAGE
Lloh36:
	ldr	x27, [x27, _sdma_fetch_prio@GOTPAGEOFF]
Lloh37:
	adrp	x28, _QIB_HAS_QSFP@GOTPAGE
Lloh38:
	ldr	x28, [x28, _QIB_HAS_QSFP@GOTPAGEOFF]
	b	LBB0_6
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	add	x25, x25, #1
	ldrsw	x8, [x19, #48]
	add	x24, x24, #4
	cmp	x25, x8
	b.ge	LBB0_8
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #56]
	add	x21, x8, x24
	ldr	w1, [x26]
	ldr	w8, [x27]
	and	w2, w8, #0xf
	mov	x0, x21
	bl	_qib_write_kreg_port
	ldr	w8, [x19, #52]
	ldr	w9, [x28]
	tst	w9, w8
	b.eq	LBB0_5
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	mov	x0, x21
	bl	_qib_init_7322_qsfp
	b	LBB0_5
LBB0_8:
	ldr	x8, [x22]
	ldr	x9, [x19, #40]
	orr	x2, x9, x8
	str	x2, [x19, #40]
	ldr	w1, [x23]
	mov	x0, x19
	bl	_qib_write_kreg
	mov	x0, x20
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh31, Lloh32
	.loh AdrpLdrGot	Lloh29, Lloh30
	.loh AdrpLdrGot	Lloh27, Lloh28
	.loh AdrpLdrGot	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh37, Lloh38
	.loh AdrpLdrGot	Lloh35, Lloh36
	.loh AdrpLdrGot	Lloh33, Lloh34
	.cfi_endproc
                                        ; -- End function
	.comm	_kr_rcvhdrentsize,4,2           ; @kr_rcvhdrentsize
	.comm	_kr_rcvhdrsize,4,2              ; @kr_rcvhdrsize
	.comm	_kr_rcvhdrcnt,4,2               ; @kr_rcvhdrcnt
	.comm	_kr_sendpioavailaddr,4,2        ; @kr_sendpioavailaddr
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Catastrophic software error, SendPIOAvailAddr written as %lx, read back as %llx\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_NUM_VL15_BUFS,4,2              ; @NUM_VL15_BUFS
	.comm	_TXCHK_CHG_TYPE_KERN,4,2        ; @TXCHK_CHG_TYPE_KERN
	.comm	_TXCHK_CHG_TYPE_ENAB1,4,2       ; @TXCHK_CHG_TYPE_ENAB1
	.comm	_sendctrl_0_observer,4,2        ; @sendctrl_0_observer
	.comm	_sendctrl_1_observer,4,2        ; @sendctrl_1_observer
	.comm	_QLOGIC_IB_C_SDMAFETCHPRIOEN,8,3 ; @QLOGIC_IB_C_SDMAFETCHPRIOEN
	.comm	_kr_control,4,2                 ; @kr_control
	.comm	_krp_senddmaprioritythld,4,2    ; @krp_senddmaprioritythld
	.comm	_sdma_fetch_prio,4,2            ; @sdma_fetch_prio
	.comm	_QIB_HAS_QSFP,4,2               ; @QIB_HAS_QSFP
	.no_dead_strip	_qib_late_7322_initreg
.subsections_via_symbols
