Permalink
Commits on Apr 27, 2010
  1. Merge branch 'version-2.6.33'

    Oleksandr Natalenko committed Apr 27, 2010
  2. version-2.6.33: bump to v2.6.33-pf3

    Oleksandr Natalenko committed Apr 27, 2010
  3. Merge remote branch 'misc-2.6.33'

    Oleksandr Natalenko committed Apr 27, 2010
  4. Merge remote branch 'zen-tune'

    Oleksandr Natalenko committed Apr 27, 2010
  5. Merge remote branch 'tuxonice-2.6.33'

    Oleksandr Natalenko committed Apr 27, 2010
  6. bfs 316

    Brandon Berhent committed Apr 27, 2010
  7. fs/block_dev.c: fix performance regression in O_DIRECT|O_SYNC writes …

    Brandon Berhent committed Apr 27, 2010
    …to block devices
Commits on Apr 26, 2010
  1. Merge branch 'origin' into combined

    Nigel Cunningham committed Apr 26, 2010
  2. fix merge conflict

    Oleksandr Natalenko committed Apr 26, 2010
  3. Linux 2.6.33.3

    gregkh committed Apr 26, 2010
  4. r8169: clean up my printk uglyness

    Neil Horman committed with gregkh Apr 1, 2010
    commit 93f4d91 upstream.
    
    Fix formatting on r8169 printk
    
    Brandon Philips noted that I had a spacing issue in my printk for the
    last r8169 patch that made it quite ugly.  Fix that up and add the PFX
    macro to it as well so it looks like the other r8169 printks
    
    Signed-off-by: Neil Horman <nhorman@tuxdriver.com>
    Signed-off-by: David S. Miller <davem@davemloft.net>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  5. x86/gart: Disable GART explicitly before initialization

    Joerg Roedel committed with gregkh Apr 7, 2010
    commit 4b83873 upstream.
    
    If we boot into a crash-kernel the gart might still be
    enabled and its caches might be dirty. This can result in
    undefined behavior later. Fix it by explicitly disabling the
    gart hardware before initialization and flushing the caches
    after enablement.
    
    Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  6. KVM: x86: Fix TSS size check for 16-bit tasks

    jan-kiszka committed with gregkh Apr 14, 2010
    (Cherry-picked from commit e8861cf)
    
    A 16-bit TSS is only 44 bytes long. So make sure to test for the correct
    size on task switch.
    
    Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
    Signed-off-by: Avi Kivity <avi@redhat.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  7. KVM: Increase NR_IOBUS_DEVS limit to 200

    Sridhar Samudrala committed with gregkh Mar 30, 2010
    (Cherry-picked from commit e80e2a6)
    
    This patch increases the current hardcoded limit of NR_IOBUS_DEVS
    from 6 to 200. We are hitting this limit when creating a guest with more
    than 1 virtio-net device using vhost-net backend. Each virtio-net
    device requires 2 such devices to service notifications from rx/tx queues.
    
    Signed-off-by: Sridhar Samudrala <sri@us.ibm.com>
    Signed-off-by: Avi Kivity <avi@redhat.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  8. KVM: fix the handling of dirty bitmaps to avoid overflows

    Takuya Yoshikawa committed with gregkh Apr 12, 2010
    (Cherry-picked from commit 87bf6e7)
    
    Int is not long enough to store the size of a dirty bitmap.
    
    This patch fixes this problem with the introduction of a wrapper
    function to calculate the sizes of dirty bitmaps.
    
    Note: in mark_page_dirty(), we have to consider the fact that
      __set_bit() takes the offset as int, not long.
    
    Signed-off-by: Takuya Yoshikawa <yoshikawa.takuya@oss.ntt.co.jp>
    Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  9. KVM: MMU: fix kvm_mmu_zap_page() and its calling path

    Xiao Guangrong committed with gregkh Apr 16, 2010
    (Cherry-picked from commit 77662e0)
    
    This patch fix:
    
    - calculate zapped page number properly in mmu_zap_unsync_children()
    - calculate freeed page number properly kvm_mmu_change_mmu_pages()
    - if zapped children page it shoud restart hlist walking
    
    KVM-Stable-Tag.
    Signed-off-by: Xiao Guangrong <xiaoguangrong@cn.fujitsu.com>
    Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  10. KVM: VMX: Save/restore rflags.vm correctly in real mode

    Avi Kivity committed with gregkh Apr 8, 2010
    (Cherry-picked from commit 78ac8b4)
    
    Currently we set eflags.vm unconditionally when entering real mode emulation
    through virtual-8086 mode, and clear it unconditionally when we enter protected
    mode.  The means that the following sequence
    
      KVM_SET_REGS  (rflags.vm=1)
      KVM_SET_SREGS (cr0.pe=1)
    
    Ends up with rflags.vm clear due to KVM_SET_SREGS triggering enter_pmode().
    
    Fix by shadowing rflags.vm (and rflags.iopl) correctly while in real mode:
    reads and writes to those bits access a shadow register instead of the actual
    register.
    
    Signed-off-by: Avi Kivity <avi@redhat.com>
    Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  11. KVM: allow bit 10 to be cleared in MSR_IA32_MC4_CTL

    aprzywar committed with gregkh Mar 24, 2010
    (Cherry-picked from commit 114be42)
    
    There is a quirk for AMD K8 CPUs in many Linux kernels (see
    arch/x86/kernel/cpu/mcheck/mce.c:__mcheck_cpu_apply_quirks()) that
    clears bit 10 in that MCE related MSR. KVM can only cope with all
    zeros or all ones, so it will inject a #GP into the guest, which
    will let it panic.
    So lets add a quirk to the quirk and ignore this single cleared bit.
    This fixes -cpu kvm64 on all machines and -cpu host on K8 machines
    with some guest Linux kernels.
    
    Signed-off-by: Andre Przywara <andre.przywara@amd.com>
    Signed-off-by: Avi Kivity <avi@redhat.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  12. KVM: Don't spam kernel log when injecting exceptions due to bad cr wr…

    Avi Kivity committed with gregkh Mar 11, 2010
    …ites
    
    (Cherry-picked from commit d6a2389)
    
    These are guest-triggerable.
    
    Signed-off-by: Avi Kivity <avi@redhat.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  13. KVM: SVM: Fix memory leaks that happen when svm_create_vcpu() fails

    Takuya Yoshikawa committed with gregkh Mar 9, 2010
    (Cherry-picked from commit b7af404)
    
    svm_create_vcpu() does not free the pages allocated during the creation
    when it fails to complete the allocations. This patch fixes it.
    
    Signed-off-by: Takuya Yoshikawa <yoshikawa.takuya@oss.ntt.co.jp>
    Signed-off-by: Avi Kivity <avi@redhat.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  14. KVM: VMX: Update instruction length on intercepted BP

    jan-kiszka committed with gregkh Feb 23, 2010
    (Cherry-picked from commit c573cd2)
    
    We intercept #BP while in guest debugging mode. As VM exits due to
    intercepted exceptions do not necessarily come with valid
    idt_vectoring, we have to update event_exit_inst_len explicitly in such
    cases. At least in the absence of migration, this ensures that
    re-injections of #BP will find and use the correct instruction length.
    
    Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
    Signed-off-by: Avi Kivity <avi@redhat.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  15. sched: Use proper type in sched_getaffinity()

    kosaki committed with gregkh Mar 17, 2010
    commit 8bc037f upstream.
    
    Using the proper type fixes the following compiler warning:
    
      kernel/sched.c:4850: warning: comparison of distinct pointer types lacks a cast
    
    Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
    Cc: torvalds@linux-foundation.org
    Cc: travis@sgi.com
    Cc: peterz@infradead.org
    Cc: drepper@redhat.com
    Cc: rja@sgi.com
    Cc: sharyath@in.ibm.com
    Cc: steiner@sgi.com
    LKML-Reference: <20100317090046.4C79.A69D9226@jp.fujitsu.com>
    Signed-off-by: Ingo Molnar <mingo@elte.hu>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  16. ext4: fix async i/o writes beyond 4GB to a sparse file

    Eric Sandeen committed with gregkh Feb 5, 2010
    commit a1de02d upstream.
    
    The "offset" member in ext4_io_end holds bytes, not blocks, so
    ext4_lblk_t is wrong - and too small (u32).
    
    This caused the async i/o writes to sparse files beyond 4GB to fail
    when they wrapped around to 0.
    
    Also fix up the type of arguments to ext4_convert_unwritten_extents(),
    it gets ssize_t from ext4_end_aio_dio_nolock() and
    ext4_ext_direct_IO().
    
    Reported-by: Giel de Nijs <giel@vectorwise.com>
    Signed-off-by: Eric Sandeen <sandeen@redhat.com>
    Cc: maximilian attems <max@stro.at>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  17. powerpc: Fix SMP build with disabled CPU hotplugging.

    Adam Lackorzynski committed with gregkh Feb 27, 2010
    commit 5b72d74 upstream.
    
    Compiling 2.6.33 with SMP enabled and HOTPLUG_CPU disabled gives me the
    following link errors:
    
      LD      init/built-in.o
      LD      .tmp_vmlinux1
    arch/powerpc/platforms/built-in.o: In function `.smp_xics_setup_cpu':
    smp.c:(.devinit.text+0x88): undefined reference to `.set_cpu_current_state'
    smp.c:(.devinit.text+0x94): undefined reference to `.set_default_offline_state'
    arch/powerpc/platforms/built-in.o: In function `.smp_pSeries_kick_cpu':
    smp.c:(.devinit.text+0x13c): undefined reference to `.set_preferred_offline_state'
    smp.c:(.devinit.text+0x148): undefined reference to `.get_cpu_current_state'
    smp.c:(.devinit.text+0x1a8): undefined reference to `.get_cpu_current_state'
    make: *** [.tmp_vmlinux1] Error 1
    
    The following change fixes that for me and seems to work as expected.
    
    Signed-off-by: Adam Lackorzynski <adam@os.inf.tu-dresden.de>
    Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  18. md: deal with merge_bvec_fn in component devices better.

    neilbrown committed with gregkh Mar 31, 2010
    commit 627a2d3 upstream.
    
    If a component device has a merge_bvec_fn then as we never call it
    we must ensure we never need to.  Currently this is done by setting
    max_sector to 1 PAGE, however this does not stop a bio being created
    with several sub-page iovecs that would violate the merge_bvec_fn.
    
    So instead set max_phys_segments to 1 and set the segment boundary to the
    same as a page boundary to ensure there is only ever one single-page
    segment of IO requested at a time.
    
    This can particularly be an issue when 'xen' is used as it is
    known to submit multiple small buffers in a single bio.
    
    Signed-off-by: NeilBrown <neilb@suse.de>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  19. module: fix __module_ref_addr()

    compudj committed with gregkh Apr 20, 2010
    The __module_ref_addr() problem disappears in 2.6.34-rc kernels because these
    percpu accesses were re-factored.
    
    __module_ref_addr() should use per_cpu_ptr() to obfuscate the pointer
    (RELOC_HIDE is needed for per cpu pointers).
    
    This non-standard per-cpu pointer use has been introduced by commit
    720eba3
    
    It causes a NULL pointer exception on some configurations when CONFIG_TRACING is
    enabled on 2.6.33. This patch fixes the problem (acknowledged by Randy who
    reported the bug).
    
    It did not appear to hurt previously because most of the accesses were done
    through local_inc, which probably obfuscated the access enough that no compiler
    optimizations were done. But with local_read() done when CONFIG_TRACING is
    active, this becomes a problem. Non-CONFIG_TRACING is probably affected as well
    (module.c contains local_set and local_read that use __module_ref_addr()), but I
    guess nobody noticed because we've been lucky enough that the compiler did not
    generate the inappropriate optimization pattern there.
    
    This patch should be queued for the 2.6.29.x through 2.6.33.x stable branches.
    (tested on 2.6.33.1 x86_64)
    
    Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
    Tested-by: Randy Dunlap <randy.dunlap@oracle.com>
    CC: Eric Dumazet <dada1@cosmosbay.com>
    CC: Rusty Russell <rusty@rustcorp.com.au>
    CC: Peter Zijlstra <a.p.zijlstra@chello.nl>
    CC: Tejun Heo <tj@kernel.org>
    CC: Ingo Molnar <mingo@elte.hu>
    CC: Andrew Morton <akpm@linux-foundation.org>
    CC: Linus Torvalds <torvalds@linux-foundation.org>
    CC: Greg Kroah-Hartman <gregkh@suse.de>
    CC: Steven Rostedt <rostedt@goodmis.org>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  20. lockdep: fix incorrect percpu usage

    compudj committed with gregkh Apr 20, 2010
    The mainline kernel as of 2.6.34-rc5 is not affected by this problem because
    commit 10fad5e fixed it by refactoring.
    
    lockdep fix incorrect percpu usage
    
    Should use per_cpu_ptr() to obfuscate the per cpu pointers (RELOC_HIDE is needed
    for per cpu pointers).
    
    git blame points to commit:
    
    lockdep.c: commit 8e18257
    
    But it's really just moving the code around. But it's enough to say that the
    problems appeared before Jul 19 01:48:54 2007, which brings us back to 2.6.23.
    
    It should be applied to stable 2.6.23.x to 2.6.33.x (or whichever of these
    stable branches are still maintained).
    
    (tested on 2.6.33.1 x86_64)
    
    Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
    CC: Randy Dunlap <randy.dunlap@oracle.com>
    CC: Eric Dumazet <dada1@cosmosbay.com>
    CC: Rusty Russell <rusty@rustcorp.com.au>
    CC: Peter Zijlstra <a.p.zijlstra@chello.nl>
    CC: Tejun Heo <tj@kernel.org>
    CC: Ingo Molnar <mingo@elte.hu>
    CC: Andrew Morton <akpm@linux-foundation.org>
    CC: Linus Torvalds <torvalds@linux-foundation.org>
    CC: Greg Kroah-Hartman <gregkh@suse.de>
    CC: Steven Rostedt <rostedt@goodmis.org>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  21. modules: fix incorrect percpu usage

    compudj committed with gregkh Apr 20, 2010
    Mainline does not need this fix, as commit
    259354d fixed the problem by refactoring.
    
    Should use per_cpu_ptr() to obfuscate the per cpu pointers (RELOC_HIDE is needed
    for per cpu pointers).
    
    Introduced by commit:
    
    module.c: commit 6b588c1
    
    This patch should be queued for the stable branch, for kernels 2.6.29.x to
    2.6.33.x.  (tested on 2.6.33.1 x86_64)
    
    Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
    CC: Randy Dunlap <randy.dunlap@oracle.com>
    CC: Eric Dumazet <dada1@cosmosbay.com>
    CC: Rusty Russell <rusty@rustcorp.com.au>
    CC: Peter Zijlstra <a.p.zijlstra@chello.nl>
    CC: Tejun Heo <tj@kernel.org>
    CC: Ingo Molnar <mingo@elte.hu>
    CC: Andrew Morton <akpm@linux-foundation.org>
    CC: Linus Torvalds <torvalds@linux-foundation.org>
    CC: Greg Kroah-Hartman <gregkh@suse.de>
    CC: Steven Rostedt <rostedt@goodmis.org>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  22. ACPI: EC: Limit burst to 64 bits

    Alexey Starikovskiy committed with gregkh Apr 16, 2010
    commit 2060c44 upstream.
    
    access_bit_width field is u8 in ACPICA, thus 256 value written to it
    becomes 0, causing divide by zero later.
    
    Proper fix would be to remove access_bit_width at all, just because
    we already have access_byte_width, which is access_bit_width / 8.
    Limit access width to 64 bit for now.
    
    https://bugzilla.kernel.org/show_bug.cgi?id=15749
    fixes regression caused by the fix for:
    https://bugzilla.kernel.org/show_bug.cgi?id=14667
    
    Signed-off-by: Alexey Starikovskiy <astarikovskiy@suse.de>
    Signed-off-by: Len Brown <len.brown@intel.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  23. ACPI: EC: Allow multibyte access to EC

    Alexey Starikovskiy committed with gregkh Apr 10, 2010
    commit dadf28a upstream
    
    http://bugzilla.kernel.org/show_bug.cgi?id=14667
    
    [bwh: Backport to 2.6.32; same applies to 2.6.33]
    
    Signed-off-by: Alexey Starikovskiy <astarikovskiy@suse.de>
    Signed-off-by: Len Brown <len.brown@intel.com>
    Cc: Ben Hutchings <ben@decadent.org.uk>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  24. xfs: check for more work before sleeping in xfssyncd

    dchinner committed with gregkh Mar 4, 2010
    commit 20f6b2c upstream.
    
    xfssyncd processes a queue of work by detaching the queue and
    then iterating over all the work items. It then sleeps for a
    time period or until new work comes in. If new work is queued
    while xfssyncd is actively processing the detached work queue,
    it will not process that new work until after a sleep timeout
    or the next work event queued wakes it.
    
    Fix this by checking the work queue again before going to sleep.
    
    Signed-off-by: Dave Chinner <david@fromorbit.com>
    Signed-off-by: Christoph Hellwig <hch@lst.de>
    Signed-off-by: Alex Elder <aelder@sgi.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  25. xfs: fix locking for inode cache radix tree tag updates

    Christoph Hellwig committed with gregkh Mar 1, 2010
    commit f1f724e upstream.
    
    The radix-tree code requires it's users to serialize tag updates
    against other updates to the tree.  While XFS protects tag updates
    against each other it does not serialize them against updates of the
    tree contents, which can lead to tag corruption.  Fix the inode
    cache to always take pag_ici_lock in exclusive mode when updating
    radix tree tags.
    
    Signed-off-by: Christoph Hellwig <hch@lst.de>
    Reported-by: Patrick Schreurs <patrick@news-service.com>
    Tested-by: Patrick Schreurs <patrick@news-service.com>
    Signed-off-by: Alex Elder <aelder@sgi.com>
    Cc: Dave Chinner <david@fromorbit.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  26. xfs: Non-blocking inode locking in IO completion

    dchinner committed with gregkh Feb 17, 2010
    commit 77d7a0c upstream.
    
    The introduction of barriers to loop devices has created a new IO
    order completion dependency that XFS does not handle. The loop
    device implements barriers using fsync and so turns a log IO in the
    XFS filesystem on the loop device into a data IO in the backing
    filesystem. That is, the completion of log IOs in the loop
    filesystem are now dependent on completion of data IO in the backing
    filesystem.
    
    This can cause deadlocks when a flush daemon issues a log force with
    an inode locked because the IO completion of IO on the inode is
    blocked by the inode lock. This in turn prevents further data IO
    completion from occuring on all XFS filesystems on that CPU (due to
    the shared nature of the completion queues). This then prevents the
    log IO from completing because the log is waiting for data IO
    completion as well.
    
    The fix for this new completion order dependency issue is to make
    the IO completion inode locking non-blocking. If the inode lock
    can't be grabbed, simply requeue the IO completion back to the work
    queue so that it can be processed later. This prevents the
    completion queue from being blocked and allows data IO completion on
    other inodes to proceed, hence avoiding completion order dependent
    deadlocks.
    
    Signed-off-by: Dave Chinner <david@fromorbit.com>
    Reviewed-by: Christoph Hellwig <hch@lst.de>
    Signed-off-by: Alex Elder <aelder@sgi.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  27. perf_events, x86: Implement Intel Westmere/Nehalem-EX support

    Peter Zijlstra committed with gregkh Apr 16, 2010
    original patch commit ids: 452a339 and
    134fbad 
    
    perf_events, x86: Implement Intel Westmere support
    
    The new Intel documentation includes Westmere arch specific
    event maps that are significantly different from the Nehalem
    ones. Add support for this generation.
    
    Found the CPUID model numbers on wikipedia.
    
    Also ammend some Nehalem constraints, spotted those when looking
    for the differences between Nehalem and Westmere.
    
    Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
    Cc: Arjan van de Ven <arjan@linux.intel.com>
    Cc: "H. Peter Anvin" <hpa@zytor.com>
    Cc: Stephane Eranian <eranian@google.com>
    LKML-Reference: <20100127221122.151865645@chello.nl>
    Signed-off-by: Ingo Molnar <mingo@elte.hu>
    
    perf, x86: Enable Nehalem-EX support
    
    According to Intel Software Devel Manual Volume 3B, the
    Nehalem-EX PMU is just like regular Nehalem (except for the
    uncore support, which is completely different).
    
    Signed-off-by:  Vince Weaver <vweaver1@eecs.utk.edu>
    Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
    Cc: Paul Mackerras <paulus@samba.org>
    Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
    Cc: "H. Peter Anvin" <hpa@zytor.com>
    Cc: Arjan van de Ven <arjan@linux.intel.com>
    Cc: Lin Ming <ming.m.lin@intel.com>
    LKML-Reference: <alpine.DEB.2.00.1004060956580.1417@cl320.eecs.utk.edu>
    Signed-off-by: Ingo Molnar <mingo@elte.hu>
    Cc: Youquan Song <youquan.song@linux.intel.com>