	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_armada38x_open_bootrom_win     ## -- Begin function armada38x_open_bootrom_win
	.p2align	4, 0x90
_armada38x_open_bootrom_win:            ## @armada38x_open_bootrom_win
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_fdtbus_bs_tag@GOTPCREL(%rip), %r14
	movl	(%r14), %edi
	movq	_MV_MBUS_BRIDGE_BASE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_MV_CPU_SUBSYS_REGS_LEN@GOTPCREL(%rip), %r15
	movl	(%r15), %edx
	leaq	-28(%rbp), %r8
	xorl	%ecx, %ecx
	callq	_bus_space_map
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_2
## %bb.1:
	movq	_MV_BOOTROM_WIN_SIZE@GOTPCREL(%rip), %rcx
	movq	_IO_WIN_SIZE_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	(%rcx), %eax
	movq	_IO_WIN_SIZE_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	shll	%cl, %eax
	movq	_MBUS_BOOTROM_ATTR@GOTPCREL(%rip), %rcx
	movq	_IO_WIN_ATTR_MASK@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	andl	(%rcx), %edx
	movq	_IO_WIN_ATTR_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	shll	%cl, %edx
	movq	_MBUS_BOOTROM_TGT_ID@GOTPCREL(%rip), %rcx
	movq	_IO_WIN_TGT_MASK@GOTPCREL(%rip), %rsi
	movl	(%rsi), %esi
	andl	(%rcx), %esi
	movq	_IO_WIN_TGT_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	shll	%cl, %esi
	movq	_IO_WIN_SYNC_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	movq	_IO_WIN_SYNC_MASK@GOTPCREL(%rip), %rdi
	movl	(%rdi), %edi
	andl	$1, %edi
	shll	%cl, %edi
	orl	%eax, %edx
	orl	%esi, %edi
	orl	%edx, %edi
	movq	_IO_WIN_ENA_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	$1, %eax
	movq	_IO_WIN_ENA_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	shll	%cl, %eax
	orl	%edi, %eax
	movl	(%r14), %edi
	movl	-28(%rbp), %esi
	movq	_IO_WIN_9_CTRL_OFFSET@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movl	%eax, %ecx
	callq	_bus_space_write_4
	movl	(%r14), %edi
	movl	-28(%rbp), %esi
	movq	_IO_WIN_9_BASE_OFFSET@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_MV_BOOTROM_MEM_ADDR@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	callq	_bus_space_write_4
	movl	(%r14), %edi
	movl	-28(%rbp), %esi
	movl	(%r15), %ecx
	movq	_BUS_SPACE_BARRIER_WRITE@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	xorl	%edx, %edx
	callq	_bus_space_barrier
	movl	(%r14), %edi
	movl	-28(%rbp), %esi
	movl	(%r15), %edx
	callq	_bus_space_unmap
LBB0_2:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_fdtbus_bs_tag,4,2              ## @fdtbus_bs_tag
	.comm	_MV_MBUS_BRIDGE_BASE,8,3        ## @MV_MBUS_BRIDGE_BASE
	.comm	_MV_CPU_SUBSYS_REGS_LEN,4,2     ## @MV_CPU_SUBSYS_REGS_LEN
	.comm	_MV_BOOTROM_WIN_SIZE,4,2        ## @MV_BOOTROM_WIN_SIZE
	.comm	_IO_WIN_SIZE_MASK,4,2           ## @IO_WIN_SIZE_MASK
	.comm	_IO_WIN_SIZE_SHIFT,4,2          ## @IO_WIN_SIZE_SHIFT
	.comm	_MBUS_BOOTROM_ATTR,4,2          ## @MBUS_BOOTROM_ATTR
	.comm	_IO_WIN_ATTR_MASK,4,2           ## @IO_WIN_ATTR_MASK
	.comm	_IO_WIN_ATTR_SHIFT,4,2          ## @IO_WIN_ATTR_SHIFT
	.comm	_MBUS_BOOTROM_TGT_ID,4,2        ## @MBUS_BOOTROM_TGT_ID
	.comm	_IO_WIN_TGT_MASK,4,2            ## @IO_WIN_TGT_MASK
	.comm	_IO_WIN_TGT_SHIFT,4,2           ## @IO_WIN_TGT_SHIFT
	.comm	_IO_WIN_SYNC_MASK,4,2           ## @IO_WIN_SYNC_MASK
	.comm	_IO_WIN_SYNC_SHIFT,4,2          ## @IO_WIN_SYNC_SHIFT
	.comm	_IO_WIN_ENA_MASK,4,2            ## @IO_WIN_ENA_MASK
	.comm	_IO_WIN_ENA_SHIFT,4,2           ## @IO_WIN_ENA_SHIFT
	.comm	_IO_WIN_9_CTRL_OFFSET,4,2       ## @IO_WIN_9_CTRL_OFFSET
	.comm	_IO_WIN_9_BASE_OFFSET,4,2       ## @IO_WIN_9_BASE_OFFSET
	.comm	_MV_BOOTROM_MEM_ADDR,4,2        ## @MV_BOOTROM_MEM_ADDR
	.comm	_BUS_SPACE_BARRIER_WRITE,4,2    ## @BUS_SPACE_BARRIER_WRITE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_armada38x_open_bootrom_win     ; -- Begin function armada38x_open_bootrom_win
	.p2align	2
