From 51888ca25a03125e742ef84d4ddfd74e139707a0 Mon Sep 17 00:00:00 2001 From: Srivatsa Vaddagiri Date: Tue, 27 Jun 2006 02:54:38 -0700 Subject: [PATCH] sched_domain: handle kmalloc failure Try to handle mem allocation failures in build_sched_domains by bailing out and cleaning up thus-far allocated memory. The patch has a direct consequence that we disable load balancing completely (even at sibling level) upon *any* memory allocation failure. [Lee.Schermerhorn@hp.com: bugfix] Signed-off-by: Srivatsa Vaddagir Cc: Nick Piggin Cc: Ingo Molnar Cc: "Siddha, Suresh B" Signed-off-by: Lee Schermerhorn Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- include/linux/sched.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include/linux') diff --git a/include/linux/sched.h b/include/linux/sched.h index 74a1e39..ab8ffc5 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h @@ -639,7 +639,7 @@ struct sched_domain { #endif }; -extern void partition_sched_domains(cpumask_t *partition1, +extern int partition_sched_domains(cpumask_t *partition1, cpumask_t *partition2); /* -- cgit v1.1