	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function brcmf_pcie_adjust_ramsize
_brcmf_pcie_adjust_ramsize:             ## @brcmf_pcie_adjust_ramsize
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	_BRCMF_RAMSIZE_OFFSET@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	leal	8(%rax), %ecx
	cmpl	%edx, %ecx
	jg	LBB0_3
## %bb.1:
	movq	%rdi, %r14
	leaq	(%rsi,%rax,4), %rbx
	movq	%rbx, %rdi
	callq	_le32_to_cpup
	movq	_BRCMF_RAMSIZE_MAGIC@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_3
## %bb.2:
	addq	$4, %rbx
	movq	%rbx, %rdi
	callq	_le32_to_cpup
	movq	%rax, %rbx
	movq	_PCIE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	movl	%ebx, %edx
	callq	_brcmf_dbg
	movq	(%r14), %rax
	movl	%ebx, (%rax)
LBB0_3:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_BRCMF_RAMSIZE_OFFSET,4,2       ## @BRCMF_RAMSIZE_OFFSET
	.comm	_BRCMF_RAMSIZE_MAGIC,8,3        ## @BRCMF_RAMSIZE_MAGIC
	.comm	_PCIE,4,2                       ## @PCIE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Found ramsize info in FW, adjusting to 0x%x\n"

	.no_dead_strip	_brcmf_pcie_adjust_ramsize
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function brcmf_pcie_adjust_ramsize
_brcmf_pcie_adjust_ramsize:             ; @brcmf_pcie_adjust_ramsize
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
Lloh0:
	adrp	x8, _BRCMF_RAMSIZE_OFFSET@GOTPAGE
Lloh1:
	ldr	x8, [x8, _BRCMF_RAMSIZE_OFFSET@GOTPAGEOFF]
Lloh2:
	ldrsw	x8, [x8]
	add	w9, w8, #8
	cmp	w9, w2
	b.gt	LBB0_3
; %bb.1:
	mov	x19, x0
	add	x20, x1, x8, lsl #2
	mov	x0, x20
	bl	_le32_to_cpup
Lloh3:
	adrp	x8, _BRCMF_RAMSIZE_MAGIC@GOTPAGE
Lloh4:
	ldr	x8, [x8, _BRCMF_RAMSIZE_MAGIC@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_3
; %bb.2:
	add	x0, x20, #4
	bl	_le32_to_cpup
	mov	x20, x0
Lloh6:
	adrp	x8, _PCIE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _PCIE@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
Lloh9:
	adrp	x1, l_.str@PAGE
Lloh10:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x20
	bl	_brcmf_dbg
	ldr	x8, [x19]
	str	w20, [x8]
LBB0_3:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_BRCMF_RAMSIZE_OFFSET,4,2       ; @BRCMF_RAMSIZE_OFFSET
	.comm	_BRCMF_RAMSIZE_MAGIC,8,3        ; @BRCMF_RAMSIZE_MAGIC
	.comm	_PCIE,4,2                       ; @PCIE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Found ramsize info in FW, adjusting to 0x%x\n"

	.no_dead_strip	_brcmf_pcie_adjust_ramsize
.subsections_via_symbols
