MINOR: global: add option to disable numa detection

Render numa detection optional with a global configuration statement
'no numa-cpu-mapping'. This can be used if the applied affinity of the
algorithm is not optimal. Also complete the documentation with this new
keyword.
diff --git a/src/cfgparse-global.c b/src/cfgparse-global.c
index 89e3b10..47de32a 100644
--- a/src/cfgparse-global.c
+++ b/src/cfgparse-global.c
@@ -42,7 +42,8 @@
 	"log-send-hostname", "server-state-base", "server-state-file",
 	"log-tag", "spread-checks", "max-spread-checks", "cpu-map", "setenv",
 	"presetenv", "unsetenv", "resetenv", "strict-limits", "localpeer",
-	"defaults", "listen", "frontend", "backend", "peers", "resolvers",
+	"numa-cpu-mapping", "defaults", "listen", "frontend", "backend",
+	"peers", "resolvers",
 	NULL /* must be last */
 };
 
@@ -1288,6 +1289,9 @@
 		}
 		setenv("HAPROXY_LOCALPEER", localpeer, 1);
 	}
+	else if (strcmp(args[0], "numa-cpu-mapping") == 0) {
+		global.numa_cpu_mapping = (kwm == KWM_NO) ? 0 : 1;
+	}
 	else {
 		struct cfg_kw_list *kwl;
 		const char *best;
diff --git a/src/cfgparse.c b/src/cfgparse.c
index 25820bc..507d072 100644
--- a/src/cfgparse.c
+++ b/src/cfgparse.c
@@ -1846,10 +1846,12 @@
 		if (kwm != KWM_STD && strcmp(args[0], "option") != 0 &&
 		    strcmp(args[0], "log") != 0 && strcmp(args[0], "busy-polling") != 0 &&
 		    strcmp(args[0], "set-dumpable") != 0 && strcmp(args[0], "strict-limits") != 0 &&
-		    strcmp(args[0], "insecure-fork-wanted") != 0) {
+		    strcmp(args[0], "insecure-fork-wanted") != 0 &&
+		    strcmp(args[0], "numa-cpu-mapping") != 0) {
 			ha_alert("parsing [%s:%d]: negation/default currently "
 				 "supported only for options, log, busy-polling, "
-				 "set-dumpable, strict-limits, and insecure-fork-wanted.\n", file, linenum);
+				 "set-dumpable, strict-limits, insecure-fork-wanted "
+				 "and numa-cpu-mapping.\n", file, linenum);
 			err_code |= ERR_ALERT | ERR_FATAL;
 			fatal++;
 		}
@@ -2189,7 +2191,7 @@
 		if (global.nbproc == 1) {
 			int numa_cores = 0;
 #if defined(__linux__) && defined USE_CPU_AFFINITY
-			if (!thread_cpu_mask_forced())
+			if (global.numa_cpu_mapping && !thread_cpu_mask_forced())
 				numa_cores = numa_detect_topology();
 #endif
 			global.nbthread = numa_cores ? numa_cores :
diff --git a/src/haproxy.c b/src/haproxy.c
index 58e9e62..b89c517 100644
--- a/src/haproxy.c
+++ b/src/haproxy.c
@@ -160,6 +160,7 @@
 struct global global = {
 	.hard_stop_after = TICK_ETERNITY,
 	.nbproc = 1,
+	.numa_cpu_mapping = 1,
 	.nbthread = 0,
 	.req_count = 0,
 	.logsrvs = LIST_HEAD_INIT(global.logsrvs),