Temporarily increase RAM available to HPS

Kernel, Main, Utilities & Applications, Miscellaneous Devices.
User avatar
shmitty
Posts: 7
Joined: Tue Jun 16, 2020 8:08 am

Temporarily increase RAM available to HPS

Unread post by shmitty »

I'm trying to temporarily make more ram available to Linux on the HPS. From what I've found in various documentation sources this should be possible through u-boot. And it should be possible to set extra u-boot args in u-boot.txt. So I set

Code: Select all

mem=1000M
in u-boot.txt but it makes no difference.
Does anyone have any idea?

Edit: I'm doing the assignment wrong. mem=1000M has to go inside another assignment, but I can't quite figure out the syntax yet...

NOTE: I've already annoyed Sorg by asking a related question through a github issue. I completely forgot about these forums. Anyway I've searched the forums for more info on this memory split between the HPS and the FPGA, but found nothing relevant to my question. So hopefully this has not been asked too many times and I don't piss off anyone any more :D

Thanks!
Michael
Locutus73
Core Developer
Posts: 51
Joined: Mon May 25, 2020 9:55 am
Has thanked: 1 time
Been thanked: 8 times

Re: Temporarily increase RAM available to HPS

Unread post by Locutus73 »

I think you need to take a look at this
https://github.com/MiSTer-devel/u-boot_ ... nano.h#L22
Probably you need the memmap parameter...
...but I’m pretty sure you’ll end with a mess: as far as I understand FPGA cores will still use all lower DDR3 512MB and will corrupt Linux memory.

Regards.

Locutus73
User avatar
Sorgelig
Site Admin
Posts: 877
Joined: Thu May 21, 2020 9:49 pm
Has thanked: 2 times
Been thanked: 211 times

Re: Temporarily increase RAM available to HPS

Unread post by Sorgelig »

You can't do it as there is frame buffers for Linux and cores just above 512MB border, so it will conflict with expanded memory.
What's the purpose of increasing the memory?
User avatar
shmitty
Posts: 7
Joined: Tue Jun 16, 2020 8:08 am

Re: Temporarily increase RAM available to HPS

Unread post by shmitty »

Locutus73, thanks!

Sorgelig, thanks. I wanted to temporarily increase the memory for an experiment I was doing copying something to /tmp tmpfs. But it turned out the problem I was having was not caused by insufficient memory.

I have been experimenting to get live setup / resize working on the mister instead of through the sd installer app on windows or various scripts on other operating systems. I know this has been attempted many times and I intend to succeed or fail trying. Learned a lot today about how it will not work. Now looking for another way to make it work. Perhaps I'll post my attempt and doubtful progress on another topic one of these days so it's not filed under this obscure "memory increase" topic. Thanks for your time!
Post Reply