summaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorHeiko Carstens <heiko.carstens@de.ibm.com>2008-12-03 13:40:46 +0100
committerMartin Schwidefsky <schwidefsky@de.ibm.com>2008-12-03 13:40:49 +0100
commita3cf4932e16e169165d0d4fd223063cd5d136785 (patch)
treea0e3753fbff153a3d43c047c8df660901cd2c38f /arch
parent3c57e6e9db88cd5a04ae395ea34135526f117675 (diff)
[S390] cpu topology: introduce kernel parameter
Introduce a topology=[on|off] kernel parameter which allows to switch cpu topology on/off. Default will be off, since it looks like that for some workloards this doesn't behave very well (on s390). Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/s390/kernel/topology.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/arch/s390/kernel/topology.c b/arch/s390/kernel/topology.c
index 586c5e33b3f4..22024b3ac993 100644
--- a/arch/s390/kernel/topology.c
+++ b/arch/s390/kernel/topology.c
@@ -57,6 +57,7 @@ struct core_info {
cpumask_t mask;
};
+static int topology_enabled;
static void topology_work_fn(struct work_struct *work);
static struct tl_info *tl_info;
static struct core_info core_info;
@@ -77,7 +78,7 @@ cpumask_t cpu_coregroup_map(unsigned int cpu)
cpumask_t mask;
cpus_clear(mask);
- if (!machine_has_topology)
+ if (!topology_enabled || !machine_has_topology)
return cpu_possible_map;
spin_lock_irqsave(&topology_lock, flags);
while (core) {
@@ -262,6 +263,15 @@ static void topology_interrupt(__u16 code)
schedule_work(&topology_work);
}
+static int __init early_parse_topology(char *p)
+{
+ if (strncmp(p, "on", 2))
+ return 0;
+ topology_enabled = 1;
+ return 0;
+}
+early_param("topology", early_parse_topology);
+
static int __init init_topology_update(void)
{
int rc;