	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function qib_sd7220_ram_xfer
_qib_sd7220_ram_xfer:                   ## @qib_sd7220_ram_xfer
	.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
	subq	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %ebx
	leal	-128(%rbx), %eax
	movl	$-1, %r13d
	cmpl	$2, %eax
	ja	LBB0_11
## %bb.1:
	movl	%r9d, %r12d
	movq	%rdi, %r14
	movl	%r8d, -72(%rbp)                 ## 4-byte Spill
	movl	%edx, -48(%rbp)                 ## 4-byte Spill
	movq	%rcx, -80(%rbp)                 ## 8-byte Spill
	cltq
	leaq	l_switch.table.qib_sd7220_ram_xfer(%rip), %rcx
	movq	(%rcx,%rax,8), %rcx
	leaq	l_switch.table.qib_sd7220_ram_xfer.1(%rip), %rdx
	movq	(%rdx,%rax,8), %rax
	movl	(%rax), %r15d
	movb	(%rcx), %cl
	movl	$1, %eax
	shlq	%cl, %rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movq	(%rdi), %rdi
	callq	_spin_lock_irqsave
	movq	%r14, %rdi
	movl	%ebx, %esi
	movl	$1, %edx
	callq	_epb_access
	testl	%eax, %eax
	js	LBB0_6
## %bb.2:
	movl	%r12d, -52(%rbp)                ## 4-byte Spill
	movq	%rbx, -88(%rbp)                 ## 8-byte Spill
	movq	_EPB_TRANS_TRIES@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	testl	%r12d, %r12d
	je	LBB0_7
## %bb.3:
	movq	_EPB_TRANS_RDY@GOTPCREL(%rip), %r13
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	movl	%r15d, %esi
	callq	_qib_read_kreg32
	movl	%eax, %ebx
	testl	%eax, (%r13)
	jne	LBB0_12
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	movl	$5, %edi
	callq	_udelay
	decl	%r12d
	jne	LBB0_4
	jmp	LBB0_8
LBB0_6:
	movq	(%r14), %rdi
	callq	_spin_unlock_irqrestore
	jmp	LBB0_11
LBB0_7:
                                        ## implicit-def: $ebx
LBB0_8:
	movl	%ebx, -44(%rbp)
	xorl	%r12d, %r12d
LBB0_9:
	xorl	%r13d, %r13d
LBB0_10:
	movl	$-1, %ebx
	movq	%r14, %rdi
	movq	-88(%rbp), %rsi                 ## 8-byte Reload
                                        ## kill: def $esi killed $esi killed $rsi
	movl	$-1, %edx
	callq	_epb_access
	testl	%eax, %eax
	cmovsl	%ebx, %r13d
	movq	(%r14), %rdi
	callq	_spin_unlock_irqrestore
	testl	%r12d, %r12d
	cmovlel	%ebx, %r13d
LBB0_11:
	movl	%r13d, %eax
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_12:
	movl	%ebx, -44(%rbp)
	testl	%r12d, %r12d
	jle	LBB0_9
## %bb.13:
	movq	_EPB_UC_CTL@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edx
	orl	-64(%rbp), %edx                 ## 4-byte Folded Reload
	cmpl	$0, -52(%rbp)                   ## 4-byte Folded Reload
	jne	LBB0_15
## %bb.14:
	movq	_EPB_ROM_W@GOTPCREL(%rip), %rax
	jmp	LBB0_16
LBB0_15:
	movq	_EPB_ROM_R@GOTPCREL(%rip), %rax
LBB0_16:
	orl	(%rax), %edx
	movl	%edx, -44(%rbp)
	leaq	-44(%rbp), %rcx
	movq	%r14, %rdi
	movl	%r15d, %esi
	callq	_epb_trans
	xorl	%r13d, %r13d
	testl	%eax, %eax
	jle	LBB0_30
## %bb.17:
	movl	-72(%rbp), %edx                 ## 4-byte Reload
	testl	%edx, %edx
	jle	LBB0_30
