Skip to content
  1. Oct 30, 2012
    • Takashi Iwai's avatar
      ALSA: usb-audio: Fix races at disconnection · 978520b7
      Takashi Iwai authored
      
      
      Close some races at disconnection of a USB audio device by adding the
      chip->shutdown_mutex and chip->shutdown check at appropriate places.
      
      The spots to put bandaids are:
      - PCM prepare, hw_params and hw_free
      - where the usb device is accessed for communication or get speed, in
       mixer.c and others; the device speed is now cached in subs->speed
       instead of accessing to chip->dev
      
      The accesses in PCM open and close don't need the mutex protection
      because these are already handled in the core PCM disconnection code.
      
      The autosuspend/autoresume codes are still uncovered by this patch
      because of possible mutex deadlocks.  They'll be covered by the
      upcoming change to rwsem.
      
      Also the mixer codes are untouched, too.  These will be fixed in
      another patch, too.
      
      Reported-by: default avatarMatthieu CASTET <matthieu.castet@parrot.com>
      Cc: <stable@vger.kernel.org>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      978520b7
    • Takashi Iwai's avatar
      ALSA: PCM: Fix some races at disconnection · 9b0573c0
      Takashi Iwai authored
      
      
      Fix races at PCM disconnection:
      - while a PCM device is being opened or closed
      - while the PCM state is being changed without lock in prepare,
        hw_params, hw_free ops
      
      Reported-by: default avatarMatthieu CASTET <matthieu.castet@parrot.com>
      Cc: <stable@vger.kernel.org>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      9b0573c0
  2. Oct 28, 2012
  3. Oct 26, 2012
  4. Oct 24, 2012
  5. Oct 22, 2012
  6. Oct 21, 2012
    • Julia Lawall's avatar
      ALSA: sound/isa/opti9xx/miro.c: eliminate possible double free · edb66893
      Julia Lawall authored
      
      
      snd_miro_probe is a static function that is only called twice in the file
      that defines it.  At each call site, its argument is freed using
      snd_card_free.  Thus, there is no need for snd_miro_probe to call
      snd_card_free on its argument on any of its error exit paths.
      
      Because snd_card_free both reads the fields of its argument and kfrees its
      argments, the results of the second snd_card_free should be unpredictable.
      
      A simplified version of the semantic match that finds this problem is as
      follows: (http://coccinelle.lip6.fr/)
      
      // <smpl>
      @r@
      identifier f,free,a;
      parameter list[n] ps;
      type T;
      expression e;
      @@
      
      f(ps,T a,...) {
        ... when any
            when != a = e
        if(...) { ... free(a); ... return ...; }
        ... when any
      }
      
      @@
      identifier r.f,r.free;
      expression x,a;
      expression list[r.n] xs;
      @@
      
      * x = f(xs,a,...);
        if (...) { ... free(a); ... return ...; }
      // </smpl>
      
      Signed-off-by: default avatarJulia Lawall <Julia.Lawall@lip6.fr>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      edb66893
    • Linus Torvalds's avatar
      Linux 3.7-rc2 · 6f0c0580
      Linus Torvalds authored
      6f0c0580
    • Linus Torvalds's avatar
      Merge tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/cmarinas/linux-aarch64 · 198190a1
      Linus Torvalds authored
      Pull arm64 fixes from Catalin Marinas:
       "Main changes:
         - AArch64 Linux compilation fixes following 3.7-rc1 changes
           (MODULES_USE_ELF_RELA, update_vsyscall() prototype)
         - Unnecessary register setting in start_thread() (thanks to Al Viro)
         - ptrace fixes"
      
      * tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/cmarinas/linux-aarch64:
        arm64: fix alignment padding in assembly code
        arm64: ptrace: use HW_BREAKPOINT_EMPTY type for disabled breakpoints
        arm64: ptrace: make structure padding explicit for debug registers
        arm64: No need to set the x0-x2 registers in start_thread()
        arm64: Ignore memory blocks below PHYS_OFFSET
        arm64: Fix the update_vsyscall() prototype
        arm64: Select MODULES_USE_ELF_RELA
        arm64: Remove duplicate inclusion of mmu_context.h in smp.c
      198190a1
    • Takashi Iwai's avatar
      ALSA: hda - Fix silent headphone output from Toshiba P200 · cb766404
      Takashi Iwai authored
      
      
      By some reason, Toshiba laptop doesn't like the EAPD turned up for the
      headphone pin.  Add a fix up code to force to turn down EAPD for NID
      0x15.
      
      Bugzilla: https://bugzilla.novell.com/show_bug.cgi?id=569991
      
      Cc: <stable@vger.kernel.org>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      cb766404
  7. Oct 20, 2012