cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Participant
Participant
1,450 Views
Registered: ‎08-01-2017

Specify RAM size to store data while running Linux

Jump to solution

Hi,

 

I'm trying to store data in RAM while running Linux. I cannot figure out how to specify the OS that it can only use the half memory.

I already try to change to modify the "memory" field in the device tree, to add a uEnv.txt size to alter the boot procedure, to modify the zynq_zed.h file.

Maybe I'd need to configure the u-boot or the FSBL compilation, but I didn't find out how to do it.

Can someone give me a clue?

 

Already, thank you

0 Kudos
1 Solution

Accepted Solutions
Highlighted
Teacher
Teacher
2,468 Views
Registered: ‎03-31-2012

Re: Specify RAM size to store data while running Linux

Jump to solution

@crochetx you can look at the following thread to see how you can modify the device-tree to add a memory reserve section for your needs. Basically you need to do this:

 

reserved-memory {
  #address-cells = <1>;
  #size-cells = <1>;
  ranges;

  vin_reserved: vin@0x10000000 {
    reg = <0x10000000 0x40000>;
  };
};

 

https://forums.xilinx.com/t5/Embedded-Linux/Zynq-Petalinux-reserve-a-DDR-memory-region/td-p/529237/page/2

- Please mark the Answer as "Accept as solution" if information provided is helpful.
Give Kudos to a post which you think is helpful and reply oriented.

View solution in original post

0 Kudos
2 Replies
Highlighted
Teacher
Teacher
2,469 Views
Registered: ‎03-31-2012

Re: Specify RAM size to store data while running Linux

Jump to solution

@crochetx you can look at the following thread to see how you can modify the device-tree to add a memory reserve section for your needs. Basically you need to do this:

 

reserved-memory {
  #address-cells = <1>;
  #size-cells = <1>;
  ranges;

  vin_reserved: vin@0x10000000 {
    reg = <0x10000000 0x40000>;
  };
};

 

https://forums.xilinx.com/t5/Embedded-Linux/Zynq-Petalinux-reserve-a-DDR-memory-region/td-p/529237/page/2

- Please mark the Answer as "Accept as solution" if information provided is helpful.
Give Kudos to a post which you think is helpful and reply oriented.

View solution in original post

0 Kudos
Highlighted
Participant
Participant
1,409 Views
Registered: ‎08-01-2017

Re: Specify RAM size to store data while running Linux

Jump to solution

Thank you Muzzafer, now it works.

 

Thus the solution is :

  add the new field 'reserved-memory' in the device tree.

  'reg' specifies the address of the beginning of the reserved memory and its length.

 

Thank you

0 Kudos