diff options
author | Furquan Shaikh <furquan@google.com> | 2014-09-04 15:21:12 -0700 |
---|---|---|
committer | Patrick Georgi <pgeorgi@google.com> | 2015-03-21 13:36:04 +0100 |
commit | 8e15963cc5583155becd783879a0bd3309cae51c (patch) | |
tree | 108ad0bf907b8e6e3f01c7aad288b32d9bac27cd /payloads/libpayload | |
parent | 732f5b55972c993f58308b198639c919b71454dc (diff) |
libpayload arm64: Add functions for reading memranges
BUG=chrome-os-partner:31634
BRANCH=None
TEST=Compiles successfully
Change-Id: I12e7cdaf07c1bc4802a04dadd85384939b5a67e0
Signed-off-by: Patrick Georgi <pgeorgi@chromium.org>
Original-Commit-Id: c454a3d60b0e087df79de4fd9cff09596ae12ca5
Original-Change-Id: Iec82d56ae4a5f1ac6243afef1f453de3905d869c
Original-Signed-off-by: Furquan Shaikh <furquan@google.com>
Original-Reviewed-on: https://chromium-review.googlesource.com/216821
Original-Tested-by: Furquan Shaikh <furquan@chromium.org>
Original-Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Original-Commit-Queue: Furquan Shaikh <furquan@chromium.org>
Reviewed-on: http://review.coreboot.org/8788
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
Diffstat (limited to 'payloads/libpayload')
-rw-r--r-- | payloads/libpayload/arch/arm64/sysinfo.c | 7 | ||||
-rw-r--r-- | payloads/libpayload/include/libpayload.h | 2 |
2 files changed, 9 insertions, 0 deletions
diff --git a/payloads/libpayload/arch/arm64/sysinfo.c b/payloads/libpayload/arch/arm64/sysinfo.c index 6d204e2dc7..28d3c4be55 100644 --- a/payloads/libpayload/arch/arm64/sysinfo.c +++ b/payloads/libpayload/arch/arm64/sysinfo.c @@ -62,3 +62,10 @@ int lib_get_sysinfo(void) return ret; } + +void lib_sysinfo_get_memranges(struct memrange **ranges, + uint64_t *nranges) +{ + *ranges = &lib_sysinfo.memrange[0]; + *nranges = lib_sysinfo.n_memranges; +} diff --git a/payloads/libpayload/include/libpayload.h b/payloads/libpayload/include/libpayload.h index 3d8417c42a..0be0d8e230 100644 --- a/payloads/libpayload/include/libpayload.h +++ b/payloads/libpayload/include/libpayload.h @@ -422,6 +422,8 @@ int get_multiboot_info(struct sysinfo_t *info); void *get_cb_header_ptr(void); int lib_get_sysinfo(void); +void lib_sysinfo_get_memranges(struct memrange **ranges, + uint64_t *nranges); /* Timer functions. */ /* Defined by each architecture. */ |