## %bb.18:
	movl	-48(%rbp), %ecx                 ## 4-byte Reload
	movzbl	%cl, %esi
	shrl	$8, %ecx
	andl	$31, %ecx
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	orl	%eax, %ecx
	movl	%ecx, -48(%rbp)                 ## 4-byte Spill
	orl	%eax, %esi
	movl	%esi, -68(%rbp)                 ## 4-byte Spill
	movl	%edx, %r12d
	leaq	-44(%rbp), %rbx
	xorl	%r13d, %r13d
	jmp	LBB0_21
LBB0_19:                                ##   in Loop: Header=BB0_21 Depth=1
	movq	-80(%rbp), %rax                 ## 8-byte Reload
	orl	(%rax,%r13,4), %edx
	movl	%edx, -44(%rbp)
	movq	%r14, %rdi
	movl	%r15d, %esi
	movq	%rbx, %rcx
	callq	_epb_trans
	testl	%eax, %eax
	jle	LBB0_29
LBB0_20:                                ##   in Loop: Header=BB0_21 Depth=1
	incq	%r13
	cmpq	%r12, %r13
	leaq	-44(%rbp), %rbx
	jae	LBB0_29
LBB0_21:                                ## =>This Inner Loop Header: Depth=1
	testq	%r13, %r13
	jne	LBB0_24
## %bb.22:                              ##   in Loop: Header=BB0_21 Depth=1
	movq	_EPB_MADDRH@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	orl	-48(%rbp), %edx                 ## 4-byte Folded Reload
	movl	%edx, -44(%rbp)
	movq	%r14, %rdi
	movl	%r15d, %esi
	movq	%rbx, %rcx
	callq	_epb_trans
	testl	%eax, %eax
	jle	LBB0_28
## %bb.23:                              ##   in Loop: Header=BB0_21 Depth=1
	movq	_EPB_MADDRL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	orl	-68(%rbp), %edx                 ## 4-byte Folded Reload
	movl	%edx, -44(%rbp)
	movq	%r14, %rdi
	movl	%r15d, %esi
	movq	%rbx, %rcx
	callq	_epb_trans
	testl	%eax, %eax
	jle	LBB0_28
LBB0_24:                                ##   in Loop: Header=BB0_21 Depth=1
	movq	_EPB_ROMDATA@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	orl	-64(%rbp), %edx                 ## 4-byte Folded Reload
	cmpl	$0, -52(%rbp)                   ## 4-byte Folded Reload
	je	LBB0_19
## %bb.25:                              ##   in Loop: Header=BB0_21 Depth=1
	movq	_EPB_RD@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
	movl	%edx, -44(%rbp)
	movq	%r14, %rdi
	movl	%r15d, %esi
	movq	%rbx, %rcx
	callq	_epb_trans
	testl	%eax, %eax
	jle	LBB0_29
## %bb.26:                              ##   in Loop: Header=BB0_21 Depth=1
	movq	_EPB_DATA_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	-44(%rbp), %eax
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	movl	%eax, (%rcx,%r13,4)
	jmp	LBB0_20
LBB0_28:
	xorl	%r13d, %r13d
LBB0_29:
	movq	_EPB_UC_CTL@GOTPCREL(%rip), %rbx