_armada38x_open_bootrom_win:            ; @armada38x_open_bootrom_win
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
Lloh0:
	adrp	x20, _fdtbus_bs_tag@GOTPAGE
Lloh1:
	ldr	x20, [x20, _fdtbus_bs_tag@GOTPAGEOFF]
	ldr	w0, [x20]
Lloh2:
	adrp	x8, _MV_MBUS_BRIDGE_BASE@GOTPAGE
Lloh3:
	ldr	x8, [x8, _MV_MBUS_BRIDGE_BASE@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
Lloh5:
	adrp	x21, _MV_CPU_SUBSYS_REGS_LEN@GOTPAGE
Lloh6:
	ldr	x21, [x21, _MV_CPU_SUBSYS_REGS_LEN@GOTPAGEOFF]
	ldr	w2, [x21]
	add	x4, sp, #12
	mov	w3, #0
	bl	_bus_space_map
	mov	x19, x0
	cbnz	w0, LBB0_2
; %bb.1:
Lloh7:
	adrp	x8, _MV_BOOTROM_WIN_SIZE@GOTPAGE
Lloh8:
	ldr	x8, [x8, _MV_BOOTROM_WIN_SIZE@GOTPAGEOFF]
Lloh9:
	adrp	x9, _IO_WIN_SIZE_MASK@GOTPAGE
Lloh10:
	ldr	x9, [x9, _IO_WIN_SIZE_MASK@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
Lloh12:
	ldr	w9, [x9]
	and	w8, w9, w8
Lloh13:
	adrp	x9, _IO_WIN_SIZE_SHIFT@GOTPAGE
Lloh14:
	ldr	x9, [x9, _IO_WIN_SIZE_SHIFT@GOTPAGEOFF]
Lloh15:
	ldr	w9, [x9]
	lsl	w8, w8, w9
Lloh16:
	adrp	x9, _MBUS_BOOTROM_ATTR@GOTPAGE
Lloh17:
	ldr	x9, [x9, _MBUS_BOOTROM_ATTR@GOTPAGEOFF]
Lloh18:
	ldr	w9, [x9]
Lloh19:
	adrp	x10, _IO_WIN_ATTR_MASK@GOTPAGE
Lloh20:
	ldr	x10, [x10, _IO_WIN_ATTR_MASK@GOTPAGEOFF]
Lloh21:
	ldr	w10, [x10]
	and	w9, w10, w9
Lloh22:
	adrp	x10, _IO_WIN_ATTR_SHIFT@GOTPAGE
Lloh23:
	ldr	x10, [x10, _IO_WIN_ATTR_SHIFT@GOTPAGEOFF]
Lloh24:
	ldr	w10, [x10]
	lsl	w9, w9, w10
	orr	w8, w9, w8
Lloh25:
	adrp	x9, _MBUS_BOOTROM_TGT_ID@GOTPAGE
Lloh26:
	ldr	x9, [x9, _MBUS_BOOTROM_TGT_ID@GOTPAGEOFF]
Lloh27:
	ldr	w9, [x9]
Lloh28:
	adrp	x10, _IO_WIN_TGT_MASK@GOTPAGE
Lloh29:
	ldr	x10, [x10, _IO_WIN_TGT_MASK@GOTPAGEOFF]
Lloh30:
	ldr	w10, [x10]
	and	w9, w10, w9
Lloh31:
	adrp	x10, _IO_WIN_TGT_SHIFT@GOTPAGE
Lloh32:
	ldr	x10, [x10, _IO_WIN_TGT_SHIFT@GOTPAGEOFF]
Lloh33:
	ldr	w10, [x10]
	lsl	w9, w9, w10
	orr	w8, w8, w9
Lloh34:
	adrp	x9, _IO_WIN_SYNC_MASK@GOTPAGE
Lloh35:
	ldr	x9, [x9, _IO_WIN_SYNC_MASK@GOTPAGEOFF]
Lloh36:
	ldr	w9, [x9]
Lloh37:
	adrp	x10, _IO_WIN_SYNC_SHIFT@GOTPAGE
Lloh38:
	ldr	x10, [x10, _IO_WIN_SYNC_SHIFT@GOTPAGEOFF]
	and	w9, w9, #0x1
Lloh39:
	ldr	w10, [x10]
	lsl	w9, w9, w10
	orr	w8, w8, w9
Lloh40:
	adrp	x9, _IO_WIN_ENA_MASK@GOTPAGE
Lloh41:
	ldr	x9, [x9, _IO_WIN_ENA_MASK@GOTPAGEOFF]
Lloh42:
	ldr	w9, [x9]
	and	w9, w9, #0x1
Lloh43:
	adrp	x10, _IO_WIN_ENA_SHIFT@GOTPAGE
Lloh44:
	ldr	x10, [x10, _IO_WIN_ENA_SHIFT@GOTPAGEOFF]
Lloh45:
	ldr	w10, [x10]
	lsl	w9, w9, w10
	orr	w3, w8, w9
	ldr	w0, [x20]
	ldr	w1, [sp, #12]
Lloh46:
	adrp	x8, _IO_WIN_9_CTRL_OFFSET@GOTPAGE
Lloh47:
	ldr	x8, [x8, _IO_WIN_9_CTRL_OFFSET@GOTPAGEOFF]
Lloh48:
	ldr	w2, [x8]
	bl	_bus_space_write_4
	ldr	w0, [x20]
	ldr	w1, [sp, #12]
Lloh49:
	adrp	x8, _IO_WIN_9_BASE_OFFSET@GOTPAGE
Lloh50:
	ldr	x8, [x8, _IO_WIN_9_BASE_OFFSET@GOTPAGEOFF]
Lloh51:
	ldr	w2, [x8]
Lloh52:
	adrp	x8, _MV_BOOTROM_MEM_ADDR@GOTPAGE
Lloh53:
	ldr	x8, [x8, _MV_BOOTROM_MEM_ADDR@GOTPAGEOFF]
Lloh54:
	ldr	w3, [x8]
	bl	_bus_space_write_4
	ldr	w0, [x20]
	ldr	w1, [sp, #12]
	ldr	w3, [x21]
Lloh55:
	adrp	x8, _BUS_SPACE_BARRIER_WRITE@GOTPAGE
Lloh56:
	ldr	x8, [x8, _BUS_SPACE_BARRIER_WRITE@GOTPAGEOFF]
Lloh57:
	ldr	w4, [x8]
	mov	w2, #0
	bl	_bus_space_barrier
	ldr	w0, [x20]
	ldr	w1, [sp, #12]
	ldr	w2, [x21]
	bl	_bus_space_unmap
LBB0_2:
	mov	x0, x19
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh55, Lloh56, Lloh57
	.loh AdrpLdrGotLdr	Lloh52, Lloh53, Lloh54
	.loh AdrpLdrGotLdr	Lloh49, Lloh50, Lloh51
	.loh AdrpLdrGotLdr	Lloh46, Lloh47, Lloh48
	.loh AdrpLdrGotLdr	Lloh43, Lloh44, Lloh45
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_fdtbus_bs_tag,4,2              ; @fdtbus_bs_tag
	.comm	_MV_MBUS_BRIDGE_BASE,8,3        ; @MV_MBUS_BRIDGE_BASE
	.comm	_MV_CPU_SUBSYS_REGS_LEN,4,2     ; @MV_CPU_SUBSYS_REGS_LEN
	.comm	_MV_BOOTROM_WIN_SIZE,4,2        ; @MV_BOOTROM_WIN_SIZE
	.comm	_IO_WIN_SIZE_MASK,4,2           ; @IO_WIN_SIZE_MASK
	.comm	_IO_WIN_SIZE_SHIFT,4,2          ; @IO_WIN_SIZE_SHIFT
	.comm	_MBUS_BOOTROM_ATTR,4,2          ; @MBUS_BOOTROM_ATTR
	.comm	_IO_WIN_ATTR_MASK,4,2           ; @IO_WIN_ATTR_MASK
	.comm	_IO_WIN_ATTR_SHIFT,4,2          ; @IO_WIN_ATTR_SHIFT
	.comm	_MBUS_BOOTROM_TGT_ID,4,2        ; @MBUS_BOOTROM_TGT_ID
	.comm	_IO_WIN_TGT_MASK,4,2            ; @IO_WIN_TGT_MASK
	.comm	_IO_WIN_TGT_SHIFT,4,2           ; @IO_WIN_TGT_SHIFT
	.comm	_IO_WIN_SYNC_MASK,4,2           ; @IO_WIN_SYNC_MASK
	.comm	_IO_WIN_SYNC_SHIFT,4,2          ; @IO_WIN_SYNC_SHIFT
	.comm	_IO_WIN_ENA_MASK,4,2            ; @IO_WIN_ENA_MASK
	.comm	_IO_WIN_ENA_SHIFT,4,2           ; @IO_WIN_ENA_SHIFT
	.comm	_IO_WIN_9_CTRL_OFFSET,4,2       ; @IO_WIN_9_CTRL_OFFSET
	.comm	_IO_WIN_9_BASE_OFFSET,4,2       ; @IO_WIN_9_BASE_OFFSET
	.comm	_MV_BOOTROM_MEM_ADDR,4,2        ; @MV_BOOTROM_MEM_ADDR
	.comm	_BUS_SPACE_BARRIER_WRITE,4,2    ; @BUS_SPACE_BARRIER_WRITE
.subsections_via_symbols
