diff options
author | Joel Kitching <kitching@google.com> | 2019-08-29 13:58:52 +0800 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2019-09-23 17:54:12 +0000 |
commit | ffd42a82201423d7b82cffd755baf3d5cd5c7efc (patch) | |
tree | 744299c8a134b963e8ac117c1d62a4a5d1b51f73 /firmware/2lib | |
parent | 56b70c403ea47f7da67c69b72c84d591b8f3ce21 (diff) | |
download | vboot-ffd42a82201423d7b82cffd755baf3d5cd5c7efc.tar.gz |
vboot: fix up some more includes
Should have no extra line breaks in between local includes,
and should be sorted alphabetically.
BUG=b:124141368
TEST=make clean && make runtests
BRANCH=none
Change-Id: I83c25d30d7376712857314965a7d93f57190aa3f
Signed-off-by: Joel Kitching <kitching@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/vboot_reference/+/1776281
Tested-by: Joel Kitching <kitching@chromium.org>
Commit-Queue: Joel Kitching <kitching@chromium.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
Diffstat (limited to 'firmware/2lib')
-rw-r--r-- | firmware/2lib/2api.c | 4 | ||||
-rw-r--r-- | firmware/2lib/2common.c | 2 | ||||
-rw-r--r-- | firmware/2lib/2crc8.c | 2 | ||||
-rw-r--r-- | firmware/2lib/2hmac.c | 4 | ||||
-rw-r--r-- | firmware/2lib/2misc.c | 4 | ||||
-rw-r--r-- | firmware/2lib/2nvstorage.c | 4 | ||||
-rw-r--r-- | firmware/2lib/2rsa.c | 2 | ||||
-rw-r--r-- | firmware/2lib/2secdata_firmware.c | 2 | ||||
-rw-r--r-- | firmware/2lib/2secdata_fwmp.c | 2 | ||||
-rw-r--r-- | firmware/2lib/2secdata_kernel.c | 2 | ||||
-rw-r--r-- | firmware/2lib/2sha1.c | 2 | ||||
-rw-r--r-- | firmware/2lib/2sha256.c | 2 | ||||
-rw-r--r-- | firmware/2lib/2sha512.c | 2 | ||||
-rw-r--r-- | firmware/2lib/2sha_utility.c | 2 | ||||
-rw-r--r-- | firmware/2lib/2stub.c | 2 | ||||
-rw-r--r-- | firmware/2lib/2tpm_bootmode.c | 2 | ||||
-rw-r--r-- | firmware/2lib/include/2return_codes.h | 2 |
17 files changed, 22 insertions, 20 deletions
diff --git a/firmware/2lib/2api.c b/firmware/2lib/2api.c index 7e168cb0..5be542bc 100644 --- a/firmware/2lib/2api.c +++ b/firmware/2lib/2api.c @@ -6,14 +6,14 @@ * (Firmware portion) */ -#include "2sysincludes.h" #include "2api.h" #include "2common.h" #include "2misc.h" #include "2nvstorage.h" +#include "2rsa.h" #include "2secdata.h" #include "2sha.h" -#include "2rsa.h" +#include "2sysincludes.h" #include "2tpm_bootmode.h" void vb2api_fail(struct vb2_context *ctx, uint8_t reason, uint8_t subcode) diff --git a/firmware/2lib/2common.c b/firmware/2lib/2common.c index c0eb4479..6da2fc3e 100644 --- a/firmware/2lib/2common.c +++ b/firmware/2lib/2common.c @@ -6,10 +6,10 @@ * (Firmware portion) */ -#include "2sysincludes.h" #include "2common.h" #include "2rsa.h" #include "2sha.h" +#include "2sysincludes.h" vb2_error_t vb2_safe_memcmp(const void *s1, const void *s2, size_t size) { diff --git a/firmware/2lib/2crc8.c b/firmware/2lib/2crc8.c index d5284de6..2760f270 100644 --- a/firmware/2lib/2crc8.c +++ b/firmware/2lib/2crc8.c @@ -5,8 +5,8 @@ * Very simple 8-bit CRC function. */ -#include "2sysincludes.h" #include "2crc8.h" +#include "2sysincludes.h" /* Uses CRC-8 ITU version, with x^8 + x^2 + x + 1 polynomial. Note that result will evaluate to zero for a buffer of all zeroes. */ diff --git a/firmware/2lib/2hmac.c b/firmware/2lib/2hmac.c index 651ae57f..d67da42c 100644 --- a/firmware/2lib/2hmac.c +++ b/firmware/2lib/2hmac.c @@ -3,9 +3,9 @@ * found in the LICENSE file. */ -#include "2sysincludes.h" -#include "2sha.h" #include "2hmac.h" +#include "2sha.h" +#include "2sysincludes.h" int hmac(enum vb2_hash_algorithm alg, const void *key, uint32_t key_size, diff --git a/firmware/2lib/2misc.c b/firmware/2lib/2misc.c index c3cae7c2..396a1593 100644 --- a/firmware/2lib/2misc.c +++ b/firmware/2lib/2misc.c @@ -5,14 +5,14 @@ * Misc functions which need access to vb2_context but are not public APIs */ -#include "2sysincludes.h" #include "2api.h" #include "2common.h" #include "2misc.h" #include "2nvstorage.h" +#include "2rsa.h" #include "2secdata.h" #include "2sha.h" -#include "2rsa.h" +#include "2sysincludes.h" vb2_error_t vb2_validate_gbb_signature(uint8_t *sig) { diff --git a/firmware/2lib/2nvstorage.c b/firmware/2lib/2nvstorage.c index be23cbbc..36926ffb 100644 --- a/firmware/2lib/2nvstorage.c +++ b/firmware/2lib/2nvstorage.c @@ -5,12 +5,12 @@ /* Non-volatile storage routines */ -#include "2sysincludes.h" #include "2common.h" #include "2crc8.h" #include "2misc.h" -#include "2nvstorage.h" #include "2nvstorage_fields.h" +#include "2nvstorage.h" +#include "2sysincludes.h" static void vb2_nv_regen_crc(struct vb2_context *ctx) { diff --git a/firmware/2lib/2rsa.c b/firmware/2lib/2rsa.c index 199c1c2e..5d84ecd6 100644 --- a/firmware/2lib/2rsa.c +++ b/firmware/2lib/2rsa.c @@ -9,10 +9,10 @@ * multiple RSA key lengths and hash digest algorithms. */ -#include "2sysincludes.h" #include "2common.h" #include "2rsa.h" #include "2sha.h" +#include "2sysincludes.h" #include "vboot_test.h" /** diff --git a/firmware/2lib/2secdata_firmware.c b/firmware/2lib/2secdata_firmware.c index 6f5d2178..1d3c855d 100644 --- a/firmware/2lib/2secdata_firmware.c +++ b/firmware/2lib/2secdata_firmware.c @@ -5,12 +5,12 @@ * Secure storage APIs */ -#include "2sysincludes.h" #include "2common.h" #include "2crc8.h" #include "2misc.h" #include "2secdata.h" #include "2secdata_struct.h" +#include "2sysincludes.h" vb2_error_t vb2api_secdata_firmware_check(struct vb2_context *ctx) { diff --git a/firmware/2lib/2secdata_fwmp.c b/firmware/2lib/2secdata_fwmp.c index d4fda283..7d19fca4 100644 --- a/firmware/2lib/2secdata_fwmp.c +++ b/firmware/2lib/2secdata_fwmp.c @@ -5,8 +5,8 @@ * Firmware management parameters (FWMP) APIs */ -#include "2crc8.h" #include "2common.h" +#include "2crc8.h" #include "2misc.h" #include "2secdata.h" #include "2secdata_struct.h" diff --git a/firmware/2lib/2secdata_kernel.c b/firmware/2lib/2secdata_kernel.c index 2be219f5..5dbd4dde 100644 --- a/firmware/2lib/2secdata_kernel.c +++ b/firmware/2lib/2secdata_kernel.c @@ -5,12 +5,12 @@ * Secure storage APIs - kernel version space */ -#include "2sysincludes.h" #include "2common.h" #include "2crc8.h" #include "2misc.h" #include "2secdata.h" #include "2secdata_struct.h" +#include "2sysincludes.h" vb2_error_t vb2api_secdata_kernel_check(struct vb2_context *ctx) { diff --git a/firmware/2lib/2sha1.c b/firmware/2lib/2sha1.c index 41c83174..a2414143 100644 --- a/firmware/2lib/2sha1.c +++ b/firmware/2lib/2sha1.c @@ -6,9 +6,9 @@ * Open Source Project (platorm/system/core.git/libmincrypt/sha.c */ -#include "2sysincludes.h" #include "2common.h" #include "2sha.h" +#include "2sysincludes.h" /* * Some machines lack byteswap.h and endian.h. These have to use the diff --git a/firmware/2lib/2sha256.c b/firmware/2lib/2sha256.c index d2cf6726..139745f4 100644 --- a/firmware/2lib/2sha256.c +++ b/firmware/2lib/2sha256.c @@ -35,9 +35,9 @@ * SUCH DAMAGE. */ -#include "2sysincludes.h" #include "2common.h" #include "2sha.h" +#include "2sysincludes.h" #define SHFR(x, n) (x >> n) #define ROTR(x, n) ((x >> n) | (x << ((sizeof(x) << 3) - n))) diff --git a/firmware/2lib/2sha512.c b/firmware/2lib/2sha512.c index e1f2601f..ee78ec2b 100644 --- a/firmware/2lib/2sha512.c +++ b/firmware/2lib/2sha512.c @@ -35,9 +35,9 @@ * SUCH DAMAGE. */ -#include "2sysincludes.h" #include "2common.h" #include "2sha.h" +#include "2sysincludes.h" #define SHFR(x, n) (x >> n) #define ROTR(x, n) ((x >> n) | (x << ((sizeof(x) << 3) - n))) diff --git a/firmware/2lib/2sha_utility.c b/firmware/2lib/2sha_utility.c index cc36b99f..a267edde 100644 --- a/firmware/2lib/2sha_utility.c +++ b/firmware/2lib/2sha_utility.c @@ -5,9 +5,9 @@ * Utility functions for message digest functions. */ -#include "2sysincludes.h" #include "2common.h" #include "2sha.h" +#include "2sysincludes.h" #if VB2_SUPPORT_SHA1 #define CTH_SHA1 VB2_HASH_SHA1 diff --git a/firmware/2lib/2stub.c b/firmware/2lib/2stub.c index 00c5d9b2..f7e680d6 100644 --- a/firmware/2lib/2stub.c +++ b/firmware/2lib/2stub.c @@ -8,8 +8,8 @@ #include <stdarg.h> #include <stdio.h> -#include "2sysincludes.h" #include "2api.h" +#include "2sysincludes.h" __attribute__((weak)) void vb2ex_printf(const char *func, const char *fmt, ...) diff --git a/firmware/2lib/2tpm_bootmode.c b/firmware/2lib/2tpm_bootmode.c index 6903fe87..81f6c40b 100644 --- a/firmware/2lib/2tpm_bootmode.c +++ b/firmware/2lib/2tpm_bootmode.c @@ -5,9 +5,9 @@ * Functions for updating the TPM state with the status of boot path. */ -#include "2sysincludes.h" #include "2common.h" #include "2sha.h" +#include "2sysincludes.h" #include "2tpm_bootmode.h" /* diff --git a/firmware/2lib/include/2return_codes.h b/firmware/2lib/include/2return_codes.h index bc612344..ed34109e 100644 --- a/firmware/2lib/include/2return_codes.h +++ b/firmware/2lib/include/2return_codes.h @@ -6,6 +6,8 @@ #ifndef VBOOT_REFERENCE_2RETURN_CODES_H_ #define VBOOT_REFERENCE_2RETURN_CODES_H_ +#include "2sysincludes.h" + /* * Functions which return an error all return this type. This is a 32-bit * value rather than an int so it's consistent across different architectures. |