1. 04 Dec, 2012 3 commits
    • Eldad Zack's avatar
      ALSA: usb-audio: sync ep init fix for audioformat mismatch · 0d9741c0
      Eldad Zack authored
      Commit 947d2996 , "ALSA: snd-usb:
      properly initialize the sync endpoint", while correcting the
      initialization of the sync endpoint when opening just the data
      endpoint, prevents devices that has a sync endpoint, with a channel
      number different than that of the data endpoint, from functioning.
      Due to a different channel and period bytes count, attempting to
      initialize the sync endpoint will fail at the usb host driver.
      For example, when using xhci:
      
       cannot submit urb 0, error -90: internal error
      
      With this patch, if a sync endpoint has multiple audioformats, a
      matching audioformat is preferred. An audioformat must be found
      with at least one channel and support the requested sample rate
      and PCM format, otherwise the stream will not be opened.
      
      If the number of channels differ between the selected audioformat
      and the requested format, adjust the period bytes count accordingly.
      It is safe to perform the calculation on the basis of the channel
      count, since the requested PCM audio format and the rate must be
      supported by the selected audioformat.
      
      Cc: Jeffrey Barish <jeff_barish@earthlink.net>
      Cc: Daniel Mack <zonque@gmail.com>
      Signed-off-by: default avatarEldad Zack <eldad@fogrefinery.com>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      0d9741c0
    • Takashi Iwai's avatar
      ALSA: usb-audio: Fix missing autopm for MIDI input · f5f16541
      Takashi Iwai authored
      The commit [88a8516a: ALSA: usbaudio: implement USB autosuspend] added
      the support of autopm for USB MIDI output, but it didn't take the MIDI
      input into account.
      
      This patch adds the following for fixing the autopm:
      - Manage the URB start at the first MIDI input stream open, instead of
        the time of instance creation
      - Move autopm code to the common substream_open()
      - Make snd_usbmidi_input_start/_stop() more robust and add the running
        state check
      Reviewd-by: default avatarClemens Ladisch <clemens@ladisch.de>
      Tested-by: default avatarClemens Ladisch <clemens@ladisch.de>
      Cc: <stable@vger.kernel.org>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      f5f16541
    • Takashi Iwai's avatar
      ALSA: usb-audio: Avoid autopm calls after disconnection · 59866da9
      Takashi Iwai authored
      Add a similar protection against the disconnection race and the
      invalid use of usb instance after disconnection, as well as we've done
      for the USB audio PCM.
      
      Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=51201Reviewd-by: default avatarClemens Ladisch <clemens@ladisch.de>
      Tested-by: default avatarClemens Ladisch <clemens@ladisch.de>
      Cc: <stable@vger.kernel.org>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      59866da9
  2. 03 Dec, 2012 5 commits
  3. 02 Dec, 2012 32 commits