Forum Discussion
5 Replies
- Altera_Forum
Honored Contributor
You can limit the memory reserved for linux by specifying the "mem" parameter when booting the linux kernel eg.
Documented here https://www.kernel.org/doc/html/v4.14/admin-guide/kernel-parameters.html (https://www.kernel.org/doc/html/v4.14/admin-guide/kernel-parameters.html) (Search for "mem=")bootargs root=/dev/mmcblk0p2 rw rootwait console=ttyS0,115200 mem=800M - Altera_Forum
Honored Contributor
Hii Tototo
Using the cable ethernet not the uart can i use this command ? this command limit the linux to use just 800M of the DDR3 memory? so to which adress i can write to ddr3 memory from the FPGA ? - Altera_Forum
Honored Contributor
--- Quote Start --- Using the cable ethernet not the uart can i use this command ? --- Quote End --- You can set these parameters from within uBoot, independently from your connection. If you type "printenv" within uBoot you will see the entire environment variables. Probably you can spot some variables that are used for booting the kernel eg. name of the kernel image, boot parameters.... --- Quote Start --- this command limit the linux to use just 800M of the DDR3 memory? so to which adress i can write to ddr3 memory from the FPGA? --- Quote End --- You can verify this by typing
It should say something like "00000000-31ffffff : System RAM" and that is the memory range used by kernel. You can do with the rest whatever you want.cat /proc/iomem - Altera_Forum
Honored Contributor
Hii Tototo ,
when I type this command "cat /proc/iomem" it gives me root@socfpga:~# cat /proc/iomem 00000000-31ffffff : System RAM 00008000-006ed827 : Kernel code 00744000-007c355b : Kernel data ff702000-ff703fff : /soc/ethernet@ff702000 ff704000-ff704fff : /soc/dwmmc0@ff704000 ff705000-ff705fff : ff705000.spi ffa00000-ffa00fff : ff705000.spi ffb40000-ffb4fffe : /soc/usb@ffb40000 ffc00000-ffc00fff : c_can_platform ffc02000-ffc0201f : serial ffc04000-ffc04fff : /soc/i2c@ffc04000 ffc05000-ffc05fff : /soc/i2c@ffc05000 ffd02000-ffd02fff : /soc/wd@ffd02000 ffe01000-ffe01fff : /soc/amba/pdma@ffe01000 fff01000-fff01fff : fff01000.spi ffff0000-ffffffff : /soc/sram@ffff0000 means that i can do with the 0x32000000-0x40000000 whatever i want - Altera_Forum
Honored Contributor
--- Quote Start --- means that i can do with the 0x32000000-0x40000000 whatever i want --- Quote End --- As this range is not used by Linux Kernelspace nor Userspace it will have no impact on the behavior of the system. And still you can access this memory from within linux by its address :)