sched: Dynamically extend the pid hash table

Change-Id: I3a719bc575cd408cd530a39efa203f507b44fa9c
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
This commit is contained in:
Jiuzhu Dong
2021-06-15 16:45:40 +08:00
committed by Xiang Xiao
parent bb867a38fc
commit 9b1f554429
15 changed files with 142 additions and 107 deletions
+7
View File
@@ -318,6 +318,13 @@ config Z180_TOOLCHAIN_SDCCW
endchoice
config Z180_MAX_TASKS
int "Max number of tasks for arch chip z180"
default 8
---help---
The maximum number of simultaneously active tasks. This value must be
a power of two.
config LINKER_HOME_AREA
hex "Physical start of _HOME area"
default 0x0000
+2 -2
View File
@@ -58,7 +58,7 @@
****************************************************************************/
static GRAN_HANDLE g_physhandle;
static struct z180_cbr_s g_cbrs[CONFIG_MAX_TASKS];
static struct z180_cbr_s g_cbrs[CONFIG_Z180_MAX_TASKS];
/****************************************************************************
* Private Functions
@@ -79,7 +79,7 @@ static inline FAR struct z180_cbr_s *z180_mmu_alloccbr(void)
{
int i;
for (i = 0; i < CONFIG_MAX_TASKS; i++)
for (i = 0; i < CONFIG_Z180_MAX_TASKS; i++)
{
FAR struct z180_cbr_s *cbr = &g_cbrs[i];
if (cbr->crefs == 0)