summaryrefslogtreecommitdiff
path: root/tests/vb2_misc_tests.c
diff options
context:
space:
mode:
authorJoel Kitching <kitching@google.com>2019-03-06 18:41:33 +0800
committerchrome-bot <chrome-bot@chromium.org>2019-03-11 23:52:13 -0700
commit6988559fb77e99a6ac2fc420cf83922ea162081e (patch)
tree72335cef7c2c4026a9e67a3d06ea50774f2b01fe /tests/vb2_misc_tests.c
parent9e53b92e50165b777111f159daa2b4e3b3c8b355 (diff)
downloadvboot-6988559fb77e99a6ac2fc420cf83922ea162081e.tar.gz
vboot: move general constants to a separate header
coreboot uses the C preprocessor on its linker scripts to allow evaluation of macros when defining memory layout. Move constants from 2api.h to an independent file in order to allow for coreboot to use these constants in its memlayout file, without needing to include the entire vboot API. Note this commit creates two new header files: - firmware/2lib/include/2constants.h: contains the constants - firmware/include/vb2_constants.h: externally importable header Also, rename VB2_WORKBUF_RECOMMENDED_SIZE to VB2_FIRMWARE_WORKBUF_RECOMMENDED_SIZE for clarity. BUG=b:124141368, b:124192753 TEST=Build locally TEST=/work/vboot/src/repohooks/pre-upload.py TEST=make clean && make runtests TEST=make clean && COV=1 make coverage && make coverage_html BRANCH=none Change-Id: Id17c6955b67e51cb048b10b4be0901c0e9110a1f Signed-off-by: Joel Kitching <kitching@google.com> Reviewed-on: https://chromium-review.googlesource.com/1504490 Commit-Ready: Joel Kitching <kitching@chromium.org> Tested-by: Joel Kitching <kitching@chromium.org> Reviewed-by: Hung-Te Lin <hungte@chromium.org> Reviewed-by: Randall Spangler <rspangler@chromium.org> Reviewed-by: Julius Werner <jwerner@chromium.org>
Diffstat (limited to 'tests/vb2_misc_tests.c')
-rw-r--r--tests/vb2_misc_tests.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/vb2_misc_tests.c b/tests/vb2_misc_tests.c
index fddd49df..1bb9686f 100644
--- a/tests/vb2_misc_tests.c
+++ b/tests/vb2_misc_tests.c
@@ -15,7 +15,7 @@
#include "test_common.h"
/* Common context for tests */
-static uint8_t workbuf[VB2_WORKBUF_RECOMMENDED_SIZE]
+static uint8_t workbuf[VB2_FIRMWARE_WORKBUF_RECOMMENDED_SIZE]
__attribute__ ((aligned (VB2_WORKBUF_ALIGN)));
static struct vb2_context cc;
static struct vb2_shared_data *sd;