UPSTREAM: soc/ucb/riscv: Place CBMEM at top of autodetected RAM
BUG=None BRANCH=None TEST=None Signed-off-by: Jonathan Neuschfer <j.neuschaefer@gmx.net> Reviewed-on: https://review.coreboot.org/17595 Tested-by: build bot (Jenkins) Reviewed-by: Ronald G. Minnich <rminnich@gmail.com> Change-Id: Ida016aec11ccdb8da8d2ae1d30ddca16b069be11 Reviewed-on: https://chromium-review.googlesource.com/417071 Commit-Ready: Furquan Shaikh <furquan@chromium.org> Tested-by: Furquan Shaikh <furquan@chromium.org> Reviewed-by: Aaron Durbin <adurbin@chromium.org>
This commit is contained in:
parent
9a26711c29
commit
b3f01e9331
1 changed files with 7 additions and 2 deletions
|
|
@ -12,9 +12,14 @@
|
|||
*/
|
||||
|
||||
#include <cbmem.h>
|
||||
#include <commonlib/configstring.h>
|
||||
|
||||
void *cbmem_top(void)
|
||||
{
|
||||
// TODO: find out how RISCV stores this.
|
||||
return (void *)((uintptr_t)3*GiB);
|
||||
uintptr_t base;
|
||||
size_t size;
|
||||
|
||||
query_mem(configstring(), &base, &size);
|
||||
|
||||
return (void *)(base + size);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue