[Devel] [PATCH rh7 01/11] Port diff-ve-cpuinfo-zero-all-bits-in-cap-mask

Vladimir Davydov vdavydov at virtuozzo.com
Fri Oct 16 09:22:45 PDT 2015


Author: Vladimir Davydov
Email: vdavydov at parallels.com
Subject: cpuinfo: zero all bits in cap mask
Date: Thu, 27 Sep 2012 17:05:17 +0400

The mask has 32*RHNCAPINTS bits.

Signed-off-by: Vladimir Davydov <vdavydov at parallels.com>
=============================================================================

https://jira.sw.ru/browse/PSBM-33638

Signed-off-by: Vladimir Davydov <vdavydov at virtuozzo.com>
---
 arch/x86/kernel/cpu/proc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/x86/kernel/cpu/proc.c b/arch/x86/kernel/cpu/proc.c
index 6a52fa6b7f39..1d5833a27661 100644
--- a/arch/x86/kernel/cpu/proc.c
+++ b/arch/x86/kernel/cpu/proc.c
@@ -66,7 +66,7 @@ static void init_cpu_flags(void *dummy)
 	unsigned int tmp1, tmp2;
 	int i;
 
-	bitmap_zero((unsigned long *)flags, NCAPINTS);
+	bitmap_zero((unsigned long *)flags, 32*NCAPINTS);
 	for (i = 0; i < 32*NCAPINTS; i++)
 		if (cpu_has(c, i))
 			set_bit(i, (unsigned long *)flags);
-- 
2.1.4




More information about the Devel mailing list