LBB0_30:
	movq	-64(%rbp), %rdx                 ## 8-byte Reload
	orl	(%rbx), %edx
	movl	%edx, -44(%rbp)
	leaq	-44(%rbp), %rcx
	movq	%r14, %rdi
	movl	%r15d, %esi
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_epb_trans
	movl	%eax, %r12d
	jmp	LBB0_10
	.cfi_endproc
                                        ## -- End function
	.comm	_EPB_IB_UC_CS_SHF,8,3           ## @EPB_IB_UC_CS_SHF
	.comm	_kr_ibsd_epb_transaction_reg,4,2 ## @kr_ibsd_epb_transaction_reg
	.comm	_EPB_PCIE_UC_CS_SHF,8,3         ## @EPB_PCIE_UC_CS_SHF
	.comm	_kr_pciesd_epb_transaction_reg,4,2 ## @kr_pciesd_epb_transaction_reg
	.comm	_EPB_TRANS_TRIES,4,2            ## @EPB_TRANS_TRIES
	.comm	_EPB_TRANS_RDY,4,2              ## @EPB_TRANS_RDY
	.comm	_EPB_UC_CTL,4,2                 ## @EPB_UC_CTL
	.comm	_EPB_ROM_R,4,2                  ## @EPB_ROM_R
	.comm	_EPB_ROM_W,4,2                  ## @EPB_ROM_W
	.comm	_EPB_MADDRH,4,2                 ## @EPB_MADDRH
	.comm	_EPB_MADDRL,4,2                 ## @EPB_MADDRL
	.comm	_EPB_ROMDATA,4,2                ## @EPB_ROMDATA
	.comm	_EPB_RD,4,2                     ## @EPB_RD
	.comm	_EPB_DATA_MASK,4,2              ## @EPB_DATA_MASK
	.no_dead_strip	_qib_sd7220_ram_xfer
	.section	__DATA,__const
	.p2align	3                               ## @switch.table.qib_sd7220_ram_xfer
l_switch.table.qib_sd7220_ram_xfer:
	.quad	_EPB_PCIE_UC_CS_SHF
	.quad	_EPB_PCIE_UC_CS_SHF
	.quad	_EPB_IB_UC_CS_SHF

	.p2align	3                               ## @switch.table.qib_sd7220_ram_xfer.1
l_switch.table.qib_sd7220_ram_xfer.1:
	.quad	_kr_pciesd_epb_transaction_reg
	.quad	_kr_pciesd_epb_transaction_reg
	.quad	_kr_ibsd_epb_transaction_reg

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function qib_sd7220_ram_xfer
_qib_sd7220_ram_xfer:                   ; @qib_sd7220_ram_xfer
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	sub	w8, w1, #128
	cmp	w8, #2
	b.hi	LBB0_6
; %bb.1:
	mov	x22, x5
	mov	x24, x4
	mov	x23, x3
	mov	x25, x2
	mov	x20, x1
	mov	x19, x0
	sbfiz	x8, x8, #3, #32
Lloh0:
	adrp	x9, l_switch.table.qib_sd7220_ram_xfer@PAGE
Lloh1:
	add	x9, x9, l_switch.table.qib_sd7220_ram_xfer@PAGEOFF
	ldr	x9, [x9, x8]
Lloh2:
	adrp	x10, l_switch.table.qib_sd7220_ram_xfer.1@PAGE
Lloh3:
	add	x10, x10, l_switch.table.qib_sd7220_ram_xfer.1@PAGEOFF
	ldr	x8, [x10, x8]
	ldr	w21, [x8]
	ldr	x27, [x9]
	mov	w28, #1
	ldr	x0, [x0]
	bl	_spin_lock_irqsave
	mov	x0, x19
	mov	x1, x20
	mov	w2, #1
	bl	_epb_access
	tbnz	w0, #31, LBB0_7
; %bb.2:
Lloh4:
	adrp	x8, _EPB_TRANS_TRIES@GOTPAGE
Lloh5:
	ldr	x8, [x8, _EPB_TRANS_TRIES@GOTPAGEOFF]
Lloh6:
	ldr	w26, [x8]
	cbz	w26, LBB0_8
; %bb.3:
	lsl	x8, x28, x27
	str	x8, [sp]                        ; 8-byte Folded Spill
Lloh7:
	adrp	x28, _EPB_TRANS_RDY@GOTPAGE
Lloh8:
	ldr	x28, [x28, _EPB_TRANS_RDY@GOTPAGEOFF]
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	mov	x1, x21
	bl	_qib_read_kreg32
	mov	x27, x0
	ldr	w8, [x28]
	tst	w8, w0
	b.ne	LBB0_10
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	w0, #5
	bl	_udelay
	subs	w26, w26, #1
	b.ne	LBB0_4
	b	LBB0_9
LBB0_6:
	mov	w0, #-1
	b	LBB0_27
LBB0_7:
	ldr	x0, [x19]
	bl	_spin_unlock_irqrestore
	mov	w0, #-1
	b	LBB0_27
