]> git.ipfire.org Git - thirdparty/u-boot.git/commit
cmd: mem: add command for getting ram size for use in scripts
authorFrank Wunderlich <frank-w@public-files.de>
Wed, 4 Feb 2026 18:40:42 +0000 (19:40 +0100)
committerTom Rini <trini@konsulko.com>
Sat, 7 Feb 2026 17:51:33 +0000 (11:51 -0600)
commite202eca183b0f1d6747b934482dc6249abdd742b
treec4369e3a05c594dae1ae1feeb04e2faa3d82047c
parent6b2d05748cf3cd6ba417a96c00602b0122e10af6
cmd: mem: add command for getting ram size for use in scripts

Add a command for getting detected ram size with possibility to
assign it to an environment variable.

example usage:

BPI-R4> memsize
4096 MiB
BPI-R4> memsize memsz
BPI-R4> printenv memsz
memsz=4096
BPI-R4>

board with 8GB ram:

BPI-R4> memsize
8192 MiB
BPI-R4> memsize memsz
BPI-R4> printenv memsz
memsz=8192
BPI-R4>

Signed-off-by: Frank Wunderlich <frank-w@public-files.de>
cmd/Kconfig
cmd/meminfo.c