1. 22 Nov, 2014 6 commits
  2. 21 Nov, 2014 4 commits
  3. 20 Nov, 2014 1 commit
  4. 18 Nov, 2014 1 commit
  5. 17 Nov, 2014 5 commits
  6. 14 Nov, 2014 4 commits
  7. 13 Nov, 2014 4 commits
  8. 11 Nov, 2014 6 commits
  9. 10 Nov, 2014 2 commits
  10. 09 Nov, 2014 2 commits
    • Takashi Iwai's avatar
      ALSA: usb-audio: Allow multiple entries for the same iface in composite quirk · d4b8fc66
      Takashi Iwai authored
      Currently the composite quirk doesn't work when multiple entries are
      assigned to the same interface because it marks the interface as
      claimed then checks whether the interface has been already claimed for
      the secondary entry.  But, if you look at the code, you'll notice that
      multiple entries are allowed if the entry is the current interface;
      i.e. the current behavior is anyway inconsistent, and this is an
      unintended shortcoming.
      
      This patch fixes the problem by marking the relevant interfaces as
      claimed after applying the all composite entries.  This fix will be
      needed for the upcoming enhancements for Digidesign Mbox 1 quirks.
      Reviewed-by: default avatarClemens Ladisch <clemens@ladisch.de>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      d4b8fc66
    • Takashi Iwai's avatar
      ALSA: pcm: Add snd_pcm_stop_xrun() helper · 1fb8510c
      Takashi Iwai authored
      Add a new helper function snd_pcm_stop_xrun() to the standard sequnce
      lock/snd_pcm_stop(XRUN)/unlock by a single call, and replace the
      existing open codes with this helper.
      
      The function checks the PCM running state to prevent setting the wrong
      state, too, for more safety.
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      1fb8510c
  11. 07 Nov, 2014 1 commit
  12. 06 Nov, 2014 2 commits
    • Takashi Iwai's avatar
      ALSA: usb-audio: Trigger PCM XRUN at XRUN · 67e22500
      Takashi Iwai authored
      The usb-audio driver detects XRUN at its complete callback, but the
      actual code to trigger PCM XRUN is commented out because it caused
      deadlock in the past.  This patch revives the PCM trigger properly.
      It resulted in more than just enabling snd_pcm_stop(), but it had to
      deduce the PCM substream with proper NULL checks and holds the stream
      lock around the call.
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      67e22500
    • Takashi Iwai's avatar
      ALSA: pcm: Update the state properly before notification · 9bc889b4
      Takashi Iwai authored
      Some state changes (e.g. snd_pcm_stop()) sets the runtime state after
      calling snd_timer_notify().  This is basically racy, since the
      notification may wakes up the user even before the state change.
      Although the possibility is low, we should set the state before the
      notifications.
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      9bc889b4
  13. 05 Nov, 2014 2 commits
    • Takashi Iwai's avatar
      Merge branch 'for-linus' into for-next · 19566b0b
      Takashi Iwai authored
      This merges the USB-audio disconnect fix and resolves the conflicts
      so that we can continue working on development of usb-audio stuff.
      
      Conflicts:
      	sound/usb/card.c
      19566b0b
    • Takashi Iwai's avatar
      ALSA: usb-audio: Fix device_del() sysfs warnings at disconnect · 0725dda2
      Takashi Iwai authored
      Some USB-audio devices show weird sysfs warnings at disconnecting the
      devices, e.g.
       usb 1-3: USB disconnect, device number 3
       ------------[ cut here ]------------
       WARNING: CPU: 0 PID: 973 at fs/sysfs/group.c:216 device_del+0x39/0x180()
       sysfs group ffffffff8183df40 not found for kobject 'midiC1D0'
       Call Trace:
        [<ffffffff814a3e38>] ? dump_stack+0x49/0x71
        [<ffffffff8103cb72>] ? warn_slowpath_common+0x82/0xb0
        [<ffffffff8103cc55>] ? warn_slowpath_fmt+0x45/0x50
        [<ffffffff813521e9>] ? device_del+0x39/0x180
        [<ffffffff81352339>] ? device_unregister+0x9/0x20
        [<ffffffff81352384>] ? device_destroy+0x34/0x40
        [<ffffffffa00ba29f>] ? snd_unregister_device+0x7f/0xd0 [snd]
        [<ffffffffa025124e>] ? snd_rawmidi_dev_disconnect+0xce/0x100 [snd_rawmidi]
        [<ffffffffa00c0192>] ? snd_device_disconnect+0x62/0x90 [snd]
        [<ffffffffa00c025c>] ? snd_device_disconnect_all+0x3c/0x60 [snd]
        [<ffffffffa00bb574>] ? snd_card_disconnect+0x124/0x1a0 [snd]
        [<ffffffffa02e54e8>] ? usb_audio_disconnect+0x88/0x1c0 [snd_usb_audio]
        [<ffffffffa015260e>] ? usb_unbind_interface+0x5e/0x1b0 [usbcore]
        [<ffffffff813553e9>] ? __device_release_driver+0x79/0xf0
        [<ffffffff81355485>] ? device_release_driver+0x25/0x40
        [<ffffffff81354e11>] ? bus_remove_device+0xf1/0x130
        [<ffffffff813522b9>] ? device_del+0x109/0x180
        [<ffffffffa01501d5>] ? usb_disable_device+0x95/0x1f0 [usbcore]
        [<ffffffffa014634f>] ? usb_disconnect+0x8f/0x190 [usbcore]
        [<ffffffffa0149179>] ? hub_thread+0x539/0x13a0 [usbcore]
        [<ffffffff810669f5>] ? sched_clock_local+0x15/0x80
        [<ffffffff81066c98>] ? sched_clock_cpu+0xb8/0xd0
        [<ffffffff81070730>] ? bit_waitqueue+0xb0/0xb0
        [<ffffffffa0148c40>] ? usb_port_resume+0x430/0x430 [usbcore]
        [<ffffffffa0148c40>] ? usb_port_resume+0x430/0x430 [usbcore]
        [<ffffffff8105973e>] ? kthread+0xce/0xf0
        [<ffffffff81059670>] ? kthread_create_on_node+0x1c0/0x1c0
        [<ffffffff814a8b7c>] ? ret_from_fork+0x7c/0xb0
        [<ffffffff81059670>] ? kthread_create_on_node+0x1c0/0x1c0
       ---[ end trace 40b1928d1136b91e ]---
      
      This comes from the fact that usb-audio driver may receive the
      disconnect callback multiple times, per each usb interface.  When a
      device has both audio and midi interfaces, it gets called twice, and
      currently the driver tries to release resources at the last call.
      At this point, the first parent interface has been already deleted,
      thus deleting a child of the first parent hits such a warning.
      
      For fixing this problem, we need to call snd_card_disconnect() and
      cancel pending operations at the very first disconnect while the
      release of the whole objects waits until the last disconnect call.
      
      Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=80931Reported-and-tested-by: default avatarTomas Gayoso <tgayoso@gmail.com>
      Reported-and-tested-by: default avatarChris J Arges <chris.j.arges@canonical.com>
      Cc: <stable@vger.kernel.org>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      0725dda2