uniphier: add a helper to get image_info

In the next commit, I will have more usecases to get struct image_info
from image ID.  It is better to make a helper function at a different
layer.  I do not need the current uniphier_image_descs_fixup() since
the code is small enough to be squashed into the caller side.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
diff --git a/plat/socionext/uniphier/uniphier_image_desc.c b/plat/socionext/uniphier/uniphier_image_desc.c
index 1e474c5..f4651db 100644
--- a/plat/socionext/uniphier/uniphier_image_desc.c
+++ b/plat/socionext/uniphier/uniphier_image_desc.c
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2017, ARM Limited and Contributors. All rights reserved.
+ * Copyright (c) 2017-2018, ARM Limited and Contributors. All rights reserved.
  *
  * SPDX-License-Identifier: BSD-3-Clause
  */
@@ -86,12 +86,11 @@
 };
 REGISTER_BL_IMAGE_DESCS(uniphier_image_descs)
 
-/* SCP is optional.  Allow run-time fixup of the descriptor array. */
-void uniphier_image_descs_fixup(void)
+struct image_info *uniphier_get_image_info(unsigned int image_id)
 {
 	struct bl_mem_params_node *desc;
 
-	desc = get_bl_mem_params_node(SCP_BL2_IMAGE_ID);
-	assert(desc != NULL);
-	desc->image_info.h.attr |= IMAGE_ATTRIB_SKIP_LOADING;
+	desc = get_bl_mem_params_node(image_id);
+	assert(desc);
+	return &desc->image_info;
 }