Platform: Rename platform specific MCUBoot macros

The BOOT_MAX_IMG_SECTORS and BOOT_STATUS_MAX_ENTRIES macros in the
original MCUBoot code base are defined in bootutil_priv.h. Rename
them to avoid redefinition errors when building TF-M with upstream
MCUBoot.

Change-Id: I2e3ff105077f06bcb2ffafe3a2ac1863ec6e0478
Signed-off-by: David Vincze <david.vincze@arm.com>
diff --git a/bl2/ext/mcuboot/bootutil/src/bootutil_priv.h b/bl2/ext/mcuboot/bootutil/src/bootutil_priv.h
index a603b01..4edfcdb 100644
--- a/bl2/ext/mcuboot/bootutil/src/bootutil_priv.h
+++ b/bl2/ext/mcuboot/bootutil/src/bootutil_priv.h
@@ -21,7 +21,7 @@
  * Original code taken from mcuboot project at:
  * https://github.com/JuulLabs-OSS/mcuboot
  * Git SHA of the original version: ac55554059147fff718015be9f4bd3108123f50a
- * Modifications are Copyright (c) 2018-2019 Arm Limited.
+ * Modifications are Copyright (c) 2018-2020 Arm Limited.
  */
 
 #ifndef H_BOOTUTIL_PRIV_
@@ -129,6 +129,8 @@
 
 _Static_assert(BOOT_IMAGE_NUMBER > 0, "Invalid value for BOOT_IMAGE_NUMBER");
 
+#define BOOT_MAX_IMG_SECTORS       MCUBOOT_MAX_IMG_SECTORS
+
 /*
  * Extract the swap type and image number from image trailers's swap_info
  * field.
@@ -166,6 +168,7 @@
 
 /** Maximum number of image sectors supported by the bootloader. */
 #define BOOT_STATUS_STATE_COUNT         3
+#define BOOT_STATUS_MAX_ENTRIES         MCUBOOT_STATUS_MAX_ENTRIES
 
 #define BOOT_PRIMARY_SLOT               0
 #define BOOT_SECONDARY_SLOT             1
diff --git a/bl2/ext/mcuboot/include/target.h b/bl2/ext/mcuboot/include/target.h
index 68f1190..a812df6 100644
--- a/bl2/ext/mcuboot/include/target.h
+++ b/bl2/ext/mcuboot/include/target.h
@@ -1,6 +1,6 @@
 /*
  *  Copyright (C) 2017, Linaro Ltd
- *  Copyright (c) 2018-2019, Arm Limited.
+ *  Copyright (c) 2018-2020, Arm Limited.
  *
  *  SPDX-License-Identifier: Apache-2.0
  */
@@ -85,12 +85,12 @@
 #error "BL2 supports CMSIS flash interface and device name must be specified"
 #endif
 
-#ifndef BOOT_STATUS_MAX_ENTRIES
-#error "BOOT_STATUS_MAX_ENTRIES must be defined by the target"
+#ifndef MCUBOOT_STATUS_MAX_ENTRIES
+#error "MCUBOOT_STATUS_MAX_ENTRIES must be defined by the target"
 #endif
 
-#ifndef BOOT_MAX_IMG_SECTORS
-#error "BOOT_MAX_IMG_SECTORS must be defined by the target"
+#ifndef MCUBOOT_MAX_IMG_SECTORS
+#error "MCUBOOT_MAX_IMG_SECTORS must be defined by the target"
 #endif
 
 #endif /* H_TARGETS_TARGET_ */