UPSTREAM: cpu/x86/mp_init: Increase AP check-in time-out to 1second

Currently, the AP check-in time-out in bsp_do_flight_plan is set to
100ms. However, as the number of APs increases, contention could
increase especially for resource like UART. This led to MP record
time-out issues on KBL platform with 7 APs and serial-console enabled
BIOS image.

This change increases the time-out value to 1 second to be on the safer
side and let APs check-in before continuing boot.

BUG=b:74085891
TEST=Verified that MP record time-out is not observed anymore on Nami.

Change-Id: Ia061d39ab504b4aa74852e9bfa33d35d90719e44
Signed-off-by: Patrick Georgi <pgeorgi@google.com>
Original-Commit-Id: fa9f107319c00563d2da4cda03ddba179c904135
Original-Change-Id: I979c11a10e6888aef0f71b5632ea803a67bbb0ff
Original-Signed-off-by: Furquan Shaikh <furquan@google.com>
Original-Reviewed-on: https://review.coreboot.org/24965
Original-Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Original-Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Original-Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/950764
Commit-Ready: Patrick Georgi <pgeorgi@chromium.org>
Tested-by: Patrick Georgi <pgeorgi@chromium.org>
Reviewed-by: Patrick Georgi <pgeorgi@chromium.org>
(cherry picked from commit f59e179d8b80000d7d3e42e27311d169b25ac46d)
Reviewed-on: https://chromium-review.googlesource.com/1054752
Reviewed-by: Furquan Shaikh <furquan@chromium.org>
Commit-Queue: Zhongze Hu <frankhu@google.com>
Tested-by: Zhongze Hu <frankhu@google.com>
diff --git a/src/cpu/x86/mp_init.c b/src/cpu/x86/mp_init.c
index baa6aec..e399128 100644
--- a/src/cpu/x86/mp_init.c
+++ b/src/cpu/x86/mp_init.c
@@ -535,7 +535,12 @@
 {
 	int i;
 	int ret = 0;
-	const int timeout_us = 100000;
+	/*
+	 * Set time-out to wait for APs to a huge value (=1 second) since it
+	 * could take a longer time for APs to check-in as the number of APs
+	 * increases (contention for resources like UART also increases).
+	 */
+	const int timeout_us = 1000000;
 	const int step_us = 100;
 	int num_aps = mp_params->num_cpus - 1;