LBB0_8:
                                        ; implicit-def: $w27
LBB0_9:
	mov	w26, #0
	mov	w28, #0
	str	w27, [sp, #12]
	b	LBB0_26
LBB0_10:
	str	w27, [sp, #12]
	cmp	w26, #1
	b.lt	LBB0_13
; %bb.11:
Lloh9:
	adrp	x26, _EPB_UC_CTL@GOTPAGE
Lloh10:
	ldr	x26, [x26, _EPB_UC_CTL@GOTPAGEOFF]
	ldr	w8, [x26]
Lloh11:
	adrp	x9, _EPB_ROM_R@GOTPAGE
Lloh12:
	ldr	x9, [x9, _EPB_ROM_R@GOTPAGEOFF]
Lloh13:
	adrp	x10, _EPB_ROM_W@GOTPAGE
Lloh14:
	ldr	x10, [x10, _EPB_ROM_W@GOTPAGEOFF]
	ldr	x27, [sp]                       ; 8-byte Folded Reload
	orr	w8, w8, w27
	cmp	w22, #0
	csel	x9, x10, x9, eq
	ldr	w9, [x9]
	orr	w2, w8, w9
	str	w2, [sp, #12]
	add	x3, sp, #12
	mov	x0, x19
	mov	x1, x21
	bl	_epb_trans
	cmp	w0, #1
	ccmp	w24, #1, #8, ge
	b.ge	LBB0_14
; %bb.12:
	mov	w28, #0
	b	LBB0_25
LBB0_13:
	mov	w28, #0
	b	LBB0_26
LBB0_14:
	mov	x28, #0
	and	w8, w25, #0xff
	ubfx	w9, w25, #8, #5
	orr	w25, w9, w27
Lloh15:
	adrp	x26, _EPB_ROMDATA@GOTPAGE
Lloh16:
	ldr	x26, [x26, _EPB_ROMDATA@GOTPAGEOFF]
	orr	w27, w8, w27
	mov	w24, w24
	b	LBB0_17
LBB0_15:                                ;   in Loop: Header=BB0_17 Depth=1
	ldr	w9, [x23, x28, lsl #2]
	orr	w2, w8, w9
	str	w2, [sp, #12]
	add	x3, sp, #12
	mov	x0, x19
	mov	x1, x21
	bl	_epb_trans
	cmp	w0, #1
	b.lt	LBB0_24
LBB0_16:                                ;   in Loop: Header=BB0_17 Depth=1
	add	x28, x28, #1
	cmp	x28, x24
	b.hs	LBB0_24
LBB0_17:                                ; =>This Inner Loop Header: Depth=1
	cbnz	x28, LBB0_20
; %bb.18:                               ;   in Loop: Header=BB0_17 Depth=1
Lloh17:
	adrp	x8, _EPB_MADDRH@GOTPAGE
Lloh18:
	ldr	x8, [x8, _EPB_MADDRH@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
	orr	w2, w25, w8
	str	w2, [sp, #12]
	add	x3, sp, #12
	mov	x0, x19
	mov	x1, x21
	bl	_epb_trans
	cmp	w0, #1
	b.lt	LBB0_23
; %bb.19:                               ;   in Loop: Header=BB0_17 Depth=1
Lloh20:
	adrp	x8, _EPB_MADDRL@GOTPAGE
Lloh21:
	ldr	x8, [x8, _EPB_MADDRL@GOTPAGEOFF]
Lloh22:
	ldr	w8, [x8]
	orr	w2, w27, w8
	str	w2, [sp, #12]
	add	x3, sp, #12
	mov	x0, x19
	mov	x1, x21
	bl	_epb_trans
	cmp	w0, #1
	b.lt	LBB0_23
LBB0_20:                                ;   in Loop: Header=BB0_17 Depth=1
	ldr	w8, [x26]
	ldr	x9, [sp]                        ; 8-byte Folded Reload
	orr	w8, w8, w9
	cbz	w22, LBB0_15
; %bb.21:                               ;   in Loop: Header=BB0_17 Depth=1
Lloh23:
	adrp	x9, _EPB_RD@GOTPAGE
Lloh24:
	ldr	x9, [x9, _EPB_RD@GOTPAGEOFF]
Lloh25:
	ldr	w9, [x9]
	orr	w2, w8, w9
	str	w2, [sp, #12]
	add	x3, sp, #12
	mov	x0, x19
	mov	x1, x21
	bl	_epb_trans
	cmp	w0, #1
	b.lt	LBB0_24
; %bb.22:                               ;   in Loop: Header=BB0_17 Depth=1
	ldr	w8, [sp, #12]
Lloh26:
	adrp	x9, _EPB_DATA_MASK@GOTPAGE
Lloh27:
	ldr	x9, [x9, _EPB_DATA_MASK@GOTPAGEOFF]
Lloh28:
	ldr	w9, [x9]
	and	w8, w9, w8
	str	w8, [x23, x28, lsl #2]
	b	LBB0_16
LBB0_23:
	mov	x28, #0
LBB0_24:
	ldr	x27, [sp]                       ; 8-byte Folded Reload
Lloh29:
	adrp	x26, _EPB_UC_CTL@GOTPAGE
Lloh30:
	ldr	x26, [x26, _EPB_UC_CTL@GOTPAGEOFF]
LBB0_25:
	ldr	w8, [x26]
	orr	w2, w8, w27
	str	w2, [sp, #12]
	add	x3, sp, #12
	mov	x0, x19
	mov	x1, x21
	bl	_epb_trans
	mov	x26, x0
LBB0_26:
	mov	x0, x19
	mov	x1, x20
	mov	w2, #-1
	bl	_epb_access
	cmp	w0, #0
	csinv	w20, w28, wzr, ge
	ldr	x0, [x19]
	bl	_spin_unlock_irqrestore
	cmp	w26, #1
	csinv	w0, w20, wzr, ge
LBB0_27:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGot	Lloh29, Lloh30
	.cfi_endproc
                                        ; -- End function
	.comm	_EPB_IB_UC_CS_SHF,8,3           ; @EPB_IB_UC_CS_SHF
	.comm	_kr_ibsd_epb_transaction_reg,4,2 ; @kr_ibsd_epb_transaction_reg
	.comm	_EPB_PCIE_UC_CS_SHF,8,3         ; @EPB_PCIE_UC_CS_SHF
	.comm	_kr_pciesd_epb_transaction_reg,4,2 ; @kr_pciesd_epb_transaction_reg
	.comm	_EPB_TRANS_TRIES,4,2            ; @EPB_TRANS_TRIES
	.comm	_EPB_TRANS_RDY,4,2              ; @EPB_TRANS_RDY
	.comm	_EPB_UC_CTL,4,2                 ; @EPB_UC_CTL
	.comm	_EPB_ROM_R,4,2                  ; @EPB_ROM_R
	.comm	_EPB_ROM_W,4,2                  ; @EPB_ROM_W
	.comm	_EPB_MADDRH,4,2                 ; @EPB_MADDRH
	.comm	_EPB_MADDRL,4,2                 ; @EPB_MADDRL
	.comm	_EPB_ROMDATA,4,2                ; @EPB_ROMDATA
	.comm	_EPB_RD,4,2                     ; @EPB_RD
	.comm	_EPB_DATA_MASK,4,2              ; @EPB_DATA_MASK
	.no_dead_strip	_qib_sd7220_ram_xfer
	.section	__DATA,__const
	.p2align	3                               ; @switch.table.qib_sd7220_ram_xfer
l_switch.table.qib_sd7220_ram_xfer:
	.quad	_EPB_PCIE_UC_CS_SHF
	.quad	_EPB_PCIE_UC_CS_SHF
	.quad	_EPB_IB_UC_CS_SHF

	.p2align	3                               ; @switch.table.qib_sd7220_ram_xfer.1
l_switch.table.qib_sd7220_ram_xfer.1:
	.quad	_kr_pciesd_epb_transaction_reg
	.quad	_kr_pciesd_epb_transaction_reg
	.quad	_kr_ibsd_epb_transaction_reg

.subsections_via_symbols
