feat(gpt): statically allocate bitlocks array
Statically allocate 'gpt_bitlock' array of fine-grained
'bitlock_t' data structures in arm_bl31_setup.c.
The amount of memory needed for this array is controlled
by 'RME_GPT_BITLOCK_BLOCK' build option and 'PLAT_ARM_PPS'
macro defined in platform_def.h which specifies the size
of protected physical address space in bytes.
'PLAT_ARM_PPS' takes values from 4GB to 4PB supported by
Arm architecture.
Change-Id: Icf620b5039e45df6828d58fca089cad83b0bc669
Signed-off-by: AlexeiFedorov <Alexei.Fedorov@arm.com>
diff --git a/lib/gpt_rme/gpt_rme_private.h b/lib/gpt_rme/gpt_rme_private.h
index 31dad20..78d1cec 100644
--- a/lib/gpt_rme/gpt_rme_private.h
+++ b/lib/gpt_rme/gpt_rme_private.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2022-2024, Arm Limited. All rights reserved.
+ * Copyright (c) 2022-2025, Arm Limited. All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*/
@@ -7,9 +7,7 @@
#ifndef GPT_RME_PRIVATE_H
#define GPT_RME_PRIVATE_H
-#include <arch.h>
#include <lib/gpt_rme/gpt_rme.h>
-#include <lib/spinlock.h>
#include <lib/utils_def.h>
/******************************************************************************/
@@ -141,10 +139,6 @@
PGS_64KB_P = 16U
} gpt_p_val_e;
-#define LOCK_SIZE sizeof(((bitlock_t *)NULL)->lock)
-#define LOCK_TYPE typeof(((bitlock_t *)NULL)->lock)
-#define LOCK_BITS (LOCK_SIZE * 8U)
-
/*
* Internal structure to retrieve the values from get_gpi_params();
*/