From 0e67e9266bfc97d4060b8591b5a8ba1b32735d88 Mon Sep 17 00:00:00 2001 From: Balazs Gerofi Date: Sun, 8 Jan 2017 11:54:18 +0900 Subject: [PATCH] ap_init(): reformat AP cores report --- kernel/ap.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/kernel/ap.c b/kernel/ap.c index 682c3fc1..beb97084 100644 --- a/kernel/ap.c +++ b/kernel/ap.c @@ -26,6 +26,16 @@ #include #include +//#define DEBUG_PRINT_AP + +#ifdef DEBUG_PRINT_AP +#define dkprintf(...) kprintf(__VA_ARGS__) +#define ekprintf(...) kprintf(__VA_ARGS__) +#else +#define dkprintf(...) do { if (0) kprintf(__VA_ARGS__); } while (0) +#define ekprintf(...) kprintf(__VA_ARGS__) +#endif + int num_processors = 1; static volatile int ap_stop = 1; @@ -93,13 +103,13 @@ void ap_init(void) if (cpu_info->hw_ids[i] == bsp_hw_id) { continue; } - kprintf("AP Booting: %d (HW ID: %d @ NUMA %d)\n", i, + dkprintf("AP Booting: %d (HW ID: %d @ NUMA %d)\n", i, cpu_info->hw_ids[i], cpu_info->nodes[i]); ihk_mc_boot_cpu(cpu_info->hw_ids[i], (unsigned long)ap_wait); num_processors++; } - kprintf("AP Booting: Done\n"); + kprintf("BSP: booted %d AP CPUs\n", cpu_info->ncpus - 1); } #include