summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorIsla Mitchell <isla.mitchell@arm.com>2017-07-11 14:54:08 +0100
committerIsla Mitchell <isla.mitchell@arm.com>2017-07-12 14:45:31 +0100
commit2a4b4b71ba8a14148708719077d80889faa6f47b (patch)
treea6c11e34542ef63da6276bacc68590e765fdeaae /tools
parentca5ba394cab0c4e7c5621a50a7bd270cb64cec97 (diff)
Fix order of #includes
This fix modifies the order of system includes to meet the ARM TF coding standard. There are some exceptions in order to retain header groupings, minimise changes to imported headers, and where there are headers within the #if and #ifndef statements. Change-Id: I65085a142ba6a83792b26efb47df1329153f1624 Signed-off-by: Isla Mitchell <isla.mitchell@arm.com>
Diffstat (limited to 'tools')
-rw-r--r--tools/cert_create/include/ext.h2
-rw-r--r--tools/cert_create/src/cmd_opt.c2
-rw-r--r--tools/cert_create/src/main.c2
-rw-r--r--tools/cert_create/src/sha.c2
-rw-r--r--tools/fiptool/fiptool.c1
-rw-r--r--tools/fiptool/fiptool.h3
-rw-r--r--tools/fiptool/tbbr_config.c3
7 files changed, 7 insertions, 8 deletions
diff --git a/tools/cert_create/include/ext.h b/tools/cert_create/include/ext.h
index 2aa17e25..d432e639 100644
--- a/tools/cert_create/include/ext.h
+++ b/tools/cert_create/include/ext.h
@@ -7,8 +7,8 @@
#ifndef EXT_H_
#define EXT_H_
-#include "key.h"
#include <openssl/x509v3.h>
+#include "key.h"
/* Extension types supported */
enum ext_type_e {
diff --git a/tools/cert_create/src/cmd_opt.c b/tools/cert_create/src/cmd_opt.c
index 0d47872e..64180d1f 100644
--- a/tools/cert_create/src/cmd_opt.c
+++ b/tools/cert_create/src/cmd_opt.c
@@ -5,10 +5,10 @@
*/
#include <assert.h>
+#include <cmd_opt.h>
#include <getopt.h>
#include <stddef.h>
#include <stdlib.h>
-#include <cmd_opt.h>
#include "debug.h"
/* Command line options */
diff --git a/tools/cert_create/src/main.c b/tools/cert_create/src/main.c
index 99236370..f14601c8 100644
--- a/tools/cert_create/src/main.c
+++ b/tools/cert_create/src/main.c
@@ -30,8 +30,8 @@
#include "ext.h"
#include "key.h"
#include "sha.h"
-#include "tbbr/tbb_ext.h"
#include "tbbr/tbb_cert.h"
+#include "tbbr/tbb_ext.h"
#include "tbbr/tbb_key.h"
/*
diff --git a/tools/cert_create/src/sha.c b/tools/cert_create/src/sha.c
index 5d5e9e21..29715930 100644
--- a/tools/cert_create/src/sha.c
+++ b/tools/cert_create/src/sha.c
@@ -4,8 +4,8 @@
* SPDX-License-Identifier: BSD-3-Clause
*/
-#include <stdio.h>
#include <openssl/sha.h>
+#include <stdio.h>
#include "debug.h"
diff --git a/tools/fiptool/fiptool.c b/tools/fiptool/fiptool.c
index 4d80f2f1..65e4a25c 100644
--- a/tools/fiptool/fiptool.c
+++ b/tools/fiptool/fiptool.c
@@ -19,7 +19,6 @@
#include <unistd.h>
#include <openssl/sha.h>
-
#include <firmware_image_package.h>
#include "fiptool.h"
diff --git a/tools/fiptool/fiptool.h b/tools/fiptool/fiptool.h
index 4b5cdd91..889b0fde 100644
--- a/tools/fiptool/fiptool.h
+++ b/tools/fiptool/fiptool.h
@@ -7,10 +7,11 @@
#ifndef __FIPTOOL_H__
#define __FIPTOOL_H__
+#include <firmware_image_package.h>
+
#include <stddef.h>
#include <stdint.h>
-#include <firmware_image_package.h>
#include <uuid.h>
#define NELEM(x) (sizeof (x) / sizeof *(x))
diff --git a/tools/fiptool/tbbr_config.c b/tools/fiptool/tbbr_config.c
index 7c6c24be..6231cd4e 100644
--- a/tools/fiptool/tbbr_config.c
+++ b/tools/fiptool/tbbr_config.c
@@ -4,9 +4,8 @@
* SPDX-License-Identifier: BSD-3-Clause
*/
-#include <stddef.h>
-
#include <firmware_image_package.h>
+#include <stddef.h>
#include "tbbr_config.h"