From 4adb10c1ede9773ce018ddb3b56f5eb900f220f8 Mon Sep 17 00:00:00 2001
From: Isla Mitchell <isla.mitchell@arm.com>
Date: Fri, 14 Jul 2017 10:48:25 +0100
Subject: [PATCH] Fix order of ARM platform #includes

This fix modifies the order of #includes in ARM standard platforms
to meet the ARM TF coding standard.

Change-Id: Ide19aad6233babda4eea2d17d49e523645fed1b2
Signed-off-by: Isla Mitchell <isla.mitchell@arm.com>
---
 plat/arm/board/fvp/fvp_io_storage.c  | 2 +-
 plat/arm/board/fvp/fvp_pm.c          | 2 +-
 plat/arm/board/juno/juno_bl1_setup.c | 2 +-
 plat/arm/common/arm_bl1_setup.c      | 2 +-
 plat/arm/common/arm_bl2_setup.c      | 2 +-
 plat/arm/common/arm_bl2u_setup.c     | 2 +-
 plat/arm/common/tsp/arm_tsp_setup.c  | 2 +-
 7 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/plat/arm/board/fvp/fvp_io_storage.c b/plat/arm/board/fvp/fvp_io_storage.c
index 27bab8006..aa2ee3056 100644
--- a/plat/arm/board/fvp/fvp_io_storage.c
+++ b/plat/arm/board/fvp/fvp_io_storage.c
@@ -8,8 +8,8 @@
 #include <common_def.h>
 #include <debug.h>
 #include <io_driver.h>
-#include <io_storage.h>
 #include <io_semihosting.h>
+#include <io_storage.h>
 #include <plat_arm.h>
 #include <semihosting.h>	/* For FOPEN_MODE_... */
 
diff --git a/plat/arm/board/fvp/fvp_pm.c b/plat/arm/board/fvp/fvp_pm.c
index e39a4d50e..9a02089e7 100644
--- a/plat/arm/board/fvp/fvp_pm.c
+++ b/plat/arm/board/fvp/fvp_pm.c
@@ -10,8 +10,8 @@
 #include <debug.h>
 #include <errno.h>
 #include <mmio.h>
-#include <platform.h>
 #include <plat_arm.h>
+#include <platform.h>
 #include <psci.h>
 #include <v2m_def.h>
 #include "drivers/pwrc/fvp_pwrc.h"
diff --git a/plat/arm/board/juno/juno_bl1_setup.c b/plat/arm/board/juno/juno_bl1_setup.c
index 65b956d0d..7c026bcb7 100644
--- a/plat/arm/board/juno/juno_bl1_setup.c
+++ b/plat/arm/board/juno/juno_bl1_setup.c
@@ -6,8 +6,8 @@
 
 #include <bl_common.h>
 #include <errno.h>
-#include <platform.h>
 #include <plat_arm.h>
+#include <platform.h>
 #include <sp805.h>
 #include <tbbr_img_def.h>
 #include <v2m_def.h>
diff --git a/plat/arm/common/arm_bl1_setup.c b/plat/arm/common/arm_bl1_setup.c
index ba95d2532..6860e36bc 100644
--- a/plat/arm/common/arm_bl1_setup.c
+++ b/plat/arm/common/arm_bl1_setup.c
@@ -9,8 +9,8 @@
 #include <arm_xlat_tables.h>
 #include <bl_common.h>
 #include <console.h>
-#include <platform_def.h>
 #include <plat_arm.h>
+#include <platform_def.h>
 #include <sp805.h>
 #include <utils.h>
 #include "../../../bl1/bl1_private.h"
diff --git a/plat/arm/common/arm_bl2_setup.c b/plat/arm/common/arm_bl2_setup.c
index e5619b7f4..b7621b853 100644
--- a/plat/arm/common/arm_bl2_setup.c
+++ b/plat/arm/common/arm_bl2_setup.c
@@ -12,8 +12,8 @@
 #include <debug.h>
 #include <desc_image_load.h>
 #include <plat_arm.h>
-#include <platform_def.h>
 #include <platform.h>
+#include <platform_def.h>
 #include <string.h>
 #include <utils.h>
 
diff --git a/plat/arm/common/arm_bl2u_setup.c b/plat/arm/common/arm_bl2u_setup.c
index 5dc9eea08..03d908b16 100644
--- a/plat/arm/common/arm_bl2u_setup.c
+++ b/plat/arm/common/arm_bl2u_setup.c
@@ -8,8 +8,8 @@
 #include <arm_def.h>
 #include <bl_common.h>
 #include <console.h>
-#include <platform_def.h>
 #include <plat_arm.h>
+#include <platform_def.h>
 #include <string.h>
 
 /* Weak definitions may be overridden in specific ARM standard platform */
diff --git a/plat/arm/common/tsp/arm_tsp_setup.c b/plat/arm/common/tsp/arm_tsp_setup.c
index 2eed18783..abeaea0bc 100644
--- a/plat/arm/common/tsp/arm_tsp_setup.c
+++ b/plat/arm/common/tsp/arm_tsp_setup.c
@@ -7,9 +7,9 @@
 #include <arm_def.h>
 #include <bl_common.h>
 #include <console.h>
+#include <plat_arm.h>
 #include <platform_def.h>
 #include <platform_tsp.h>
-#include <plat_arm.h>
 
 #define BL32_END (unsigned long)(&__BL32_END__)
 
-- 
GitLab