	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_solo_p2m_init                  ## -- Begin function solo_p2m_init
	.p2align	4, 0x90
_solo_p2m_init:                         ## @solo_p2m_init
	.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, %r14
	movq	_SOLO_NR_P2M@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	jle	LBB0_3
## %bb.1:
	movl	$4, %r13d
	xorl	%r12d, %r12d
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	16(%r14), %rbx
	leaq	(%rbx,%r13), %rdi
	callq	_mutex_init
	leaq	(%rbx,%r13), %rdi
	addq	$-4, %rdi
	callq	_init_completion
	movl	%r12d, %edi
	callq	_SOLO_P2M_CONTROL
	movq	%r14, %rdi
	movl	%eax, %esi
	xorl	%edx, %edx
	callq	_solo_reg_write
	movl	%r12d, %edi
	callq	_SOLO_P2M_CONFIG
	movl	%eax, %r15d
	movq	_SOLO_P2M_DESC_INTR_OPT@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	_SOLO_P2M_CSC_16BIT_565@GOTPCREL(%rip), %rax
	orl	(%rax), %ebx
	xorl	%edi, %edi
	callq	_SOLO_P2M_DMA_INTERVAL
	orl	%eax, %ebx
	movq	_SOLO_P2M_PCI_MASTER_MODE@GOTPCREL(%rip), %rax
	orl	(%rax), %ebx
	movq	%r14, %rdi
	movl	%r15d, %esi
	movl	%ebx, %edx
	callq	_solo_reg_write
	movl	%r12d, %edi
	callq	_SOLO_IRQ_P2M
	movq	%r14, %rdi
	movl	%eax, %esi
	callq	_solo_irq_on
	movq	_SOLO_NR_P2M@GOTPCREL(%rip), %rax
	incq	%r12
	movslq	(%rax), %rax
	addq	$8, %r13
	cmpq	%rax, %r12
	jl	LBB0_2
LBB0_3:
	movl	$0, (%r14)
	movl	$2, %r12d
	movq	_SOLO_SYS_CFG@GOTPCREL(%rip), %r13
	jmp	LBB0_4
	.p2align	4, 0x90
LBB0_9:                                 ##   in Loop: Header=BB0_4 Depth=1
	movl	$33488896, %esi                 ## imm = 0x1FF0000
LBB0_10:                                ##   in Loop: Header=BB0_4 Depth=1
	movl	$65536, %edx                    ## imm = 0x10000
	callq	_solo_p2m_test
	testl	%eax, %eax
	je	LBB0_11
LBB0_12:                                ##   in Loop: Header=BB0_4 Depth=1
	addl	$-1, %r12d
	jae	LBB0_13
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	_SOLO_DMA_CTRL@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movl	$1, %edi
	callq	_SOLO_DMA_CTRL_REFRESH_CYCLE
	movl	%eax, %ebx
	movl	%r12d, %edi
	callq	_SOLO_DMA_CTRL_SDRAM_SIZE
	orl	%eax, %ebx
	movq	_SOLO_DMA_CTRL_SDRAM_CLK_INVERT@GOTPCREL(%rip), %rax
	orl	(%rax), %ebx
	movq	_SOLO_DMA_CTRL_READ_CLK_SELECT@GOTPCREL(%rip), %rax
	orl	(%rax), %ebx
	movl	$1, %edi
	callq	_SOLO_DMA_CTRL_LATENCY
	orl	%eax, %ebx
	movq	%r14, %rdi
	movl	%r15d, %esi
	movl	%ebx, %edx
	callq	_solo_reg_write
	movl	(%r13), %esi
	movq	_SOLO_SYS_CFG_RESET@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	orl	4(%r14), %edx
	movq	%r14, %rdi
	callq	_solo_reg_write
	movl	(%r13), %esi
	movl	4(%r14), %edx
	movq	%r14, %rdi
	callq	_solo_reg_write
	movq	%r14, %rdi
	cmpl	$1, %r12d
	je	LBB0_8
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	cmpl	$2, %r12d
	jne	LBB0_9
