]> xenbits.xensource.com Git - people/ssmith/netchannel2-pvops.bak.git/.git/log
people/ssmith/netchannel2-pvops.bak.git/.git
16 years agoMerge branch 'core/urgent'
Ingo Molnar [Tue, 12 May 2009 14:31:24 +0000 (16:31 +0200)]
Merge branch 'core/urgent'

16 years agolockdep: increase MAX_LOCKDEP_ENTRIES
Ingo Molnar [Tue, 12 May 2009 14:29:13 +0000 (16:29 +0200)]
lockdep: increase MAX_LOCKDEP_ENTRIES

Now that lockdep coverage has increased it has become easier to
run out of entries:

[   21.401387] BUG: MAX_LOCKDEP_ENTRIES too low!
[   21.402007] turning off the locking correctness validator.
[   21.402007] Pid: 1555, comm: S99local Not tainted 2.6.30-rc5-tip #2
[   21.402007] Call Trace:
[   21.402007]  [<ffffffff81069789>] add_lock_to_list+0x53/0xba
[   21.402007]  [<ffffffff810eb615>] ? lookup_mnt+0x19/0x53
[   21.402007]  [<ffffffff8106be14>] check_prev_add+0x14b/0x1c7
[   21.402007]  [<ffffffff8106c304>] validate_chain+0x474/0x52a
[   21.402007]  [<ffffffff8106c6fc>] __lock_acquire+0x342/0x3c7
[   21.402007]  [<ffffffff8106c842>] lock_acquire+0xc1/0xe5
[   21.402007]  [<ffffffff810eb615>] ? lookup_mnt+0x19/0x53
[   21.402007]  [<ffffffff8153aedc>] _spin_lock+0x31/0x66

Double the size - as we've done in the past.

[ Impact: allow lockdep to cover more locks ]

Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agoMerge branch 'perfcounters/core'
Ingo Molnar [Tue, 12 May 2009 13:31:13 +0000 (15:31 +0200)]
Merge branch 'perfcounters/core'

16 years agoperf_counter: call hw_perf_save_disable/restore around group_sched_in
Paul Mackerras [Tue, 12 May 2009 11:59:01 +0000 (21:59 +1000)]
perf_counter: call hw_perf_save_disable/restore around group_sched_in

I noticed that when enabling a group via the PERF_COUNTER_IOC_ENABLE
ioctl on the group leader, the counters weren't enabled and counting
immediately on return from the ioctl, but did start counting a little
while later (presumably after a context switch).

