From 404fc0cfa60692001adc524545c386934b3f4b44 Mon Sep 17 00:00:00 2001 From: Almudena Garcia Date: Mon, 27 Jul 2020 19:52:44 +0200 Subject: [PATCH 1/7] configfrag.ac: Define NCPUS to 255 if mach_ncpus > 1 This allows to define the size of cpus structures to the maximum value allowed by xAPIC, keeping this size independant of mach_ncpus value --- configfrag.ac | 3 +++ 1 file changed, 3 insertions(+) diff --git a/configfrag.ac b/configfrag.ac index 91d737ef..454d9f23 100644 --- a/configfrag.ac +++ b/configfrag.ac @@ -46,9 +46,12 @@ AC_DEFINE([BOOTSTRAP_SYMBOLS], [0], [BOOTSTRAP_SYMBOLS]) # Multiprocessor support is still broken. AH_TEMPLATE([MULTIPROCESSOR], [set things up for a uniprocessor]) mach_ncpus=1 +AC_DEFINE_UNQUOTED([NCPUS], [$mach_ncpus], [number of CPUs]) + AC_DEFINE_UNQUOTED([NCPUS], [$mach_ncpus], [number of CPUs]) [if [ $mach_ncpus -gt 1 ]; then] AC_DEFINE([MULTIPROCESSOR], [1], [set things up for a multiprocessor]) + AC_DEFINE_UNQUOTED([NCPUS], [255], [number of CPUs]) [fi] # Restartable Atomic Sequences to get a really fast test-n-set. Can't be -- 2.27.0