	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pasemi_edac_init_csrows
_pasemi_edac_init_csrows:               ## @pasemi_edac_init_csrows
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	movq	%rsi, -56(%rbp)                 ## 8-byte Spill
	cmpl	$0, (%rdi)
	jle	LBB0_7
## %bb.1:
	movq	%rdi, %r13
	xorl	%ebx, %ebx
	xorl	%r14d, %r14d
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_2 Depth=1
	incq	%r14
	movslq	(%r13), %rax
	addq	$12, %rbx
	cmpq	%rax, %r14
	jge	LBB0_7
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%r13), %rax
	movq	(%rax,%r14,8), %r15
	movq	16(%r15), %rax
	movq	(%rax), %rax
	movq	(%rax), %r12
	movq	_MCDRAM_RANKCFG@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	%rbx, %rsi
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	leaq	-48(%rbp), %rdx
	callq	_pci_read_config_dword
	movl	-48(%rbp), %eax
	movq	_MCDRAM_RANKCFG_EN@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_6
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_MCDRAM_RANKCFG_TYPE_SIZE_M@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	andl	%eax, %edx
	movq	_MCDRAM_RANKCFG_TYPE_SIZE_S@GOTPCREL(%rip), %rcx
	movzbl	(%rcx), %ecx
	sarl	%cl, %edx
	cmpl	$6, %edx
	jae	LBB0_4
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	movslq	%edx, %rax
	movb	$20, %cl
	movq	_PAGE_SHIFT@GOTPCREL(%rip), %rdx
	subb	(%rdx), %cl
	leaq	l_switch.table.pasemi_edac_init_csrows(%rip), %rdx
	movl	(%rdx,%rax,4), %eax
	shll	%cl, %eax
	movl	%eax, (%r12)
	movq	_last_page_in_mmc@GOTPCREL(%rip), %rdx
	movl	(%rdx), %ecx
	movl	%ecx, (%r15)
	addl	%eax, %ecx
	decl	%ecx
	movl	%ecx, 4(%r15)
	addl	%eax, (%rdx)
	movq	$0, 8(%r15)
	movq	_PASEMI_EDAC_ERROR_GRAIN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 16(%r12)
	movq	_MEM_DDR@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 12(%r12)
	movq	_DEV_UNKNOWN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 8(%r12)
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, 4(%r12)
	jmp	LBB0_6
LBB0_7:
	xorl	%eax, %eax
	jmp	LBB0_8
LBB0_4:
	movq	_KERN_ERR@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	leaq	L_.str(%rip), %rdx
	movq	%r13, %rdi
	movl	%eax, %ecx
	callq	_edac_mc_printk
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_8:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MCDRAM_RANKCFG,8,3             ## @MCDRAM_RANKCFG
	.comm	_MCDRAM_RANKCFG_EN,4,2          ## @MCDRAM_RANKCFG_EN
	.comm	_MCDRAM_RANKCFG_TYPE_SIZE_M,4,2 ## @MCDRAM_RANKCFG_TYPE_SIZE_M
	.comm	_MCDRAM_RANKCFG_TYPE_SIZE_S,4,2 ## @MCDRAM_RANKCFG_TYPE_SIZE_S
	.comm	_PAGE_SHIFT,4,2                 ## @PAGE_SHIFT
	.comm	_KERN_ERR,4,2                   ## @KERN_ERR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Unrecognized Rank Config. rankcfg=%u\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_last_page_in_mmc,4,2           ## @last_page_in_mmc
	.comm	_PASEMI_EDAC_ERROR_GRAIN,4,2    ## @PASEMI_EDAC_ERROR_GRAIN
	.comm	_MEM_DDR,4,2                    ## @MEM_DDR
	.comm	_DEV_UNKNOWN,4,2                ## @DEV_UNKNOWN
	.no_dead_strip	_pasemi_edac_init_csrows
	.section	__TEXT,__const
	.p2align	2                               ## @switch.table.pasemi_edac_init_csrows
l_switch.table.pasemi_edac_init_csrows:
	.long	128                             ## 0x80
	.long	256                             ## 0x100
	.long	512                             ## 0x200
	.long	512                             ## 0x200
	.long	1024                            ## 0x400
	.long	2048                            ## 0x800

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pasemi_edac_init_csrows
_pasemi_edac_init_csrows:               ; @pasemi_edac_init_csrows
	.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
	ldr	w8, [x0]
	cmp	w8, #1
	b.lt	LBB0_6
; %bb.1:
	mov	x20, x2
	mov	x21, x1
	mov	x19, x0
	mov	x22, #0
	mov	x23, #0
Lloh0:
	adrp	x24, _MCDRAM_RANKCFG@GOTPAGE
Lloh1:
	ldr	x24, [x24, _MCDRAM_RANKCFG@GOTPAGEOFF]
Lloh2:
	adrp	x25, _MCDRAM_RANKCFG_EN@GOTPAGE
Lloh3:
	ldr	x25, [x25, _MCDRAM_RANKCFG_EN@GOTPAGEOFF]
Lloh4:
	adrp	x28, _last_page_in_mmc@GOTPAGE