The reason was that __perf_counter_enable calls group_sched_in which
calls hw_perf_group_sched_in, which on powerpc assumes that the caller
has called hw_perf_save_disable already.  Until commit 46d686c6
("perf_counter: put whole group on when enabling group leader") it was
true that all callers of group_sched_in had called
hw_perf_save_disable first, and the powerpc hw_perf_group_sched_in
relies on that (there isn't an x86 version).

This fixes the problem by putting calls to hw_perf_save_disable /
hw_perf_restore around the calls to group_sched_in and
counter_sched_in in __perf_counter_enable.  Having the calls to
hw_perf_save_disable/restore around the counter_sched_in call is
harmless and makes this call consistent with the other call sites
of counter_sched_in, which have all called hw_perf_save_disable first.

[ Impact: more precise counter group disable/enable functionality ]

Signed-off-by: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
LKML-Reference: <18953.25733.53359.147452@cargo.ozlabs.ibm.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agoMerge branch 'linus'
Ingo Molnar [Tue, 12 May 2009 11:22:30 +0000 (13:22 +0200)]
Merge branch 'linus'

16 years agoMerge branch 'x86/mm'
Ingo Molnar [Tue, 12 May 2009 09:27:22 +0000 (11:27 +0200)]
Merge branch 'x86/mm'

16 years agox86: make sparse mem work in non-NUMA mode
Shaohua Li [Tue, 12 May 2009 08:40:00 +0000 (16:40 +0800)]
x86: make sparse mem work in non-NUMA mode

With sparse memory, holes should not be marked present for memmap.
This patch makes sure sparsemem really works on SMP mode (!NUMA).

[ Impact: use less memory to map fragmented RAM, avoid boot-OOM/crash ]

Signed-off-by: Shaohua Li <shaohua.li@intel.com>
Signed-off-by: Sheng Yang <sheng.yang@intel.com>
LKML-Reference: <1242117600.22431.0.camel@sli10-desk.sh.intel.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agox86: process.c, remove useless headers
Amerigo Wang [Tue, 12 May 2009 03:29:09 +0000 (23:29 -0400)]
x86: process.c, remove useless headers

<stdarg.h> is not needed by these files, remove them.

[ Impact: cleanup ]

Signed-off-by: WANG Cong <amwang@redhat.com>
Cc: akpm@linux-foundation.org
LKML-Reference: <20090512032956.5040.77055.sendpatchset@localhost.localdomain>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agoMerge branch 'x86/mm'
Ingo Molnar [Tue, 12 May 2009 09:17:16 +0000 (11:17 +0200)]
Merge branch 'x86/mm'

16 years agox86: process.c, remove useless headers
Amerigo Wang [Tue, 12 May 2009 03:29:09 +0000 (23:29 -0400)]
x86: process.c, remove useless headers

<stdarg.h> is not needed by these files, remove them.

[ Impact: cleanup ]

Signed-off-by: WANG Cong <amwang@redhat.com>
Cc: akpm@linux-foundation.org
LKML-Reference: <20090512032956.5040.77055.sendpatchset@localhost.localdomain>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agoMerge branch 'x86/mm'
Ingo Molnar [Tue, 12 May 2009 09:14:03 +0000 (11:14 +0200)]
Merge branch 'x86/mm'

16 years agox86: make sparse mem work in non-NUMA mode
Shaohua Li [Tue, 12 May 2009 08:40:00 +0000 (16:40 +0800)]
x86: make sparse mem work in non-NUMA mode

With sparse memory, holes should not be marked present for memmap.
This patch makes sure sparsemem really works on SMP mode (!NUMA).

Signed-off-by: Shaohua Li <shaohua.li@intel.com>
Signed-off-by: Sheng Yang <sheng.yang@intel.com>
LKML-Reference: <1242117600.22431.0.camel@sli10-desk.sh.intel.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agox86: merge process.c a bit
Amerigo Wang [Tue, 12 May 2009 02:05:28 +0000 (22:05 -0400)]
x86: merge process.c a bit

Merge arch_align_stack() and arch_randomize_brk(), since
they are the same.

Tested on x86_64.

[ Impact: cleanup ]

Signed-off-by: Amerigo Wang <amwang@redhat.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agoMerge branch 'x86/microcode'
Ingo Molnar [Tue, 12 May 2009 08:39:21 +0000 (10:39 +0200)]
Merge branch 'x86/microcode'

16 years agoMerge branch 'tracing/core'
Ingo Molnar [Tue, 12 May 2009 08:39:19 +0000 (10:39 +0200)]
Merge branch 'tracing/core'

16 years agoMerge branch 'timers/ntp'
Ingo Molnar [Tue, 12 May 2009 08:39:16 +0000 (10:39 +0200)]
Merge branch 'timers/ntp'

16 years agox86: microcode: use smp_call_function_single instead of set_cpus_allowed, cleanup...
Dmitry Adamushko [Mon, 11 May 2009 21:48:27 +0000 (23:48 +0200)]
x86: microcode: use smp_call_function_single instead of set_cpus_allowed, cleanup of synchronization logic

* Solve issues described in 6f66cbc63081fd70e3191b4dbb796746780e5ae1
  in a way that doesn't resort to set_cpus_allowed();

* in fact, only collect_cpu_info and apply_microcode callbacks
  must run on a target cpu, others will do just fine on any other.
  smp_call_function_single() (as suggested by Ingo) is used to run
  these callbacks on a target cpu.

* cleanup of synchronization logic of the 'microcode_core' part

  The generic 'microcode_core' part guarantees that only a single cpu
  (be it a full-fledged cpu, one of the cores or HT)
  is being updated at any particular moment of time.

  In general, there is no need for any additional sync. mechanism in
  arch-specific parts (the patch removes existing spinlocks).

  See also the "Synchronization" section in microcode_core.c.

* return -EINVAL instead of -1 (which is translated into -EPERM) in
  microcode_write(), reload_cpu() and mc_sysdev_add(). Other suggestions
  for an error code?

* use 'enum ucode_state' as return value of request_microcode_{fw, user}
  to gain more flexibility by distinguishing between real error cases
  and situations when an appropriate ucode was not found (which is not an
  error per-se).

* some minor cleanups

Thanks a lot to Hugh Dickins for review/suggestions/testing!

   Reference: http://marc.info/?l=linux-kernel&m=124025889012541&w=2

[ Impact: refactor and clean up microcode driver locking code ]

Signed-off-by: Dmitry Adamushko <dmitry.adamushko@gmail.com>
Acked-by: Hugh Dickins <hugh@veritas.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Rusty Russell <rusty@rustcorp.com.au>
Cc: Andreas Herrmann <andreas.herrmann3@amd.com>
Cc: Peter Oruba <peter.oruba@amd.com>
Cc: Arjan van de Ven <arjan@infradead.org>
LKML-Reference: <1242078507.5560.9.camel@earth>
[ did some more cleanups ]
Signed-off-by: Ingo Molnar <mingo@elte.hu>
 arch/x86/include/asm/microcode.h  |   25 ++
 arch/x86/kernel/microcode_amd.c   |   58 ++----
 arch/x86/kernel/microcode_core.c  |  326 +++++++++++++++++++++-----------------
 arch/x86/kernel/microcode_intel.c |   92 +++-------
 4 files changed, 261 insertions(+), 240 deletions(-)

(~20 new comment lines)

16 years agontp: fix comment typos
john stultz [Tue, 12 May 2009 01:13:13 +0000 (18:13 -0700)]
ntp: fix comment typos

Bernhard Schiffner noticed I had a few comment typos in this patch,
(note: to save embarrassment, when making typos, avoid copying and
pasting them) so this patch corrects them.

[ Impact: cleanup ]

Reported-by: Bernhard Schiffner <bernhard@schiffner-limbach.de>
Signed-off-by: John Stultz <johnstul@us.ibm.com>
Cc: riel@redhat.com
Cc: akpm@linux-foundation.org
LKML-Reference: <1242090794.7214.131.camel@localhost.localdomain>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agoMerge branch 'auto-latest'
Ingo Molnar [Tue, 12 May 2009 08:24:47 +0000 (10:24 +0200)]
Merge branch 'auto-latest'

16 years agoMerge branch 'auto-perfcounters-next' into auto-latest
Ingo Molnar [Tue, 12 May 2009 07:26:58 +0000 (09:26 +0200)]
Merge branch 'auto-perfcounters-next' into auto-latest

Conflicts:
arch/x86/kernel/irqinit.c
arch/x86/kernel/irqinit_64.c
arch/x86/kernel/traps.c
arch/x86/mm/fault.c

16 years agoMerge branch 'auto-warnings-next' into auto-latest
Ingo Molnar [Tue, 12 May 2009 07:25:53 +0000 (09:25 +0200)]
Merge branch 'auto-warnings-next' into auto-latest

16 years agoMerge branch 'auto-iommu-next' into auto-latest
Ingo Molnar [Tue, 12 May 2009 07:25:51 +0000 (09:25 +0200)]
Merge branch 'auto-iommu-next' into auto-latest

16 years agoMerge branch 'auto-sparseirq-next' into auto-latest
Ingo Molnar [Tue, 12 May 2009 07:25:49 +0000 (09:25 +0200)]
Merge branch 'auto-sparseirq-next' into auto-latest

16 years agoMerge branch 'auto-oprofile-next' into auto-latest
Ingo Molnar [Tue, 12 May 2009 07:25:46 +0000 (09:25 +0200)]
Merge branch 'auto-oprofile-next' into auto-latest

16 years agomanual merge of auto-kmemcheck-next
Ingo Molnar [Tue, 12 May 2009 07:25:29 +0000 (09:25 +0200)]
manual merge of auto-kmemcheck-next

Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agoMerge branch 'auto-safe-poison-pointers-next' into auto-latest
Ingo Molnar [Tue, 12 May 2009 07:25:24 +0000 (09:25 +0200)]
Merge branch 'auto-safe-poison-pointers-next' into auto-latest

16 years agoMerge branch 'auto-core-next' into auto-latest
Ingo Molnar [Tue, 12 May 2009 07:25:20 +0000 (09:25 +0200)]
Merge branch 'auto-core-next' into auto-latest

16 years agoMerge branch 'auto-genirq-next' into auto-latest
Ingo Molnar [Tue, 12 May 2009 07:25:18 +0000 (09:25 +0200)]
Merge branch 'auto-genirq-next' into auto-latest

16 years agoMerge branch 'auto-timers-next' into auto-latest
Ingo Molnar [Tue, 12 May 2009 07:25:17 +0000 (09:25 +0200)]
Merge branch 'auto-timers-next' into auto-latest

16 years agoMerge branch 'auto-tracing-next' into auto-latest
Ingo Molnar [Tue, 12 May 2009 07:25:15 +0000 (09:25 +0200)]
Merge branch 'auto-tracing-next' into auto-latest

16 years agoMerge branch 'auto-sched-next' into auto-latest
Ingo Molnar [Tue, 12 May 2009 07:25:14 +0000 (09:25 +0200)]
Merge branch 'auto-sched-next' into auto-latest

16 years agoMerge branch 'irq/numa' into auto-genirq-next
Ingo Molnar [Tue, 12 May 2009 07:24:30 +0000 (09:24 +0200)]
Merge branch 'irq/numa' into auto-genirq-next

16 years agoMerge branch 'irq/genirq' into auto-genirq-next
Ingo Molnar [Tue, 12 May 2009 07:24:28 +0000 (09:24 +0200)]
Merge branch 'irq/genirq' into auto-genirq-next

16 years agoMerge branch 'linus' into out-of-tree
Ingo Molnar [Tue, 12 May 2009 07:16:27 +0000 (09:16 +0200)]
Merge branch 'linus' into out-of-tree

16 years agoMerge branch 'kmemcheck' into auto-kmemcheck-next
Ingo Molnar [Tue, 12 May 2009 07:11:22 +0000 (09:11 +0200)]
Merge branch 'kmemcheck' into auto-kmemcheck-next

16 years agoMerge commit 'v2.6.30-rc5' into kmemcheck
Ingo Molnar [Tue, 12 May 2009 07:07:41 +0000 (09:07 +0200)]
Merge commit 'v2.6.30-rc5' into kmemcheck

Conflicts:
arch/x86/mm/init.c
kernel/sysctl.c

Merge reason: refresh the branch to .30-rc5 and resolve conflicts.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agoMerge branch 'timers/core' into auto-timers-next
Ingo Molnar [Tue, 12 May 2009 07:05:46 +0000 (09:05 +0200)]
Merge branch 'timers/core' into auto-timers-next

16 years agoMerge branch 'timers/ntp' into auto-timers-next
Ingo Molnar [Tue, 12 May 2009 07:05:38 +0000 (09:05 +0200)]
Merge branch 'timers/ntp' into auto-timers-next

16 years agoMerge branch 'timers/clocksource' into auto-timers-next
Ingo Molnar [Tue, 12 May 2009 07:05:31 +0000 (09:05 +0200)]
Merge branch 'timers/clocksource' into auto-timers-next

16 years agoMerge branch 'timers/clockevents' into auto-timers-next
Ingo Molnar [Tue, 12 May 2009 07:05:30 +0000 (09:05 +0200)]
Merge branch 'timers/clockevents' into auto-timers-next

16 years agoMerge branch 'sched/docs' into auto-sched-next
Ingo Molnar [Tue, 12 May 2009 07:05:25 +0000 (09:05 +0200)]
Merge branch 'sched/docs' into auto-sched-next

16 years agoMerge branch 'core/rcu' into auto-sched-next
Ingo Molnar [Tue, 12 May 2009 07:05:05 +0000 (09:05 +0200)]
Merge branch 'core/rcu' into auto-sched-next

16 years agoMerge branch 'sched/core' into auto-sched-next
Ingo Molnar [Tue, 12 May 2009 07:05:04 +0000 (09:05 +0200)]
Merge branch 'sched/core' into auto-sched-next

16 years agoMerge branch 'sched/urgent' into auto-sched-next
Ingo Molnar [Tue, 12 May 2009 07:05:03 +0000 (09:05 +0200)]
Merge branch 'sched/urgent' into auto-sched-next

16 years agoMerge branch 'perfcounters/core' into auto-perfcounters-next
Ingo Molnar [Tue, 12 May 2009 07:04:55 +0000 (09:04 +0200)]
Merge branch 'perfcounters/core' into auto-perfcounters-next

16 years agoMerge branch 'oprofile' into auto-oprofile-next
Ingo Molnar [Tue, 12 May 2009 07:04:44 +0000 (09:04 +0200)]
Merge branch 'oprofile' into auto-oprofile-next

16 years agoMerge branch 'core/iommu' into auto-iommu-next
Ingo Molnar [Tue, 12 May 2009 07:04:37 +0000 (09:04 +0200)]
Merge branch 'core/iommu' into auto-iommu-next

16 years agoMerge branch 'core/rcu' into auto-core-next
Ingo Molnar [Tue, 12 May 2009 07:03:14 +0000 (09:03 +0200)]
Merge branch 'core/rcu' into auto-core-next

16 years agoMerge branch 'core/signal' into auto-core-next
Ingo Molnar [Tue, 12 May 2009 07:03:09 +0000 (09:03 +0200)]
Merge branch 'core/signal' into auto-core-next

16 years agoMerge branch 'core/futexes' into auto-core-next
Ingo Molnar [Tue, 12 May 2009 07:02:59 +0000 (09:02 +0200)]
Merge branch 'core/futexes' into auto-core-next

16 years agoMerge branch 'core/printk' into auto-core-next
Ingo Molnar [Tue, 12 May 2009 07:02:49 +0000 (09:02 +0200)]
Merge branch 'core/printk' into auto-core-next

16 years agoMerge branch 'core/percpu' into auto-core-next
Ingo Molnar [Tue, 12 May 2009 07:02:47 +0000 (09:02 +0200)]
Merge branch 'core/percpu' into auto-core-next

16 years agoMerge branch 'core/locking' into auto-core-next
Ingo Molnar [Tue, 12 May 2009 07:02:45 +0000 (09:02 +0200)]
Merge branch 'core/locking' into auto-core-next

16 years agoMerge branch 'tracing/mm' into auto-tracing-next
Ingo Molnar [Tue, 12 May 2009 07:02:11 +0000 (09:02 +0200)]
Merge branch 'tracing/mm' into auto-tracing-next

16 years agoMerge branch 'tracing/core' into auto-tracing-next
Ingo Molnar [Tue, 12 May 2009 07:01:48 +0000 (09:01 +0200)]
Merge branch 'tracing/core' into auto-tracing-next

16 years agoMerge branch 'x86/kbuild-phys' into auto-x86-next
Ingo Molnar [Tue, 12 May 2009 06:52:53 +0000 (08:52 +0200)]
Merge branch 'x86/kbuild-phys' into auto-x86-next

16 years agoMerge branch 'x86/kbuild' into auto-x86-next
Ingo Molnar [Tue, 12 May 2009 06:52:51 +0000 (08:52 +0200)]
Merge branch 'x86/kbuild' into auto-x86-next

16 years agoMerge branch 'x86/asm' into auto-x86-next
Ingo Molnar [Tue, 12 May 2009 06:52:43 +0000 (08:52 +0200)]
Merge branch 'x86/asm' into auto-x86-next

16 years agoMerge branch 'x86/cpufeature' into auto-x86-next
Ingo Molnar [Tue, 12 May 2009 06:52:36 +0000 (08:52 +0200)]
Merge branch 'x86/cpufeature' into auto-x86-next

16 years agoMerge branch 'x86/mm' into auto-x86-next
Ingo Molnar [Tue, 12 May 2009 06:52:35 +0000 (08:52 +0200)]
Merge branch 'x86/mm' into auto-x86-next

16 years agoMerge branch 'x86/fpu' into auto-x86-next
Ingo Molnar [Tue, 12 May 2009 06:51:44 +0000 (08:51 +0200)]
Merge branch 'x86/fpu' into auto-x86-next

16 years agoMerge branch 'x86/setup' into auto-x86-next
Ingo Molnar [Tue, 12 May 2009 06:50:46 +0000 (08:50 +0200)]
Merge branch 'x86/setup' into auto-x86-next

16 years agoMerge branch 'x86/xen' into auto-x86-next
Ingo Molnar [Tue, 12 May 2009 06:50:45 +0000 (08:50 +0200)]
Merge branch 'x86/xen' into auto-x86-next

16 years agoMerge branch 'x86/cpu' into auto-x86-next
Ingo Molnar [Tue, 12 May 2009 06:50:27 +0000 (08:50 +0200)]
Merge branch 'x86/cpu' into auto-x86-next

16 years agoMerge branch 'x86/cleanups' into auto-x86-next
Ingo Molnar [Tue, 12 May 2009 06:50:23 +0000 (08:50 +0200)]
Merge branch 'x86/cleanups' into auto-x86-next

16 years agoMerge branch 'x86/apic' into auto-x86-next
Ingo Molnar [Tue, 12 May 2009 06:50:17 +0000 (08:50 +0200)]
Merge branch 'x86/apic' into auto-x86-next

16 years agoMerge branch 'x86/urgent' into auto-x86-next
Ingo Molnar [Tue, 12 May 2009 06:50:12 +0000 (08:50 +0200)]
Merge branch 'x86/urgent' into auto-x86-next

16 years agoring-buffer: move code around to remove some branches
Steven Rostedt [Tue, 12 May 2009 02:11:05 +0000 (22:11 -0400)]
ring-buffer: move code around to remove some branches

This is a bit of micro-optimizations. But since the ring buffer is used
in tracing every function call, it is an extreme hot path. Every nanosecond
counts.

This change shows over 5% improvement in the ring-buffer-benchmark.

[ Impact: more efficient code ]

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
16 years agoring-buffer: use internal time stamp function
Steven Rostedt [Mon, 11 May 2009 20:28:23 +0000 (16:28 -0400)]
ring-buffer: use internal time stamp function

The ring_buffer_time_stamp that is exported adds a little more overhead
than is needed for using it internally. This patch adds an internal
timestamp function that can be inlined (a single line function)
and used internally for the ring buffer.

[ Impact: a little less overhead to the ring buffer ]

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
16 years agoring-buffer: small optimizations
Steven Rostedt [Mon, 11 May 2009 20:08:00 +0000 (16:08 -0400)]
ring-buffer: small optimizations

Doing some small changes in the fast path of the ring buffer recording
saves over 3% in the ring-buffer-benchmark test.

[ Impact: a little faster ring buffer recording ]

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
16 years agox86, 32-bit: fix kernel_trap_sp()
Masami Hiramatsu [Mon, 11 May 2009 21:03:00 +0000 (17:03 -0400)]
x86, 32-bit: fix kernel_trap_sp()

Use &regs->sp instead of regs for getting the top of stack in kernel mode.
(on x86-64, regs->sp always points the top of stack)

[ Impact: Oprofile decodes only stack for backtracing on i386 ]

Signed-off-by: Masami Hiramatsu <mhiramat@redhat.com>
[ v2: rename the API to kernel_stack_pointer(), move variable inside ]
Acked-by: Linus Torvalds <torvalds@linux-foundation.org>
Cc: systemtap@sources.redhat.com
Cc: Harvey Harrison <harvey.harrison@gmail.com>
Cc: Jan Blunck <jblunck@suse.de>
Cc: Christoph Hellwig <hch@infradead.org>
LKML-Reference: <20090511210300.17332.67549.stgit@localhost.localdomain>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agosched: Don't export sched_mc_power_savings on multi-socket single core system
Vaidyanathan Srinivasan [Mon, 11 May 2009 14:39:14 +0000 (20:09 +0530)]
sched: Don't export sched_mc_power_savings on multi-socket single core system

Fix to prevent sched_mc_power_saving from being exported through sysfs
for multi-scoket single core system. Max cores should be always greater than
one (1). My earlier patch that introduced fix for not exporting
'sched_mc_power_saving' on laptops  broke it on multi-socket single core
system. This fix addresses issue on both laptop and multi-socket single
core system.
Below are the Test results:

1. Single socket - multi-core
       Before Patch: Does not export 'sched_mc_power_saving'
       After Patch: Does not export 'sched_mc_power_saving'
       Result: Pass

2. Multi Socket - single core
      Before Patch: exports 'sched_mc_power_saving'
      After Patch: Does not export 'sched_mc_power_saving'
      Result: Pass

3. Multi Socket - Multi core
      Before Patch: exports 'sched_mc_power_saving'
      After Patch: exports 'sched_mc_power_saving'

[ Impact: make the sched_mc_power_saving control available more consistently ]

Signed-off-by: Mahesh Salgaonkar <mahesh@linux.vnet.ibm.com>
Cc: Suresh B Siddha <suresh.b.siddha@intel.com>
Cc: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
LKML-Reference: <20090511143914.GB4853@dirshya.in.ibm.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agoMerge branch 'for-linus' of git://repo.or.cz/cris-mirror
Linus Torvalds [Mon, 11 May 2009 19:43:41 +0000 (12:43 -0700)]
Merge branch 'for-linus' of git://repo.or.cz/cris-mirror

* 'for-linus' of git://repo.or.cz/cris-mirror:
  CRISv32: Fix typo compile error in ARTPEC-3 gpio driver.
  CRIS: Wire up syscalls signalfd4 to writev.
  CRISv32: Remove obsolete vcs_hook.o from Makefile
  CRIS: Merge machine dependent boot/compressed and boot/rescue

16 years agoMerge branch 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jgarzi...
Linus Torvalds [Mon, 11 May 2009 19:42:55 +0000 (12:42 -0700)]
Merge branch 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jgarzik/libata-dev

* 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jgarzik/libata-dev:
  ata_piix: The Sony TZ90 needs the cable type hardcoding
  ata_piix: ICH7 does not support correct MWDMA timings
  Avoid world-writable sysfs files in libata driver.
  libata: fix suspend/resume for ATA SEMB devices
  libata: clear ering on resume
  pata_pdc202xx_old: fix UDMA33 handling
  sata_mv: use new sata phy register settings for new devices
  libata: fix attach error handling

16 years agodup2: Fix return value with oldfd == newfd and invalid fd
Jeff Mahoney [Mon, 11 May 2009 18:25:34 +0000 (14:25 -0400)]
dup2: Fix return value with oldfd == newfd and invalid fd

The return value of dup2 when oldfd == newfd and the fd isn't valid is
not getting properly sign extended.  We end up with 4294967287 instead
of -EBADF.

I've reproduced this on SLE11 (2.6.27.21), openSUSE Factory
(2.6.29-rc5), and Ubuntu 9.04 (2.6.28).

This patch uses a signed int for the error value so it is properly
extended.

Commit 6c5d0512a091480c9f981162227fdb1c9d70e555 introduced this
regression.

Reported-by: Jiri Dluhos <jdluhos@novell.com>
Signed-off-by: Jeff Mahoney <jeffm@suse.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoring-buffer: move calculation of event length
Steven Rostedt [Mon, 11 May 2009 18:42:53 +0000 (14:42 -0400)]
ring-buffer: move calculation of event length

The event length is calculated and passed in to rb_reserve_next_event
in two different locations. Having rb_reserve_next_event do the
calculations directly makes only one location to do the change and
causes the calculation to be inlined by gcc.

Before:
   text    data     bss     dec     hex filename
  16538      24      12   16574    40be kernel/trace/ring_buffer.o

After:
   text    data     bss     dec     hex filename
  16490      24      12   16526    408e kernel/trace/ring_buffer.o

[ Impact: smaller more efficient code ]

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
16 years agoata_piix: The Sony TZ90 needs the cable type hardcoding
Alan Cox [Wed, 6 May 2009 16:09:41 +0000 (17:09 +0100)]
ata_piix: The Sony TZ90 needs the cable type hardcoding

The Sony TZ90 needs the cable type hardcoding. See bug #12734

Signed-off-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoata_piix: ICH7 does not support correct MWDMA timings
Alan Cox [Wed, 6 May 2009 16:08:44 +0000 (17:08 +0100)]
ata_piix: ICH7 does not support correct MWDMA timings

See Errata documentation. The recommended workaround is to use PIO4 instead
which will we automatically do by flagging this mode not available.

Signed-off-by: Alan Cox <alan.cox@linux.intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoAvoid world-writable sysfs files in libata driver.
Vitaly Mayatskikh [Mon, 4 May 2009 13:48:45 +0000 (15:48 +0200)]
Avoid world-writable sysfs files in libata driver.

Signed-off-by: Vitaly Mayatskikh <v.mayatskih@gmail.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agolibata: fix suspend/resume for ATA SEMB devices
Borislav Petkov [Sun, 26 Apr 2009 14:33:34 +0000 (16:33 +0200)]
libata: fix suspend/resume for ATA SEMB devices

79b42babbac2a5a522b8e269fb2811b6e1063030 fixed identifying ATA devices
reporting 3c/c3 signature which belongs to SEMB devices now. However,
suspending the machine with such device (WDC WD2500AAJS-6 01.0) fails
with the following:

hda: host max PIO4 wanted PIO255(auto-tune) selected PIO4
hda: UDMA/100 mode selected
hdb: host max PIO4 wanted PIO255(auto-tune) selected PIO4
hdb: UDMA/66 mode selected
sd 1:0:0:0: [sda] Starting disk
ata5: SATA link down (SStatus 0 SControl 300)
ata1: SATA link down (SStatus 0 SControl 300)
ata3: SATA link down (SStatus 0 SControl 300)
ata6: SATA link down (SStatus 0 SControl 300)
ata2: softreset failed (device not ready)
ata2: failed due to HW bug, retry pmp=0
ata4: softreset failed (device not ready)
ata4: failed due to HW bug, retry pmp=0
ata4: SATA link up 3.0 Gbps (SStatus 123 SControl 300)
ata2: SATA link up 3.0 Gbps (SStatus 123 SControl 300)
ata2.00: class mismatch 1 != 7
ata2.00: revalidation failed (errno=-19)
ata2: limiting SATA link speed to 1.5 Gbps
ata4.00: configured for UDMA/133
ata2: softreset failed (device not ready)
ata2: failed due to HW bug, retry pmp=0
ata2: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
ata2.00: class mismatch 1 != 7
ata2.00: revalidation failed (errno=-19)
ata2.00: disabled
sd 1:0:0:0: rejecting I/O to offline device
sd 1:0:0:0: [sda] START_STOP FAILED
sd 1:0:0:0: [sda] Result: hostbyte=0x01 driverbyte=0x00
PM: Device 1:0:0:0 failed to thaw: error 65536
sd 3:0:0:0: [sdb] Starting disk

due to a class mismatch in ata_dev_revalidate(). Fix it by adding the
ATA_DEV_SEMB device class to the check.

CC: Tejun Heo <htejun@gmail.com>
Signed-off-by: Borislav Petkov <petkovbb@gmail.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agolibata: clear ering on resume
Tejun Heo [Thu, 23 Apr 2009 00:55:28 +0000 (09:55 +0900)]
libata: clear ering on resume

Error timestamps are in jiffies which doesn't run while suspended and
PHY events during resume isn't too uncommon.  When the two are
combined, it can lead to unnecessary speed downs if the machine is
suspended and resumed repeatedly.  Clear error history on resume.

This was reported and verified in bnc#486803 by Vladimir Botka.

Signed-off-by: Tejun Heo <tj@kernel.org>
Reported-by: Vladimir Botka <vbotka@novell.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agopata_pdc202xx_old: fix UDMA33 handling
Bartlomiej Zolnierkiewicz [Mon, 20 Apr 2009 20:31:25 +0000 (22:31 +0200)]
pata_pdc202xx_old: fix UDMA33 handling

The original driver doesn't use 66 MHz clock for UDMA33.

[ The alternative solution would be to adjust UDMA33 timings
  for 66 MHz clock but I think that it is safer to stick with
  old & tested behavior for now. ]

Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agosata_mv: use new sata phy register settings for new devices
Martin Michlmayr [Mon, 4 May 2009 18:58:50 +0000 (20:58 +0200)]
sata_mv: use new sata phy register settings for new devices

Marvell's new SoC (65 nano) needs different settings for its SATA
PHY registers.

Tested-by: Martin Michlmayr <tbm@cyrius.com>
Signed-off-by: Saeed Bishara <saeed@marvell.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agolibata: fix attach error handling
Tejun Heo [Sat, 9 May 2009 16:06:54 +0000 (01:06 +0900)]
libata: fix attach error handling

New device attach path in ata_eh_revalidate_and_attach() is divided
into two separate loops because ATA requires IDENTIFY to be issued to
slave first while the user expects to see device probe messages from
the master device.  new_mask is used to track which devices are the
new ones between the first loop and the second.

This usually works well but if an error occurs during configuration
stage, ata_dev_revalidate_and_attach() returns with error code and
forgets new_mask.  On the retry run, dev->class is set and new_mask
for the device is clear, so the device just gets revalidated and thus
ends up skipping post-configuration procedure including scheduling of
SCSI_HOTPLUG for the device.  When this occurs, ATA part of probing
works fine but SCSI probing usually doesn't happen and makes the
device unreachable.

The behavior has been around for a very long time but it has been
uncovered with the recent addition of 1_5_GBPS horkage which uses
-EAGAIN return value from ata_dev_configure() to restart the probing
sequence after forcing cable speed.

This can be fixed by making sure dev->class is permanently set only
after all configurations are successfully complete.  Fix it.

Signed-off-by: Tejun Heo <tj@kernel.org>
Reported-by: Tim Connors <tconnors+linuxkml@astro.swin.edu.au>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoring-buffer: remove type parameter from rb_reserve_next_event
Steven Rostedt [Mon, 11 May 2009 18:08:09 +0000 (14:08 -0400)]
ring-buffer: remove type parameter from rb_reserve_next_event

The rb_reserve_next_event is only called for the data type (type = 0).
There is no reason to pass in the type to the function.

Before:
   text    data     bss     dec     hex filename
  16554      24      12   16590    40ce kernel/trace/ring_buffer.o

After:
   text    data     bss     dec     hex filename
  16538      24      12   16574    40be kernel/trace/ring_buffer.o

[ Impact: cleaner, smaller and slightly more efficient code ]

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
16 years agoring-buffer: check for divide by zero in ring-buffer-benchmark
Steven Rostedt [Fri, 8 May 2009 15:03:57 +0000 (11:03 -0400)]
ring-buffer: check for divide by zero in ring-buffer-benchmark

Although we check if "missed" is not zero, we divide by hit + missed,
and the addition can possible overflow and become a divide by zero.

This patch checks for this case, and will report it when it happens
then modify "hit" to make the calculation be non zero.

[ Impact: prevent possible divide by zero in ring-buffer-benchmark ]

Reported-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
16 years agoring-buffer: replace constants with time macros in ring-buffer-benchmark
Steven Rostedt [Fri, 8 May 2009 14:56:33 +0000 (10:56 -0400)]
ring-buffer: replace constants with time macros in ring-buffer-benchmark

The use of numeric constants is discouraged. It is cleaner and more
descriptive to use macros for constant time conversions.

This patch also removes an extra new line.

[ Impact: more descriptive time conversions ]

Reported-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
16 years agox86: fix percpu_{to,from}_op()
Jan Beulich [Mon, 11 May 2009 15:49:28 +0000 (16:49 +0100)]
x86: fix percpu_{to,from}_op()

- the byte operand constraints were wrong for 32-bit
- the to-op's input operands weren't properly parenthesized

[ Impact: fix possible miscompilation or build failure ]

Signed-off-by: Jan Beulich <jbeulich@novell.com>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
16 years agointel-iommu: PAE memory corruption fix
David Woodhouse [Sun, 10 May 2009 22:57:41 +0000 (23:57 +0100)]
intel-iommu: PAE memory corruption fix

PAGE_MASK is 0xFFFFF000 on i386 -- even with PAE.

So it's not sufficient to ensure that you use phys_addr_t or uint64_t
everywhere you handle physical addresses -- you also have to avoid using
the construct 'addr & PAGE_MASK', because that will strip the high 32
bits of the address.

This patch avoids that problem by using PHYSICAL_PAGE_MASK instead of
PAGE_MASK where appropriate. It leaves '& PAGE_MASK' in a few instances
that don't matter -- where it's being used on the virtual bus addresses
we're dishing out, which are 32-bit anyway.

Since PHYSICAL_PAGE_MASK is not present on other architectures, we have
to define it (to PAGE_MASK) if it's not already defined.

Maybe it would be better just to fix PAGE_MASK for i386/PAE?

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agox86, 64-bit: ifdef out struct thread_struct::ip
Alexey Dobriyan [Sun, 3 May 2009 23:30:15 +0000 (03:30 +0400)]
x86, 64-bit: ifdef out struct thread_struct::ip

struct thread_struct::ip isn't used on x86_64, struct pt_regs::ip is used
instead.

kgdb should be reading 0 always, but I can't check it.

[ Impact: (potentially) reduce thread_struct size on 64-bit ]

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Cc: containers@lists.linux-foundation.org
LKML-Reference: <20090503233015.GJ16631@x200.localdomain>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agox86, 32-bit: ifdef out struct thread_struct::fs
Alexey Dobriyan [Sun, 3 May 2009 23:29:52 +0000 (03:29 +0400)]
x86, 32-bit: ifdef out struct thread_struct::fs

After commit 464d1a78fbf8cf6c7fd970e7b3e2db50a320ce28 aka
"[PATCH] i386: Convert i386 PDA code to use %fs"
%fs saved during context switch moved from thread_struct to pt_regs
and value on thread_struct became unused.

[ Impact: reduce thread_struct size on 32-bit ]

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Cc: containers@lists.linux-foundation.org
LKML-Reference: <20090503232952.GI16631@x200.localdomain>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agox86: apic: Fixmap apic address even if apic disabled
Cyrill Gorcunov [Mon, 11 May 2009 13:41:40 +0000 (17:41 +0400)]
x86: apic: Fixmap apic address even if apic disabled

In case if apic were disabled by boot option
we still need read_apic operation. So fixmap
a fake apic area if needed.

[ Impact: fix boot crash ]

Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org>
Cc: yinghai@kernel.org
Cc: eswierk@aristanetworks.com
LKML-Reference: <20090511134140.GH4624@lenovo>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agoMerge commit 'v2.6.30-rc5' into core/iommu
Ingo Molnar [Mon, 11 May 2009 12:44:27 +0000 (14:44 +0200)]
Merge commit 'v2.6.30-rc5' into core/iommu

Merge reason: core/iommu was on an .30-rc1 base,
              update it to .30-rc5 to refresh.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agox86: display extended apic registers with print_local_APIC and cpu_debug code
Andreas Herrmann [Fri, 8 May 2009 16:23:50 +0000 (18:23 +0200)]
x86: display extended apic registers with print_local_APIC and cpu_debug code

Both print_local_APIC (used when apic=debug kernel param is set) and
cpu_debug code missed support for some extended APIC registers that
I'd like to see.

This adds support to show:

 - extended APIC feature register
 - extended APIC control register
 - extended LVT registers

[ Impact: print more debug info ]

Signed-off-by: Andreas Herrmann <andreas.herrmann3@amd.com>
Cc: Jaswinder Singh Rajput <jaswinder@kernel.org>
Cc: Cyrill Gorcunov <gorcunov@openvz.org>
LKML-Reference: <20090508162350.GO29045@alberich.amd.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agox86: Provide _sdata in the vmlinux.lds.S file
Catalin Marinas [Mon, 11 May 2009 12:22:00 +0000 (13:22 +0100)]
x86: Provide _sdata in the vmlinux.lds.S file

_sdata is a common symbol defined by many architectures and made
available to the kernel via asm-generic/sections.h. Kmemleak uses this
symbol when scanning the data sections.

[ Impact: add new global symbol ]

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
LKML-Reference: <20090511122105.26556.96593.stgit@pc1117.cambridge.arm.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agoMerge commit 'v2.6.30-rc5' into x86/kbuild
Ingo Molnar [Mon, 11 May 2009 12:27:56 +0000 (14:27 +0200)]
Merge commit 'v2.6.30-rc5' into x86/kbuild

Merge reason: x86/kbuild was based on .30-rc1, refresh it with -rc5
              fixes before queueing up more changes

Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agoblktrace: from-sector redundant in trace_block_remap, cleanup
Li Zefan [Mon, 11 May 2009 07:06:46 +0000 (15:06 +0800)]
blktrace: from-sector redundant in trace_block_remap, cleanup

The last argument of block_remap prober is the original sector
before remap, so it should be 'from', not 'to'.

[ Impact: clean up ]

Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>
Cc: "Alan D. Brunelle" <Alan.Brunelle@hp.com>
Cc: Jens Axboe <jens.axboe@oracle.com>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
LKML-Reference: <4A07CE86.5090301@cn.fujitsu.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agoMerge commit 'v2.6.30-rc5' into sched/core
Ingo Molnar [Mon, 11 May 2009 10:59:32 +0000 (12:59 +0200)]
Merge commit 'v2.6.30-rc5' into sched/core

Merge reason: sched/core was on .30-rc1 before, update to latest fixes

Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agoblktrace: pdu_buf of pc events should be unsigned
Li Zefan [Mon, 11 May 2009 06:33:23 +0000 (14:33 +0800)]
blktrace: pdu_buf of pc events should be unsigned

I got this:
  8,0    1   305.417782332  2037  I   R 32 (ffffff9e 10 00 ...) [bash]

It should be:
  8,0    1   305.417782332  2037  I   R 32 (9e 10 00 ...) [bash]

[ Impact: fix output of pc events ]

Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>
Cc: Jens Axboe <jens.axboe@oracle.com>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Steven Rostedt <rostedt@goodmis.org>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
LKML-Reference: <4A07C6B3.9080802@cn.fujitsu.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agoperf_counter: call atomic64_set for counter->count
Paul Mackerras [Mon, 11 May 2009 05:50:21 +0000 (15:50 +1000)]
perf_counter: call atomic64_set for counter->count

A compile warning triggered because we are calling
atomic_set(&counter->count). But since counter->count
is an atomic64_t, we have to use atomic64_set.

So the count can be set short, resulting in the reset ioctl
only resetting the low word.

[ Impact: clear counter properly during the reset ioctl ]

Signed-off-by: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
LKML-Reference: <18951.48285.270311.981806@drongo.ozlabs.ibm.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>