]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blob - src/patches/suse-2.6.27.25/patches.arch/s390-05-08-topology.patch
Revert "Move xen patchset to new version's subdir."
[people/pmueller/ipfire-2.x.git] / src / patches / suse-2.6.27.25 / patches.arch / s390-05-08-topology.patch
1 From: Gerald Schaefer <geraldsc@de.ibm.com>
2 Subject: kernel: disable cpu topology support by default
3 References: bnc#450096,LTC#50392
4
5 Symptom: System performance may be lower than expected.
6 Problem: If the hardware supports the configuration-topology facility
7 the system cpu topology information will be passed to the
8 scheduler. The scheduler bases its load balancing decisions
9 also on the cpu topology. This may have a negative performance
10 impact on machines where I/O interrupts are distributed unevenly
11 to cpus. Those cpus which are grouped together and get more I/O
12 interrupts than others will tend to have a higher average load.
13 Solution: Disable cpu topology support by default and add a kernel parameter
14 which allows to switch it on. In order to switch support on
15 topology=on needs to be added to the kernel parameter line.
16
17 Acked-by: John Jolly <jjolly@suse.de>
18 ---
19 Documentation/kernel-parameters.txt | 8 ++++++++
20 arch/s390/kernel/topology.c | 12 +++++++++++-
21 2 files changed, 19 insertions(+), 1 deletion(-)
22
23 --- a/arch/s390/kernel/topology.c
24 +++ b/arch/s390/kernel/topology.c
25 @@ -59,6 +59,7 @@ struct core_info {
26 cpumask_t mask;
27 };
28
29 +static int topology_enabled;
30 static void topology_work_fn(struct work_struct *work);
31 static struct tl_info *tl_info;
32 static struct core_info core_info;
33 @@ -79,7 +80,7 @@ cpumask_t cpu_coregroup_map(unsigned int
34 cpumask_t mask;
35
36 cpus_clear(mask);
37 - if (!machine_has_topology)
38 + if (!topology_enabled || !machine_has_topology)
39 return cpu_present_map;
40 spin_lock_irqsave(&topology_lock, flags);
41 while (core) {
42 @@ -264,6 +265,15 @@ static void topology_interrupt(__u16 cod
43 schedule_work(&topology_work);
44 }
45
46 +static int __init early_parse_topology(char *p)
47 +{
48 + if (strncmp(p, "on", 2))
49 + return 0;
50 + topology_enabled = 1;
51 + return 0;
52 +}
53 +early_param("topology", early_parse_topology);
54 +
55 static int __init init_topology_update(void)
56 {
57 int rc;
58 --- a/Documentation/kernel-parameters.txt
59 +++ b/Documentation/kernel-parameters.txt
60 @@ -2194,6 +2194,14 @@ and is between 256 and 4096 characters.
61 See comment before function dc390_setup() in
62 drivers/scsi/tmscsim.c.
63
64 + topology= [S390]
65 + Format: {off | on}
66 + Specify if the kernel should make use of the cpu
67 + topology informations if the hardware supports these.
68 + The scheduler will make use of these informations and
69 + e.g. base its process migration decisions on it.
70 + Default is off.
71 +
72 tp720= [HW,PS2]
73
74 trix= [HW,OSS] MediaTrix AudioTrix Pro