lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  PHC 
Open Source and information security mailing list archives
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Thu, 22 May 2014 05:27:24 -0700
From:	tip-bot for Vincent Guittot <>
Subject: [tip:sched/core] sched/numa:
  Fix initialization of sched_domain_topology for NUMA

Commit-ID:  c515db8cd311ef77b2dc7cbd6b695022655bb0f3
Author:     Vincent Guittot <>
AuthorDate: Tue, 13 May 2014 11:11:01 +0200
Committer:  Ingo Molnar <>
CommitDate: Thu, 22 May 2014 11:16:29 +0200

sched/numa: Fix initialization of sched_domain_topology for NUMA

Jet Chen has reported a kernel panics when booting qemu-system-x86_64 with
kvm64 cpu. A panic occured while building the sched_domain.

In sched_init_numa, we create a new topology table in which both default
levels and numa levels are copied. The last row of the table must have a null
pointer in the mask field.

The current implementation doesn't add this last row in the computation of the
table size. So we add 1 row in the allocation size that will be used as the
last row of the table. The kzalloc will ensure that the mask field is NULL.

Reported-by: Jet Chen <>
Tested-by: Jet Chen <>
Signed-off-by: Vincent Guittot <>
Signed-off-by: Peter Zijlstra <>
Signed-off-by: Ingo Molnar <>
 kernel/sched/core.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/sched/core.c b/kernel/sched/core.c
index a78c5b6..45d077e 100644
--- a/kernel/sched/core.c
+++ b/kernel/sched/core.c
@@ -6231,7 +6231,7 @@ static void sched_init_numa(void)
 	/* Compute default topology size */
 	for (i = 0; sched_domain_topology[i].mask; i++);
-	tl = kzalloc((i + level) *
+	tl = kzalloc((i + level + 1) *
 			sizeof(struct sched_domain_topology_level), GFP_KERNEL);
 	if (!tl)
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

Powered by blists - more mailing lists