LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   How Can I Find Start and Stop Memory Address for Linux Memtester Program (https://www.linuxquestions.org/questions/linux-software-2/how-can-i-find-start-and-stop-memory-address-for-linux-memtester-program-4175576064/)

danmartinj 03-28-2016 04:41 PM

How Can I Find Start and Stop Memory Address for Linux Memtester Program
 
Hello,

I am learning about the linux memtester program because I would like to use this tool to test some custom boards we are working on. I was told I would be given a start and stop physical address to test these devices. Right now I am just playing with the tool using a Ubuntu VM and I am trying to test the tool and issue a physical memory address to it.

My problem is I do not know how to determine the starting physical memory address and from most googling I have done so far there does not seem to be a clear way from userspace to get the start/stop physical memory address. Does anyone have any ideas on how I can do this? Or even how to do this from kernel land in a simple way?

Thanks in advance,

Joe

dazdaz 03-29-2016 11:47 AM

Hi,

Would be useful if you could please share more information.

What do you mean by custom boards exactly. Is this like a breadboard, such as a RaspBerry Pi device connected to physical hardware running virtualisation software ?

Are you using 32bit or 64bit hardware and OS ?

Are you intending to run the memory testing tool running from within the VM or on the Hypervisor or on bare metal or on the custom board ?

What type of virtualisation are you using.

Out of curiosity, what type of processor are you using.

Do you want to only test physical RAM or Virtual RAM as well ( presumably not ) ?

Have you populated your motherboard with SDRAM memory chips and if so how many and of what configuration.

Are there SDRAM chips or another type that you want to test on the "custom board" ?

Can you share a little more information pls.

Thanks

danmartinj 03-29-2016 01:40 PM

Hey dazdaz,

I actually have limited knowledge myself on some of these details.
As far as I know its a custom board built by some vendor which I do not know. It is running arm 64bit processor. The board appears to fit into a standard pc case. I am testing as far as I know just RAM. Matter of fact I actually just built the software on the machine today so I know memtest works on arm.

I am now trying to understand more how the program works...I am just using my vm as a way to learn the program and test it out. At the moment I know if you execute the binary with the amount of memory you want it will try to test that amount of memory. For example, on a 2G of RAM VM if I run.

./memtest 1500 1

The program will output all the tests in its test case and report on success or fail. Now I am wondering how does it determine where to start. I know it uses mmap to map the memory, malloc to access it and mlock to lock it while testing...I just feel like I am not understanding some pretty important details at the moment. The code I got from here: https://github.com/jnavila/memtester

Thanks in advance,
Joe


All times are GMT -5. The time now is 02:59 PM.