Lloh5:
	ldr	x28, [x28, _last_page_in_mmc@GOTPAGEOFF]
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x23, x23, #1
	ldrsw	x8, [x19]
	add	x22, x22, #12
	cmp	x23, x8
	b.ge	LBB0_6
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #8]
	ldr	x27, [x8, x23, lsl #3]
	ldr	x8, [x27, #16]
	ldr	x8, [x8]
	ldr	x26, [x8]
	ldr	x8, [x24]
	add	x1, x22, x8
	add	x2, sp, #12
	mov	x0, x21
	bl	_pci_read_config_dword
	ldr	w3, [sp, #12]
	ldr	w8, [x25]
	tst	w8, w3
	b.eq	LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
Lloh6:
	adrp	x8, _MCDRAM_RANKCFG_TYPE_SIZE_M@GOTPAGE
Lloh7:
	ldr	x8, [x8, _MCDRAM_RANKCFG_TYPE_SIZE_M@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	and	w8, w8, w3
Lloh9:
	adrp	x9, _MCDRAM_RANKCFG_TYPE_SIZE_S@GOTPAGE
Lloh10:
	ldr	x9, [x9, _MCDRAM_RANKCFG_TYPE_SIZE_S@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	asr	w8, w8, w9
	cmp	w8, #6
	b.hs	LBB0_7
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
Lloh12:
	adrp	x9, l_switch.table.pasemi_edac_init_csrows@PAGE
Lloh13:
	add	x9, x9, l_switch.table.pasemi_edac_init_csrows@PAGEOFF
	ldr	w8, [x9, w8, sxtw #2]
Lloh14:
	adrp	x9, _PAGE_SHIFT@GOTPAGE
Lloh15:
	ldr	x9, [x9, _PAGE_SHIFT@GOTPAGEOFF]
Lloh16:
	ldr	w9, [x9]
	mov	w10, #20
	sub	w9, w10, w9
	lsl	w8, w8, w9
	str	w8, [x26]
	ldr	w9, [x28]
	add	w10, w9, w8
	sub	w10, w10, #1
	stp	w9, w10, [x27]
	ldr	w9, [x28]
	add	w8, w9, w8
	str	w8, [x28]
	str	xzr, [x27, #8]
Lloh17:
	adrp	x8, _PASEMI_EDAC_ERROR_GRAIN@GOTPAGE
Lloh18:
	ldr	x8, [x8, _PASEMI_EDAC_ERROR_GRAIN@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
	str	w8, [x26, #16]
Lloh20:
	adrp	x8, _MEM_DDR@GOTPAGE
Lloh21:
	ldr	x8, [x8, _MEM_DDR@GOTPAGEOFF]
Lloh22:
	ldr	w8, [x8]
Lloh23:
	adrp	x9, _DEV_UNKNOWN@GOTPAGE
Lloh24:
	ldr	x9, [x9, _DEV_UNKNOWN@GOTPAGEOFF]
Lloh25:
	ldr	w9, [x9]
	stp	w9, w8, [x26, #8]
	str	w20, [x26, #4]
	b	LBB0_2
LBB0_6:
	mov	w0, #0
	b	LBB0_8
LBB0_7:
Lloh26:
	adrp	x8, _KERN_ERR@GOTPAGE
Lloh27:
	ldr	x8, [x8, _KERN_ERR@GOTPAGEOFF]
Lloh28:
	ldr	w1, [x8]
Lloh29:
	adrp	x2, l_.str@PAGE
Lloh30:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x19
	bl	_edac_mc_printk
Lloh31:
	adrp	x8, _EINVAL@GOTPAGE
Lloh32:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh33:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_8:
	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 AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.cfi_endproc
                                        ; -- End function
	.comm	_MCDRAM_RANKCFG,8,3             ; @MCDRAM_RANKCFG
	.comm	_MCDRAM_RANKCFG_EN,4,2          ; @MCDRAM_RANKCFG_EN
	.comm	_MCDRAM_RANKCFG_TYPE_SIZE_M,4,2 ; @MCDRAM_RANKCFG_TYPE_SIZE_M
	.comm	_MCDRAM_RANKCFG_TYPE_SIZE_S,4,2 ; @MCDRAM_RANKCFG_TYPE_SIZE_S
	.comm	_PAGE_SHIFT,4,2                 ; @PAGE_SHIFT
	.comm	_KERN_ERR,4,2                   ; @KERN_ERR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Unrecognized Rank Config. rankcfg=%u\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_last_page_in_mmc,4,2           ; @last_page_in_mmc
	.comm	_PASEMI_EDAC_ERROR_GRAIN,4,2    ; @PASEMI_EDAC_ERROR_GRAIN
	.comm	_MEM_DDR,4,2                    ; @MEM_DDR
	.comm	_DEV_UNKNOWN,4,2                ; @DEV_UNKNOWN
	.no_dead_strip	_pasemi_edac_init_csrows
	.section	__TEXT,__const
	.p2align	2                               ; @switch.table.pasemi_edac_init_csrows
l_switch.table.pasemi_edac_init_csrows:
	.long	128                             ; 0x80
	.long	256                             ; 0x100
	.long	512                             ; 0x200
	.long	512                             ; 0x200
	.long	1024                            ; 0x400
	.long	2048                            ; 0x800

.subsections_via_symbols
