[PATCH v2 3/4] crash: ARM: get online CPUs from cpu_active_mask

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



For ARM32 platfrom, The system will "offline" all CPUs except the
crashing one, by clear the cpu_online_mask. So we need find another
way to get online-CPUs number for crash utility.

This patch uses MAX(get_cpus_active(),get_cpus_online()) to get that
value.

Signed-off-by: Liu Hua <sdu.liu@xxxxxxxxxx>
---
 arm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arm.c b/arm.c
index 3c38cd5..84dd3ec 100644
--- a/arm.c
+++ b/arm.c
@@ -1518,7 +1518,7 @@ arm_display_machine_stats(void)
 static int
 arm_get_smp_cpus(void)
 {
-	return get_cpus_online();
+	return MAX(get_cpus_active(), get_cpus_online());
 }
 
 /*
-- 
1.9.0

--
Crash-utility mailing list
Crash-utility@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/crash-utility




[Index of Archives]     [Fedora Development]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [KDE Users]     [Fedora Tools]

 

Powered by Linux