1. 11 Jan, 2013 32 commits
  2. 17 Dec, 2012 8 commits
    • Greg Kroah-Hartman's avatar
      Linux 3.7.1 · cc860507
      Greg Kroah-Hartman authored
      cc860507
    • Kevin McKinney's avatar
      Staging: bcm: Add two products and remove an existing product. · 53730b4c
      Kevin McKinney authored
      commit 4f29ef05 upstream.
      
      This patch adds two new products and modifies
      the device id table to include them. In addition,
      product of 0xbccd - BCM_USB_PRODUCT_ID_SM250 is
      removed because Beceem, ZTE, Sprint use this id
      for block devices.
      Reported-by: default avatarMuhammad Minhazul Haque <mdminhazulhaque@gmail.com>
      Signed-off-by: default avatarKevin McKinney <klmckinney1@gmail.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      53730b4c
    • Eric Dumazet's avatar
      rcu: Fix batch-limit size problem · 5ebf81ae
      Eric Dumazet authored
      commit 878d7439 upstream.
      
      Commit 29c00b4a (rcu: Add event-tracing for RCU callback
      invocation) added a regression in rcu_do_batch()
      
      Under stress, RCU is supposed to allow to process all items in queue,
      instead of a batch of 10 items (blimit), but an integer overflow makes
      the effective limit being 1.  So, unless there is frequent idle periods
      (during which RCU ignores batch limits), RCU can be forced into a
      state where it cannot keep up with the callback-generation rate,
      eventually resulting in OOM.
      
      This commit therefore converts a few variables in rcu_do_batch() from
      int to long to fix this problem, along with the module parameters
      controlling the batch limits.
      Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
      Signed-off-by: default avatarPaul E. McKenney <paulmck@linux.vnet.ibm.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      5ebf81ae
    • Alan Stern's avatar
      USB: EHCI: bugfix: urb->hcpriv should not be NULL · 2083ca13
      Alan Stern authored
      commit 2656a9ab upstream.
      
      This patch (as1632b) fixes a bug in ehci-hcd.  The USB core uses
      urb->hcpriv to determine whether or not an URB is active; host
      controller drivers are supposed to set this pointer to a non-NULL
      value when an URB is queued.  However ehci-hcd sets it to NULL for
      isochronous URBs, which defeats the check in usbcore.
      
      In itself this isn't a big deal.  But people have recently found that
      certain sequences of actions will cause the snd-usb-audio driver to
      reuse URBs without waiting for them to complete.  In the absence of
      proper checking by usbcore, the URBs get added to their endpoint list
      twice.  This leads to list corruption and a system freeze.
      
      The patch makes ehci-hcd assign a meaningful value to urb->hcpriv for
      isochronous URBs.  Improving robustness always helps.
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Reported-by: default avatarArtem S. Tashkinov <t.artem@lycos.com>
      Reported-by: default avatarChristof Meerwald <cmeerw@cmeerw.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      2083ca13
    • Zheng Liu's avatar
      perf test: fix a build error on builtin-test · 9eb7f694
      Zheng Liu authored
      commit 12f8f74b upstream.
      
      Recently I build perf and get a build error on builtin-test.c. The error is as
      following:
      
      $ make
          CC perf.o
          CC builtin-test.o
      cc1: warnings being treated as errors
      builtin-test.c: In function ‘sched__get_first_possible_cpu’:
      builtin-test.c:977: warning: implicit declaration of function ‘CPU_ALLOC’
      builtin-test.c:977: warning: nested extern declaration of ‘CPU_ALLOC’
      builtin-test.c:977: warning: assignment makes pointer from integer without a cast
      builtin-test.c:978: warning: implicit declaration of function ‘CPU_ALLOC_SIZE’
      builtin-test.c:978: warning: nested extern declaration of ‘CPU_ALLOC_SIZE’
      builtin-test.c:979: warning: implicit declaration of function ‘CPU_ZERO_S’
      builtin-test.c:979: warning: nested extern declaration of ‘CPU_ZERO_S’
      builtin-test.c:982: warning: implicit declaration of function ‘CPU_FREE’
      builtin-test.c:982: warning: nested extern declaration of ‘CPU_FREE’
      builtin-test.c:992: warning: implicit declaration of function ‘CPU_ISSET_S’
      builtin-test.c:992: warning: nested extern declaration of ‘CPU_ISSET_S’
      builtin-test.c:998: warning: implicit declaration of function ‘CPU_CLR_S’
      builtin-test.c:998: warning: nested extern declaration of ‘CPU_CLR_S’
      make: *** [builtin-test.o] Error 1
      
      This problem is introduced in 3e7c439a. CPU_ALLOC and related macros are
      missing in sched__get_first_possible_cpu function. In 54489c18, commiter
      mentioned that CPU_ALLOC has been removed. So CPU_ALLOC calls in this
      function are removed to let perf to be built.
      Signed-off-by: default avatarVinson Lee <vlee@twitter.com>
      Signed-off-by: default avatarZheng Liu <wenqing.lz@taobao.com>
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Stephane Eranian <eranian@google.com>
      Cc: Vinson Lee <vlee@twitter.com>
      Cc: Zheng Liu <wenqing.lz@taobao.com>
      Link: http://lkml.kernel.org/r/1352422726-31114-1-git-send-email-vlee@twitter.comSigned-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      9eb7f694
    • Dan Williams's avatar
      cdc-acm: implement TIOCSSERIAL to avoid blocking close(2) · 45d6c5dd
      Dan Williams authored
      commit ba2d8ce9 upstream.
      
      Some devices (ex Nokia C7) simply don't respond at all when data is sent
      to some of their USB interfaces.  The data gets stuck in the TTYs queue
      and sits there until close(2), which them blocks because closing_wait
      defaults to 30 seconds (even though the fd is O_NONBLOCK).  This is
      rarely desired.  Implement the standard mechanism to adjust closing_wait
      and let applications handle it how they want to.
      
      See also 02303f73 for usb_wwan.c.
      Signed-off-by: default avatarDan Williams <dcbw@redhat.com>
      Acked-by: default avatarOliver Neukum <oneukum@suse.de>
      Tested-by: default avatarAleksander Morgado <aleksander@gnu.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      45d6c5dd
    • Steven Rostedt's avatar
      ring-buffer: Fix race between integrity check and readers · f99b4b46
      Steven Rostedt authored
      commit 9366c1ba upstream.
      
      The function rb_check_pages() was added to make sure the ring buffer's
      pages were sane. This check is done when the ring buffer size is modified
      as well as when the iterator is released (closing the "trace" file),
      as that was considered a non fast path and a good place to do a sanity
      check.
      
      The problem is that the check does not have any locks around it.
      If one process were to read the trace file, and another were to read
      the raw binary file, the check could happen while the reader is reading
      the file.
      
      The issues with this is that the check requires to clear the HEAD page
      before doing the full check and it restores it afterward. But readers
      require the HEAD page to exist before it can read the buffer, otherwise
      it gives a nasty warning and disables the buffer.
      
      By adding the reader lock around the check, this keeps the race from
      happening.
      Signed-off-by: default avatarSteven Rostedt <rostedt@goodmis.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      f99b4b46
    • Steven Rostedt's avatar
      ring-buffer: Fix NULL pointer if rb_set_head_page() fails · 7c3432b1
      Steven Rostedt authored
      commit 54f7be5b upstream.
      
      The function rb_set_head_page() searches the list of ring buffer
      pages for a the page that has the HEAD page flag set. If it does
      not find it, it will do a WARN_ON(), disable the ring buffer and
      return NULL, as this should never happen.
      
      But if this bug happens to happen, not all callers of this function
      can handle a NULL pointer being returned from it. That needs to be
      fixed.
      Signed-off-by: default avatarSteven Rostedt <rostedt@goodmis.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      7c3432b1