## %bb.6:                               ##   in Loop: Header=BB0_4 Depth=1
	movl	$134152192, %esi                ## imm = 0x7FF0000
	movl	$65536, %edx                    ## imm = 0x10000
	callq	_solo_p2m_test
	testl	%eax, %eax
	jne	LBB0_12
## %bb.7:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	%r14, %rdi
	movl	$100597760, %esi                ## imm = 0x5FF0000
	jmp	LBB0_10
	.p2align	4, 0x90
LBB0_8:                                 ##   in Loop: Header=BB0_4 Depth=1
	movl	$67043328, %esi                 ## imm = 0x3FF0000
	jmp	LBB0_10
LBB0_13:
	movl	(%r14), %eax
	testl	%eax, %eax
	je	LBB0_15
LBB0_16:
	movq	%r14, %rdi
	callq	_SOLO_SDRAM_END
	movl	(%r14), %r15d
	xorl	%ebx, %ebx
	cmpl	%r15d, %eax
	jle	LBB0_19
## %bb.17:
	movq	8(%r14), %r12
	movq	%r14, %rdi
	callq	_SOLO_SDRAM_END
	leaq	L_.str.1(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r12, %rdi
	movl	%r15d, %edx
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_18
LBB0_11:
	movl	$33554432, %eax                 ## imm = 0x2000000
	movl	%r12d, %ecx
	shll	%cl, %eax
	movl	%eax, (%r14)
	testl	%eax, %eax
	jne	LBB0_16
LBB0_15:
	movq	8(%r14), %rdi
	leaq	L_.str(%rip), %rsi
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_dev_err
LBB0_18:
	movq	_EIO@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
LBB0_19:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SOLO_NR_P2M,4,2                ## @SOLO_NR_P2M
	.comm	_SOLO_P2M_CSC_16BIT_565,4,2     ## @SOLO_P2M_CSC_16BIT_565
	.comm	_SOLO_P2M_DESC_INTR_OPT,4,2     ## @SOLO_P2M_DESC_INTR_OPT
	.comm	_SOLO_P2M_PCI_MASTER_MODE,4,2   ## @SOLO_P2M_PCI_MASTER_MODE
	.comm	_SOLO_DMA_CTRL,4,2              ## @SOLO_DMA_CTRL
	.comm	_SOLO_DMA_CTRL_SDRAM_CLK_INVERT,4,2 ## @SOLO_DMA_CTRL_SDRAM_CLK_INVERT
	.comm	_SOLO_DMA_CTRL_READ_CLK_SELECT,4,2 ## @SOLO_DMA_CTRL_READ_CLK_SELECT
	.comm	_SOLO_SYS_CFG,4,2               ## @SOLO_SYS_CFG
	.comm	_SOLO_SYS_CFG_RESET,4,2         ## @SOLO_SYS_CFG_RESET
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Error detecting SDRAM size\n"

	.comm	_EIO,4,2                        ## @EIO
L_.str.1:                               ## @.str.1
	.asciz	"SDRAM is not large enough (%u < %u)\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_solo_p2m_init                  ; -- Begin function solo_p2m_init
	.p2align	2
_solo_p2m_init:                         ; @solo_p2m_init
	.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
	mov	x19, x0
Lloh0:
	adrp	x22, _SOLO_NR_P2M@GOTPAGE
Lloh1:
	ldr	x22, [x22, _SOLO_NR_P2M@GOTPAGEOFF]
	ldr	w8, [x22]
	cmp	w8, #1
	b.lt	LBB0_3
; %bb.1:
	mov	x20, #0
	mov	w23, #4
Lloh2:
	adrp	x24, _SOLO_P2M_CSC_16BIT_565@GOTPAGE
Lloh3:
	ldr	x24, [x24, _SOLO_P2M_CSC_16BIT_565@GOTPAGEOFF]
Lloh4:
	adrp	x25, _SOLO_P2M_DESC_INTR_OPT@GOTPAGE
Lloh5:
	ldr	x25, [x25, _SOLO_P2M_DESC_INTR_OPT@GOTPAGEOFF]
Lloh6:
	adrp	x26, _SOLO_P2M_PCI_MASTER_MODE@GOTPAGE
Lloh7:
	ldr	x26, [x26, _SOLO_P2M_PCI_MASTER_MODE@GOTPAGEOFF]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #16]
	add	x21, x8, x23
	mov	x0, x21
	bl	_mutex_init
	sub	x0, x21, #4
	bl	_init_completion
	mov	x0, x20
	bl	_SOLO_P2M_CONTROL
	mov	x1, x0
	mov	x0, x19
	mov	w2, #0
	bl	_solo_reg_write
	mov	x0, x20
	bl	_SOLO_P2M_CONFIG
	mov	x21, x0
	ldr	w8, [x24]
	ldr	w9, [x25]
	orr	w27, w9, w8
	mov	w0, #0
	bl	_SOLO_P2M_DMA_INTERVAL
	orr	w8, w27, w0
	ldr	w9, [x26]
	orr	w2, w8, w9
	mov	x0, x19
	mov	x1, x21
	bl	_solo_reg_write
	mov	x0, x20
	bl	_SOLO_IRQ_P2M
	mov	x1, x0
	mov	x0, x19
	bl	_solo_irq_on
	add	x20, x20, #1
	ldrsw	x8, [x22]
	add	x23, x23, #8
	cmp	x20, x8
	b.lt	LBB0_2
LBB0_3:
	str	wzr, [x19]
	mov	w20, #2
Lloh8:
	adrp	x23, _SOLO_DMA_CTRL@GOTPAGE
Lloh9:
	ldr	x23, [x23, _SOLO_DMA_CTRL@GOTPAGEOFF]
Lloh10:
	adrp	x24, _SOLO_DMA_CTRL_SDRAM_CLK_INVERT@GOTPAGE
Lloh11:
	ldr	x24, [x24, _SOLO_DMA_CTRL_SDRAM_CLK_INVERT@GOTPAGEOFF]
Lloh12:
	adrp	x25, _SOLO_DMA_CTRL_READ_CLK_SELECT@GOTPAGE
Lloh13:
	ldr	x25, [x25, _SOLO_DMA_CTRL_READ_CLK_SELECT@GOTPAGEOFF]
Lloh14:
	adrp	x26, _SOLO_SYS_CFG@GOTPAGE
Lloh15:
	ldr	x26, [x26, _SOLO_SYS_CFG@GOTPAGEOFF]
Lloh16:
	adrp	x27, _SOLO_SYS_CFG_RESET@GOTPAGE
Lloh17:
	ldr	x27, [x27, _SOLO_SYS_CFG_RESET@GOTPAGEOFF]
	b	LBB0_7
LBB0_4:                                 ;   in Loop: Header=BB0_7 Depth=1
	mov	w1, #33488896
LBB0_5:                                 ;   in Loop: Header=BB0_7 Depth=1
	mov	w2, #65536
	bl	_solo_p2m_test
	cbz	w0, LBB0_15
LBB0_6:                                 ;   in Loop: Header=BB0_7 Depth=1
	mov	x20, x21
	cmn	w21, #1
	b.eq	LBB0_12
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w21, [x23]
	mov	w0, #1
	bl	_SOLO_DMA_CTRL_REFRESH_CYCLE
	mov	x22, x0
	mov	x0, x20
	bl	_SOLO_DMA_CTRL_SDRAM_SIZE
	orr	w8, w0, w22
	ldr	w9, [x24]
	orr	w8, w8, w9
	ldr	w9, [x25]
	orr	w22, w8, w9
	mov	w0, #1
	bl	_SOLO_DMA_CTRL_LATENCY
	orr	w2, w22, w0
	mov	x0, x19
	mov	x1, x21
	bl	_solo_reg_write
	ldr	w1, [x26]
	ldr	w8, [x19, #4]
	ldr	w9, [x27]
	orr	w2, w9, w8
	mov	x0, x19
	bl	_solo_reg_write
	ldr	w1, [x26]
	ldr	w2, [x19, #4]
	mov	x0, x19
	bl	_solo_reg_write
	mov	x0, x19
	subs	w21, w20, #1
	b.eq	LBB0_11
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	cmp	w20, #2
	b.ne	LBB0_4
; %bb.9:                                ;   in Loop: Header=BB0_7 Depth=1
	mov	w1, #134152192
	mov	w2, #65536
	bl	_solo_p2m_test
	cbnz	w0, LBB0_6
; %bb.10:                               ;   in Loop: Header=BB0_7 Depth=1
	mov	x0, x19
	mov	w1, #100597760
	b	LBB0_5
LBB0_11:                                ;   in Loop: Header=BB0_7 Depth=1
	mov	w1, #67043328
	b	LBB0_5
LBB0_12:
	ldr	w8, [x19]
	cbz	w8, LBB0_16
LBB0_13:
	mov	x0, x19
	bl	_SOLO_SDRAM_END
	ldr	w21, [x19]
	cmp	w0, w21
	b.le	LBB0_18
; %bb.14:
	ldr	x20, [x19, #8]
	mov	x0, x19
	bl	_SOLO_SDRAM_END
                                        ; kill: def $w0 killed $w0 def $x0
	stp	x21, x0, [sp]
Lloh18:
	adrp	x1, l_.str.1@PAGE
Lloh19:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x20
	b	LBB0_17
LBB0_15:
	mov	w8, #33554432
	lsl	w8, w8, w20
	str	w8, [x19]
	cbnz	w8, LBB0_13
LBB0_16:
	ldr	x0, [x19, #8]
Lloh20:
	adrp	x1, l_.str@PAGE
Lloh21:
	add	x1, x1, l_.str@PAGEOFF
LBB0_17:
	bl	_dev_err
Lloh22:
	adrp	x8, _EIO@GOTPAGE
Lloh23:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh24:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_19
LBB0_18:
	mov	w0, #0
LBB0_19:
	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	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.cfi_endproc
                                        ; -- End function
	.comm	_SOLO_NR_P2M,4,2                ; @SOLO_NR_P2M
	.comm	_SOLO_P2M_CSC_16BIT_565,4,2     ; @SOLO_P2M_CSC_16BIT_565
	.comm	_SOLO_P2M_DESC_INTR_OPT,4,2     ; @SOLO_P2M_DESC_INTR_OPT
	.comm	_SOLO_P2M_PCI_MASTER_MODE,4,2   ; @SOLO_P2M_PCI_MASTER_MODE
	.comm	_SOLO_DMA_CTRL,4,2              ; @SOLO_DMA_CTRL
	.comm	_SOLO_DMA_CTRL_SDRAM_CLK_INVERT,4,2 ; @SOLO_DMA_CTRL_SDRAM_CLK_INVERT
	.comm	_SOLO_DMA_CTRL_READ_CLK_SELECT,4,2 ; @SOLO_DMA_CTRL_READ_CLK_SELECT
	.comm	_SOLO_SYS_CFG,4,2               ; @SOLO_SYS_CFG
	.comm	_SOLO_SYS_CFG_RESET,4,2         ; @SOLO_SYS_CFG_RESET
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Error detecting SDRAM size\n"

	.comm	_EIO,4,2                        ; @EIO
l_.str.1:                               ; @.str.1
	.asciz	"SDRAM is not large enough (%u < %u)\n"

.subsections_via_symbols
