Replace hardcoded stack count with architecture specific constant
Tous les contrôles ont réussi
Builds / ExectOS (amd64, debug) (push) Successful in 41s
Builds / ExectOS (amd64, release) (push) Successful in 40s
Builds / ExectOS (i686, release) (push) Successful in 36s
Builds / ExectOS (i686, debug) (push) Successful in 37s

Cette révision appartient à :
2026-03-28 20:53:50 +01:00
Parent a608b26fde
révision e9aaeab982
3 fichiers modifiés avec 5 ajouts et 1 suppressions

Voir le fichier

@@ -111,6 +111,7 @@
/* XTOS Kernel stack size */
#define KERNEL_STACK_SIZE 0x8000
#define KERNEL_STACKS 3
/* XTOS Kernel stack guard pages */
#define KERNEL_STACK_GUARD_PAGES 1

Voir le fichier

@@ -130,6 +130,7 @@
/* XTOS Kernel stack size */
#define KERNEL_STACK_SIZE 0x4000
#define KERNEL_STACKS 2
/* XTOS Kernel stack guard pages */
#define KERNEL_STACK_GUARD_PAGES 1

Voir le fichier

@@ -128,7 +128,9 @@ MM::KernelPool::AllocateProcessorStructures(IN ULONG CpuNumber,
/* Align address to page size boundary and find a space for processor block */
Address = ROUND_UP((UINT_PTR)ProcessorStructures, MM_PAGE_SIZE);
ProcessorBlock = (PKPROCESSOR_BLOCK)((PUCHAR)Address + (2 * KERNEL_STACK_SIZE) + (GDT_ENTRIES * sizeof(KGDTENTRY)));
ProcessorBlock = (PKPROCESSOR_BLOCK)((PUCHAR)Address +
(KERNEL_STACKS * KERNEL_STACK_SIZE) +
(GDT_ENTRIES * sizeof(KGDTENTRY)));
/* Store processor number in the processor block */
ProcessorBlock->CpuNumber = CpuNumber;