Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Commits on Dec 9, 2011
  1. @gregkh

    Linux 3.0.13

    gregkh authored
  2. @gregkh

    clockevents: Set noop handler in clockevents_exchange_device()

    Thomas Gleixner authored gregkh committed
    commit de28f25 upstream.
    
    If a device is shutdown, then there might be a pending interrupt,
    which will be processed after we reenable interrupts, which causes the
    original handler to be run. If the old handler is the (broadcast)
    periodic handler the shutdown state might hang the kernel completely.
    
    Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  3. @gregkh

    clocksource: Fix bug with max_deferment margin calculation

    Yang Honggang (Joseph) authored gregkh committed
    commit b1f9196 upstream.
    
    In order to leave a margin of 12.5% we should >> 3 not >> 5.
    
    Signed-off-by: Yang Honggang (Joseph) <eagle.rtlinux@gmail.com>
    [jstultz: Modified commit subject]
    Signed-off-by: John Stultz <john.stultz@linaro.org>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  4. @gregkh

    oprofile: Fix crash when unloading module (hr timer mode)

    Robert Richter authored gregkh committed
    commit 87121ca upstream.
    
    Oprofile may crash in a KVM guest while unlaoding modules. This
    happens if oprofile_arch_init() fails and oprofile switches to the hr
    timer mode as a fallback. In this case oprofile_arch_exit() is called,
    but it never was initialized properly which causes the crash. This
    patch fixes this.
    
    oprofile: using timer interrupt.
    BUG: unable to handle kernel NULL pointer dereference at 0000000000000008
    IP: [<ffffffff8123c226>] unregister_syscore_ops+0x41/0x58
    PGD 41da3f067 PUD 41d80e067 PMD 0
    Oops: 0002 [#1] PREEMPT SMP
    CPU 5
    Modules linked in: oprofile(-)
    
    Pid: 2382, comm: modprobe Not tainted 3.1.0-rc7-00018-g709a39d #18 Advanced Micro Device Anaheim/Anaheim
    RIP: 0010:[<ffffffff8123c226>]  [<ffffffff8123c226>] unregister_syscore_ops+0x41/0x58
    RSP: 0018:ffff88041de1de98  EFLAGS: 00010296
    RAX: 0000000000000000 RBX: ffffffffa00060e0 RCX: dead000000200200
    RDX: 0000000000000000 RSI: dead000000100100 RDI: ffffffff8178c620
    RBP: ffff88041de1dea8 R08: 0000000000000001 R09: 0000000000000082
    R10: 0000000000000000 R11: ffff88041de1dde8 R12: 0000000000000080
    R13: fffffffffffffff5 R14: 0000000000000001 R15: 0000000000610210
    FS:  00007f9ae5bef700(0000) GS:ffff88042fd40000(0000) knlGS:0000000000000000
    CS:  0010 DS: 0000 ES: 0000 CR0: 000000008005003b
    CR2: 0000000000000008 CR3: 000000041ca44000 CR4: 00000000000006e0
    DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
    DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
    Process modprobe (pid: 2382, threadinfo ffff88041de1c000, task ffff88042db6d040)
    Stack:
     ffff88041de1deb8 ffffffffa0006770 ffff88041de1deb8 ffffffffa000251e
     ffff88041de1dec8 ffffffffa00022c2 ffff88041de1ded8 ffffffffa0004993
     ffff88041de1df78 ffffffff81073115 656c69666f72706f 0000000000610200
    Call Trace:
     [<ffffffffa000251e>] op_nmi_exit+0x15/0x17 [oprofile]
     [<ffffffffa00022c2>] oprofile_arch_exit+0xe/0x10 [oprofile]
     [<ffffffffa0004993>] oprofile_exit+0x13/0x15 [oprofile]
     [<ffffffff81073115>] sys_delete_module+0x1c3/0x22f
     [<ffffffff811bf09e>] ? trace_hardirqs_on_thunk+0x3a/0x3f
     [<ffffffff8148070b>] system_call_fastpath+0x16/0x1b
    Code: 20 c6 78 81 e8 c5 cc 23 00 48 8b 13 48 8b 43 08 48 be 00 01 10 00 00 00 ad de 48 b9 00 02 20 00 00 00 ad de 48 c7 c7 20 c6 78 81
     89 42 08 48 89 10 48 89 33 48 89 4b 08 e8 a6 c0 23 00 5a 5b
    RIP  [<ffffffff8123c226>] unregister_syscore_ops+0x41/0x58
     RSP <ffff88041de1de98>
    CR2: 0000000000000008
    ---[ end trace 06d4e95b6aa3b437 ]---
    
    Signed-off-by: Robert Richter <robert.richter@amd.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  5. @gregkh

    jump_label: jump_label_inc may return before the code is patched

    Gleb Natapov authored gregkh committed
    commit bbbf7af upstream.
    
    If cpu A calls jump_label_inc() just after atomic_add_return() is
    called by cpu B, atomic_inc_not_zero() will return value greater then
    zero and jump_label_inc() will return to a caller before jump_label_update()
    finishes its job on cpu B.
    
    Link: http://lkml.kernel.org/r/20111018175551.GH17571@redhat.com
    
    Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
    Acked-by: Jason Baron <jbaron@redhat.com>
    Signed-off-by: Gleb Natapov <gleb@redhat.com>
    Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  6. @gregkh

    perf: Fix parsing of __print_flags() in TP_printk()

    Steven Rostedt authored gregkh committed
    commit d06c27b upstream.
    
    A update is made to the sched:sched_switch event that adds some
    logic to the first parameter of the __print_flags() that shows the
    state of tasks. This change cause perf to fail parsing the flags.
    
    A simple fix is needed to have the parser be able to process ops
    within the argument.
    
    Reported-by: Andrew Vagin <avagin@openvz.org>
    Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  7. @gregkh

    tick-broadcast: Stop active broadcast device when replacing it

    Thomas Gleixner authored gregkh committed
    commit c1be843 upstream.
    
    When a better rated broadcast device is installed, then the current
    active device is not disabled, which results in two running broadcast
    devices.
    
    Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  8. @idryomov @gregkh

    tracing: fix event_subsystem ref counting

    idryomov authored gregkh committed
    commit cb59974 upstream.
    
    Fix a bug introduced by e9dbfae, which prevents event_subsystem from
    ever being released.
    
    Ref_count was added to keep track of subsystem users, not for counting
    events.  Subsystem is created with ref_count = 1, so there is no need to
    increment it for every event, we have nr_events for that.  Fix this by
    touching ref_count only when we actually have a new user -
    subsystem_open().
    
    Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
    Link: http://lkml.kernel.org/r/1320052062-7846-1-git-send-email-idryomov@gmail.com
    Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  9. @rabinv @gregkh

    rtc: Disable the alarm in the hardware

    rabinv authored gregkh committed
    commit c0afabd upstream.
    
    Currently, the RTC code does not disable the alarm in the hardware.
    
    This means that after a sequence such as the one below (the files are in the
    RTC sysfs), the box will boot up after 2 minutes even though we've
    asked for the alarm to be turned off.
    
    	# echo $((`cat since_epoch`)+120) > wakealarm
    	# echo 0 > wakealarm
    	# poweroff
    
    Fix this by disabling the alarm when there are no timers to run.
    
    Cc: John Stultz <john.stultz@linaro.org>
    Signed-off-by: Rabin Vincent <rabin.vincent@stericsson.com>
    Signed-off-by: John Stultz <john.stultz@linaro.org>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  10. @gregkh

    trace_events_filter: Use rcu_assign_pointer() when setting ftrace_eve…

    Tejun Heo authored gregkh committed
    …nt_call->filter
    
    commit d3d9acf upstream.
    
    ftrace_event_call->filter is sched RCU protected but didn't use
    rcu_assign_pointer().  Use it.
    
    TODO: Add proper __rcu annotation to call->filter and all its users.
    
    -v2: Use RCU_INIT_POINTER() for %NULL clearing as suggested by Eric.
    
    Link: http://lkml.kernel.org/r/20111123164949.GA29639@google.com
    
    Cc: Eric Dumazet <eric.dumazet@gmail.com>
    Cc: Frederic Weisbecker <fweisbec@gmail.com>
    Cc: Jiri Olsa <jolsa@redhat.com>
    Signed-off-by: Tejun Heo <tj@kernel.org>
    Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  11. @gregkh

    xfs: fix attr2 vs large data fork assert

    Christoph Hellwig authored gregkh committed
    commit 4c393a6 upstream.
    
    With Dmitry fsstress updates I've seen very reproducible crashes in
    xfs_attr_shortform_remove because xfs_attr_shortform_bytesfit claims that
    the attributes would not fit inline into the inode after removing an
    attribute.  It turns out that we were operating on an inode with lots
    of delalloc extents, and thus an if_bytes values for the data fork that
    is larger than biggest possible on-disk storage for it which utterly
    confuses the code near the end of xfs_attr_shortform_bytesfit.
    
    Fix this by always allowing the current attribute fork, like we already
    do for the attr1 format, given that delalloc conversion will take care
    for moving either the data or attribute area out of line if it doesn't
    fit at that point - or making the point moot by merging extents at this
    point.
    
    Also document the function better, and clean up some loose bits.
    
    Reviewed-by: Dave Chinner <dchinner@redhat.com>
    Signed-off-by: Christoph Hellwig <hch@lst.de>
    Signed-off-by: Ben Myers <bpm@sgi.com>
    Acked-by: Dave Chinner <dchinner@redhat.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  12. @gregkh

    xfs: force buffer writeback before blocking on the ilock in inode rec…

    Christoph Hellwig authored gregkh committed
    …laim
    
    commit 4dd2cb4 upstream.
    
    If we are doing synchronous inode reclaim we block the VM from making
    progress in memory reclaim.  So if we encouter a flush locked inode
    promote it in the delwri list and wake up xfsbufd to write it out now.
    Without this we can get hangs of up to 30 seconds during workloads hitting
    synchronous inode reclaim.
    
    The scheme is copied from what we do for dquot reclaims.
    
    Reported-by: Simon Kirby <sim@hostway.ca>
    Signed-off-by: Christoph Hellwig <hch@lst.de>
    Tested-by: Simon Kirby <sim@hostway.ca>
    Signed-off-by: Ben Myers <bpm@sgi.com>
    Acked-by: Dave Chinner <dchinner@redhat.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  13. @gregkh

    xfs: validate acl count

    Christoph Hellwig authored gregkh committed
    commit fa8b18e upstream.
    
    This prevents in-memory corruption and possible panics if the on-disk
    ACL is badly corrupted.
    
    Signed-off-by: Christoph Hellwig <hch@lst.de>
    Signed-off-by: Ben Myers <bpm@sgi.com>
    Acked-by: Dave Chinner <dchinner@redhat.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  14. @gregkh

    NFS: Prevent 3.0 from crashing if it receives a partial layout

    Trond Myklebust authored gregkh committed
    This is a backport of critical parts of
    commit 7c24d94 "NFSv4.1: File layout only supports whole file layouts"
    
    It prevents the file layout driver from (incorrectly) using
    partial layouts, but ignores the part of the referenced commmit that
    relies on additional machinery to change the LAYOUTGET request
    based on layout driver.
    
    Signed-off-by: Fred Isaman <iisaman@netapp.com>
    Acked-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  15. @gitido @gregkh

    genirq: Fix race condition when stopping the irq thread

    gitido authored gregkh committed
    commit 550acb1 upstream.
    
    In irq_wait_for_interrupt(), the should_stop member is verified before
    setting the task's state to TASK_INTERRUPTIBLE and calling schedule().
    In case kthread_stop sets should_stop and wakes up the process after
    should_stop is checked by the irq thread but before the task's state
    is changed, the irq thread might never exit:
    
    kthread_stop                    irq_wait_for_interrupt
    ------------                    ----------------------
    
                                     ...
    ...                              while (!kthread_should_stop()) {
    kthread->should_stop = 1;
    wake_up_process(k);
    wait_for_completion(&kthread->exited);
    ...
                                         set_current_state(TASK_INTERRUPTIBLE);
    
                                         ...
    
                                         schedule();
                                     }
    
    Fix this by checking if the thread should stop after modifying the
    task's state.
    
    [ tglx: Simplified it a bit ]
    
    Signed-off-by: Ido Yariv <ido@wizery.com>
    Link: http://lkml.kernel.org/r/1322740508-22640-1-git-send-email-ido@wizery.com
    Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  16. @mcgrof @gregkh

    cfg80211: amend regulatory NULL dereference fix

    mcgrof authored gregkh committed
    commit 0bac71a upstream.
    
    Johannes' patch for "cfg80211: fix regulatory NULL dereference"
    broke user regulaotry hints and it did not address the fact that
    last_request was left populated even if the previous regulatory
    hint was stale due to the wiphy disappearing.
    
    Fix user reguluatory hints by only bailing out if for those
    regulatory hints where a request_wiphy is expected. The stale last_request
    considerations are addressed through the previous fixes on last_request
    where we reset the last_request to a static world regdom request upon
    reset_regdomains(). In this case though we further enhance the effect
    by simply restoring reguluatory settings completely.
    
    Cc: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
    Reviewed-by: Johannes Berg <johannes@sipsolutions.net>
    Signed-off-by: John W. Linville <linville@tuxdriver.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  17. @mcgrof @gregkh

    cfg80211: fix race on init and driver registration

    mcgrof authored gregkh committed
    commit a042994 upstream.
    
    There is a theoretical race that if hit will trigger
    a crash. The race is between when we issue the first
    regulatory hint, regulatory_hint_core(), gets processed
    by the workqueue and between when the first device
    gets registered to the wireless core. This is not easy
    to reproduce but it was easy to do so through the
    regulatory simulator I have been working on. This
    is a port of the fix I implemented there [1].
    
    [1] mcgrof/regsim@a246ccf
    
    Cc: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
    Signed-off-by: John W. Linville <linville@tuxdriver.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  18. @gregkh

    add missing .set function for NT_S390_LAST_BREAK regset

    Martin Schwidefsky authored gregkh committed
    commit b934069 upstream.
    
    The last breaking event address is a read-only value, the regset misses the
    .set function. If a PTRACE_SETREGSET is done for NT_S390_LAST_BREAK we
    get an oops due to a branch to zero:
    
    Kernel BUG at 0000000000000002 verbose debug info unavailable
    illegal operation: 0001 #1 SMP
    ...
    Call Trace:
    (<0000000000158294> ptrace_regset+0x184/0x188)
     <00000000001595b6> ptrace_request+0x37a/0x4fc
     <0000000000109a78> arch_ptrace+0x108/0x1fc
     <00000000001590d6> SyS_ptrace+0xaa/0x12c
     <00000000005c7a42> sysc_noemu+0x16/0x1c
     <000003fffd5ec10c> 0x3fffd5ec10c
    Last Breaking-Event-Address:
     <0000000000158242> ptrace_regset+0x132/0x188
    
    Add a nop .set function to prevent the branch to zero.
    
    Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  19. @gregkh

    oprofile, x86: Fix crash when unloading module (nmi timer mode)

    Robert Richter authored gregkh committed
    commit 97f7f81 upstream.
    
    If oprofile uses the nmi timer interrupt there is a crash while
    unloading the module. The bug can be triggered with oprofile build as
    module and kernel parameter nolapic set. This patch fixes this.
    
    oprofile: using NMI timer interrupt.
    BUG: unable to handle kernel NULL pointer dereference at 0000000000000008
    IP: [<ffffffff8123c226>] unregister_syscore_ops+0x41/0x58
    PGD 42dbca067 PUD 41da6a067 PMD 0
    Oops: 0002 [#1] PREEMPT SMP
    CPU 5
    Modules linked in: oprofile(-) [last unloaded: oprofile]
    
    Pid: 2518, comm: modprobe Not tainted 3.1.0-rc7-00019-gb2fb49d #19 Advanced Micro Device Anaheim/Anaheim
    RIP: 0010:[<ffffffff8123c226>]  [<ffffffff8123c226>] unregister_syscore_ops+0x41/0x58
    RSP: 0018:ffff88041ef71e98  EFLAGS: 00010296
    RAX: 0000000000000000 RBX: ffffffffa0017100 RCX: dead000000200200
    RDX: 0000000000000000 RSI: dead000000100100 RDI: ffffffff8178c620
    RBP: ffff88041ef71ea8 R08: 0000000000000001 R09: 0000000000000082
    R10: 0000000000000000 R11: ffff88041ef71de8 R12: 0000000000000080
    R13: fffffffffffffff5 R14: 0000000000000001 R15: 0000000000610210
    FS:  00007fc902f20700(0000) GS:ffff88042fd40000(0000) knlGS:0000000000000000
    CS:  0010 DS: 0000 ES: 0000 CR0: 000000008005003b
    CR2: 0000000000000008 CR3: 000000041cdb6000 CR4: 00000000000006e0
    DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
    DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
    Process modprobe (pid: 2518, threadinfo ffff88041ef70000, task ffff88041d348040)
    Stack:
     ffff88041ef71eb8 ffffffffa0017790 ffff88041ef71eb8 ffffffffa0013532
     ffff88041ef71ec8 ffffffffa00132d6 ffff88041ef71ed8 ffffffffa00159b2
     ffff88041ef71f78 ffffffff81073115 656c69666f72706f 0000000000610200
    Call Trace:
     [<ffffffffa0013532>] op_nmi_exit+0x15/0x17 [oprofile]
     [<ffffffffa00132d6>] oprofile_arch_exit+0xe/0x10 [oprofile]
     [<ffffffffa00159b2>] oprofile_exit+0x1e/0x20 [oprofile]
     [<ffffffff81073115>] sys_delete_module+0x1c3/0x22f
     [<ffffffff811bf09e>] ? trace_hardirqs_on_thunk+0x3a/0x3f
     [<ffffffff8148070b>] system_call_fastpath+0x16/0x1b
    Code: 20 c6 78 81 e8 c5 cc 23 00 48 8b 13 48 8b 43 08 48 be 00 01 10 00 00 00 ad de 48 b9 00 02 20 00 00 00 ad de 48 c7 c7 20 c6 78 81
     89 42 08 48 89 10 48 89 33 48 89 4b 08 e8 a6 c0 23 00 5a 5b
    RIP  [<ffffffff8123c226>] unregister_syscore_ops+0x41/0x58
     RSP <ffff88041ef71e98>
    CR2: 0000000000000008
    ---[ end trace 43a541a52956b7b0 ]---
    
    Signed-off-by: Robert Richter <robert.richter@amd.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  20. @gregkh

    perf/x86: Fix PEBS instruction unwind

    Peter Zijlstra authored gregkh committed
    commit 57d1c0c upstream.
    
    Masami spotted that we always try to decode the instruction stream as
    64bit instructions when running a 64bit kernel, this doesn't work for
    ia32-compat proglets.
    
    Use TIF_IA32 to detect if we need to use the 32bit instruction
    decoder.
    
    Reported-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
    Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
    Signed-off-by: Ingo Molnar <mingo@elte.hu>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  21. @gregkh

    x86/paravirt: PTE updates in k(un)map_atomic need to be synchronous, …

    Konrad Rzeszutek Wilk authored gregkh committed
    …regardless of lazy_mmu mode
    
    commit 2cd1c8d upstream.
    
    Fix an outstanding issue that has been reported since 2.6.37.
    Under a heavy loaded machine processing "fork()" calls could
    crash with:
    
    BUG: unable to handle kernel paging request at f573fc8c
    IP: [<c01abc54>] swap_count_continued+0x104/0x180
    *pdpt = 000000002a3b9027 *pde = 0000000001bed067 *pte = 0000000000000000 Oops: 0000 [#1] SMP
    Modules linked in:
    Pid: 1638, comm: apache2 Not tainted 3.0.4-linode37 #1
    EIP: 0061:[<c01abc54>] EFLAGS: 00210246 CPU: 3
    EIP is at swap_count_continued+0x104/0x180
    .. snip..
    Call Trace:
     [<c01ac222>] ? __swap_duplicate+0xc2/0x160
     [<c01040f7>] ? pte_mfn_to_pfn+0x87/0xe0
     [<c01ac2e4>] ? swap_duplicate+0x14/0x40
     [<c01a0a6b>] ? copy_pte_range+0x45b/0x500
     [<c01a0ca5>] ? copy_page_range+0x195/0x200
     [<c01328c6>] ? dup_mmap+0x1c6/0x2c0
     [<c0132cf8>] ? dup_mm+0xa8/0x130
     [<c013376a>] ? copy_process+0x98a/0xb30
     [<c013395f>] ? do_fork+0x4f/0x280
     [<c01573b3>] ? getnstimeofday+0x43/0x100
     [<c010f770>] ? sys_clone+0x30/0x40
     [<c06c048d>] ? ptregs_clone+0x15/0x48
     [<c06bfb71>] ? syscall_call+0x7/0xb
    
    The problem is that in copy_page_range() we turn lazy mode on,
    and then in swap_entry_free() we call swap_count_continued()
    which ends up in:
    
             map = kmap_atomic(page, KM_USER0) + offset;
    
    and then later we touch *map.
    
    Since we are running in batched mode (lazy) we don't actually
    set up the PTE mappings and the kmap_atomic is not done
    synchronously and ends up trying to dereference a page that has
    not been set.
    
    Looking at kmap_atomic_prot_pfn(), it uses
    'arch_flush_lazy_mmu_mode' and doing the same in
    kmap_atomic_prot() and __kunmap_atomic() makes the problem go
    away.
    
    Interestingly, commit b8bcfe9 ("x86/paravirt: remove lazy
    mode in interrupts") removed part of this to fix an interrupt
    issue - but it went to far and did not consider this scenario.
    
    Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
    Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
    Cc: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
    Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
    Signed-off-by: Ingo Molnar <mingo@elte.hu>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  22. @wom-bat @gregkh

    x86: Fix "Acer Aspire 1" reboot hang

    wom-bat authored gregkh committed
    commit 1ef0389 upstream.
    
    Looks like on some Acer Aspire 1s with older bioses, reboot via bios
    fails.  It works on my machine, (with BIOS version 0.3310) but
    not on some others (BIOS version 0.3309).
    
    There's a log of problems at:
    
      https://bbs.archlinux.org/viewtopic.php?id=124136
    
    This patch adds a different callback to the reboot quirk table,
    to allow rebooting via keybaord controller.
    
    Reported-by: Uroš Vampl <mobile.leecher@gmail.com>
    Tested-by: Vasily Khoruzhick <anarsoul@gmail.com>
    Signed-off-by: Peter Chubb <peter.chubb@nicta.com.au>
    Cc: Don Zickus <dzickus@redhat.com>
    Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
    Link: http://lkml.kernel.org/r/1323093233-9481-1-git-send-email-anarsoul@gmail.com
    Signed-off-by: Ingo Molnar <mingo@elte.hu>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  23. @bjorn-helgaas @gregkh

    x86/mpparse: Account for bus types other than ISA and PCI

    bjorn-helgaas authored gregkh committed
    commit 9e68666 upstream.
    
    In commit f8924e7 ("x86: unify mp_bus_info"), the 32-bit
    and 64-bit versions of MP_bus_info were rearranged to match each
    other better.  Unfortunately it introduced a regression: prior
    to that change we used to always set the mp_bus_not_pci bit,
    then clear it if we found a PCI bus.  After it, we set
    mp_bus_not_pci for ISA buses, clear it for PCI buses, and leave
    it alone otherwise.
    
    In the cases of ISA and PCI, there's not much difference.  But
    ISA is not the only non-PCI bus, so it's better to always set
    mp_bus_not_pci and clear it only for PCI.
    
    Without this change, Dan's Dell PowerEdge 4200 panics on boot
    with a log indicating interrupt routing trouble unless the
    "noapic" option is supplied.  With this change, the machine
    boots reliably without "noapic".
    
    Fixes http://bugs.debian.org/586494
    
    Reported-bisected-and-tested-by: Dan McGrath <troubledaemon@gmail.com>
    Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
    Cc: Dan McGrath <troubledaemon@gmail.com>
    Cc: Alexey Starikovskiy <aystarik@gmail.com>
    [jrnieder@gmail.com: clarified commit message]
    Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
    Link: http://lkml.kernel.org/r/20111122215000.GA9151@elie.hsd1.il.comcast.net
    Signed-off-by: Ingo Molnar <mingo@elte.hu>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  24. @sqazi @gregkh

    sched, x86: Avoid unnecessary overflow in sched_clock

    sqazi authored gregkh committed
    commit 4cecf6d upstream.
    
    (Added the missing signed-off-by line)
    
    In hundreds of days, the __cycles_2_ns calculation in sched_clock
    has an overflow.  cyc * per_cpu(cyc2ns, cpu) exceeds 64 bits, causing
    the final value to become zero.  We can solve this without losing
    any precision.
    
    We can decompose TSC into quotient and remainder of division by the
    scale factor, and then use this to convert TSC into nanoseconds.
    
    Signed-off-by: Salman Qazi <sqazi@google.com>
    Acked-by: John Stultz <johnstul@us.ibm.com>
    Reviewed-by: Paul Turner <pjt@google.com>
    Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
    Link: http://lkml.kernel.org/r/20111115221121.7262.88871.stgit@dungbeetle.mtv.corp.google.com
    Signed-off-by: Ingo Molnar <mingo@elte.hu>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  25. @gregkh

    xHCI: fix bug in xhci_clear_command_ring()

    Andiry Xu authored gregkh committed
    commit 158886c upstream.
    
    When system enters suspend, xHCI driver clears command ring by writing zero
    to all the TRBs. However, this also writes zero to the Link TRB, and the ring
    is mangled. This may cause driver accesses wrong memory address and the
    result is unpredicted.
    
    When clear the command ring, keep the last Link TRB intact, only clear its
    cycle bit. This should fix the "command ring full" issue reported by Oliver
    Neukum.
    
    This should be backported to stable kernels as old as 2.6.37, since the
    commit 8982132 "xhci: Fix command ring replay after resume" is merged.
    
    Signed-off-by: Andiry Xu <andiry.xu@amd.com>
    Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
    Reported-by: Oliver Neukum <oneukum@suse.de>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  26. @mat-c @gregkh

    EHCI : Fix a regression in the ISO scheduler

    mat-c authored gregkh committed
    commit e342090 upstream.
    
    Fix a regression that was introduced by commit
    811c926 (USB: EHCI: fix HUB TT scheduling
    issue with iso transfer).
    
    We detect an error if next == start, but this means uframe 0 can't be allocated
    anymore for iso transfer...
    
    Reported-by: Sander Eikelenboom <linux@eikelenboom.it>
    Signed-off-by: Matthieu CASTET <castet.matthieu@free.fr>
    Acked-by: Alan Stern <stern@rowland.harvard.edu>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  27. @gregkh

    USB: EHCI: fix HUB TT scheduling issue with iso transfer

    Thomas Poussevin authored gregkh committed
    commit 811c926 upstream.
    
    The current TT scheduling doesn't allow to play and then record on a
    full-speed device connected to a high speed hub.
    
    The IN iso stream can only start on the first uframe (0-2 for a 165 us)
    because of CSPLIT transactions.
    For the OUT iso stream there no such restriction. uframe 0-5 are possible.
    
    The idea of this patch is that the first uframe are precious (for IN TT iso
    stream) and we should allocate the last uframes first if possible.
    
    For that we reverse the order of uframe allocation (last uframe first).
    
    Here an example :
    
    hid interrupt stream
    ----------------------------------------------------------------------
    uframe                |  0  |  1  |  2  |  3  |  4  |  5  |  6  |  7  |
    ----------------------------------------------------------------------
    max_tt_usecs          | 125 | 125 | 125 | 125 | 125 | 125 | 30  |  0  |
    ----------------------------------------------------------------------
    used usecs on a frame | 13  |  0  |  0  |  0  |  0  |  0  |  0  |  0  |
    ----------------------------------------------------------------------
    
    iso OUT stream
    ----------------------------------------------------------------------
    uframe                |  0  |  1  |  2  |  3  |  4  |  5  |  6  |  7  |
    ----------------------------------------------------------------------
    max_tt_usecs          | 125 | 125 | 125 | 125 | 125 | 125 | 30  |  0  |
    ----------------------------------------------------------------------
    used usecs on a frame | 13  | 125 |  39 |  0  |  0  |  0  |  0  |  0  |
    ----------------------------------------------------------------------
    
    There no place for iso IN stream  (uframe 0-2 are used) and we got "cannot
    submit datapipe for urb 0, error -28: not enough bandwidth" error.
    
    With the patch this become.
    
    iso OUT stream
    ----------------------------------------------------------------------
    uframe                |  0  |  1  |  2  |  3  |  4  |  5  |  6  |  7  |
    ----------------------------------------------------------------------
    max_tt_usecs          | 125 | 125 | 125 | 125 | 125 | 125 | 30  |  0  |
    ----------------------------------------------------------------------
    used usecs on a frame |  13 |  0  |  0  |  0  | 125 |  39 |  0  |  0  |
    ----------------------------------------------------------------------
    
    iso IN stream
    ----------------------------------------------------------------------
    uframe                |  0  |  1  |  2  |  3  |  4  |  5  |  6  |  7  |
    ----------------------------------------------------------------------
    max_tt_usecs          | 125 | 125 | 125 | 125 | 125 | 125 | 30  |  0  |
    ----------------------------------------------------------------------
    used usecs on a frame |  13 |  0  | 125 | 40  | 125 |  39 |  0  |  0  |
    ----------------------------------------------------------------------
    
    Signed-off-by: Matthieu Castet <matthieu.castet@parrot.com>
    Signed-off-by: Thomas Poussevin <thomas.poussevin@parrot.com>
    Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  28. @yestyle @gregkh

    USB: usb-storage: unusual_devs entry for Kingston DT 101 G2

    yestyle authored gregkh committed
    commit cec28a5 upstream.
    
    Kingston DT 101 G2 replies a wrong tag while transporting, add an
    unusal_devs entry to ignore the tag validation.
    
    Signed-off-by: Qinglin Ye <yestyle@gmail.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  29. @gregkh

    usb: option: add SIMCom SIM5218

    Veli-Pekka Peltola authored gregkh committed
    commit ec0cd94 upstream.
    
    Tested with SIM5218EVB-KIT evaluation kit.
    
    Signed-off-by: Veli-Pekka Peltola <veli-pekka.peltola@bluegiga.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  30. @gregkh

    usb: option: add Huawei E353 controlling interfaces

    Dirk Nehring authored gregkh committed
    commit 46b1848 upstream.
    
    This patch creates the missing controlling devices for the Huawei E353
    HSPA+ stick.
    
    Signed-off-by: Dirk Nehring <dnehring@gmx.net>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  31. @koriakin @gregkh

    usb: ftdi_sio: add PID for Propox ISPcable III

    koriakin authored gregkh committed
    commit 307369b upstream.
    
    Signed-off-by: Marcin Kościelnicki <koriakin@0x04.net>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  32. @bentiss @gregkh

    HID: Correct General touch PID

    bentiss authored gregkh committed
    commit b180771 upstream.
    
    Genera Touch told us that 0001 is their single point device
    and 0003 is the multitouch one. Apparently, we made the tests
    someone having a prototype, and not the final product.
    They said it should be safe to do the switch.
    
    This partially reverts 5572da0 ("HID: hid-mulitouch: add support
    for the 'Sensing Win7-TwoFinger'").
    
    Signed-off-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
    Signed-off-by: Jiri Kosina <jkosina@suse.cz>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  33. @gregkh

    USB: whci-hcd: fix endian conversion in qset_clear()

    Dan Carpenter authored gregkh committed
    commit 8746c83 upstream.
    
    qset->qh.link is an __le64 field and we should be using cpu_to_le64()
    to fill it.
    
    Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  34. @FedericoVaga @gregkh

    Staging: comedi: fix signal handling in read and write

    FedericoVaga authored gregkh committed
    commit 6a9ce6b upstream.
    
    After sleeping on a wait queue, signal_pending(current) should be
    checked (not before sleeping).
    
    Acked-by: Alessandro Rubini <rubini@gnudd.com>
    Signed-off-by: Federico Vaga <federico.vaga@gmail.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  35. @FedericoVaga @gregkh

    Staging: comedi: fix mmap_count

    FedericoVaga authored gregkh committed
    commit df30b21 upstream.
    
    In comedi_fops, mmap_count is decremented at comedi_vm_ops->close but
    it is not incremented at comedi_vm_ops->open. This may result in a negative
    counter.  The patch introduces the open method to keep the counter
    consistent.
    
    The bug was triggerd by this sample code:
    
            mmap(0, ...., comedi_fd);
            fork();
            exit(0);
    
    Acked-by: Alessandro Rubini <rubini@gnudd.com>
    Signed-off-by: Federico Vaga <federico.vaga@gmail.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Something went wrong with that request. Please try again.