Is changing u-boot config for reserved memory interfering with mender u-boot?

Hi!

I am running with the following bblayer setup for a rasberrypi 3a+ board project.

  • meta-oe
  • meta-python
  • meta-multimedia
  • meta-networking
  • meta-raspberrypi
  • meta-mender-core
  • meta-mender-raspberrypi
  • custom

I am facing the problem that even the rpi has 512 MB of ram only 256 MB is accessible by the running applications. The other 256 MB of memory are reserved by kernel CMD (contiguous memory allocator) and compared to rasbpian which only uses 8 MB for CMD.

Q1: It seems to be strange that 256 MB ram is reserved for the kernel by default since it is only 8 MB on the raspbian-buster distro. Is this standard what you get with the above bblayer setup without any tweaking?

Q2: I think this could be changed by changing somehow the boot arguments for the kernel. Is this a problem for mender u-boot?

Q3: How can this be done? Any advice where to start (maybe an example) would be very helpful.

Regards,
Markus

Hi @markus4dev,

Q1: It seems to be strange that 256 MB ram is reserved for the kernel by default since it is only 8 MB on the raspbian-buster distro. Is this standard what you get with the above bblayer setup without any tweaking?

I would assume that there are different defaults in Raspbian and in meta-raspberrypi.

Q2: I think this could be changed by changing somehow the boot arguments for the kernel. Is this a problem for mender u-boot?

This should not interfere with Mender functionality.

Q3: How can this be done? Any advice where to start (maybe an example) would be very helpful.

Strictly speaking this is not related to Mender functionality, but I belive this is controled by the gpu_mem argument you can find in /uboot/config.txt.

You should also be able to change this during build time using the options mentioned here, https://github.com/agherzan/meta-raspberrypi/blob/master/docs/extra-build-config.md#gpu-memory

Thanks @mirzak!

I understand that this is not mender specific, I wanted to check that tweaking u-boot is not interfering with mender u-boot integration.

I have already set GPU=16 MB in confix.txt and seen the affect. Still the other 256 MB are not usable for the user space.

I guess I need add my own kernel recipe to add a boot cmd that sets cmd= 8192K like it is on raspbian.

Regards,
Markus