1. 14 May, 2018 5 commits
  2. 13 May, 2018 16 commits
  3. 04 May, 2018 7 commits
  4. 03 May, 2018 2 commits
  5. 02 May, 2018 10 commits
    • Takashi Iwai's avatar
      ALSA: usb-audio: Give proper vendor/product name for Dell WD15 Dock · 6455abb4
      Takashi Iwai authored
      Dell WD15 Dock with 0bda:4014 doesn't give any useful strings for the
      vendor and the product names.  Name them more specifically via quirk,
      as well as the UCM profile name.
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      6455abb4
    • Takashi Iwai's avatar
      ALSA: usb-audio: Allow to override the longname string · 07eca5fc
      Takashi Iwai authored
      Historically USB-audio driver sets the card's longname field with the
      details of the device and the bus information.  It's good per se, but
      not preferable when it's referred as the identifier for UCM profile.
      
      This patch adds a quirk profile_name field to override the card's
      longname string to a pre-defined one, so that one can create a unique
      and consistent ID string for the specific USB device via a quirk table
      to be used as a UCM profile name.
      
      The patch does a slight code refactoring to split out the functions to
      set shortname and longname fields as well.
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      07eca5fc
    • Takashi Iwai's avatar
      ALSA: usb-audio: Add "Keep Interface" control · 4120fbed
      Takashi Iwai authored
      This patch adds "Keep Interface" control for each USB-audio device.
      The control element is with SND_CTL_IFACE_CARD, so that it won't
      appear on any sane mixer applications.  For a device that is confirmed
      to work well with "keep-interface" mode, user can flip the control via
      amixer, e.g.
        % amixer -c1 cset iface=CARD,name='Keep Interface' on
      
      and save/restore the state via alsactl.
      
      The reason to provide this via control API is that the behavior must
      be pretty depending on the device (and the firmware in it), so it's
      not ideal to apply via module option.
      
      For a device that certainly works, we may set it statically via a
      quirk table entry.  But a device like Dell WD15 dock behaves so
      differently depending on the firmware, and we can't set it
      statically.  So leave this as a dynamic switch each user can adjust
      freely.
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      4120fbed
    • Takashi Iwai's avatar
      ALSA: usb-audio: Add keep_iface flag · 8a463225
      Takashi Iwai authored
      Introduce a new flag to struct snd_usb_audio for allowing the device
      to skip usb_set_interface() calls at changing or closing the stream.
      As of this patch, the flag is nowhere set, so it's just a place
      holder.  The dynamic switching will be added in the following patch.
      
      A background information for this change:
      
      Dell WD15 dock with Realtek chip gives a very long pause at each time
      the driver changes the altset, which eventually happens at every PCM
      stream open/close and parameter change.  As the long pause happens in
      each usb_set_interface() call, there is nothing we can do as long as
      it's called.  The workaround is to reduce calling it as much as
      possible, and this flag indicates that behavior.
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      8a463225
    • Takashi Iwai's avatar
      ALSA: usb-audio: Avoid superfluous usb_set_interface() calls · b099b969
      Takashi Iwai authored
      This is a preliminary change for the upcoming quirk implementation.
      
      Currently USB-audio driver tries to call usb_set_interface() whenever
      the format change with interface/altset modification happens.  In this
      patch, the check is replaced with the comparison of cur_altsetting and
      the targeted altsetting pointer, so that the driver may skip the
      unnecessary function calls.
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      b099b969
    • Takashi Iwai's avatar
      ALSA: usb-audio: Initialize Dell Dock playback volumes · 964af639
      Takashi Iwai authored
      In the early commit adcdd0d5 ("ALSA: usb-audio: Skip volume
      controls triggers hangup on Dell USB Dock"), we add the mixer quirks
      for Dell dock to skip two mixer FU's for playback.  This supposed that
      the device has always the proper initial volume, but it doesn't seem
      always correct.
      
      This patch adds the explicit initialization of the volumes to the
      fixed 0dB at the device probe time.  Also, such a fixup is needed
      after the resume, so a new function is hooked to the resume callback
      as well.
      
      Bugzilla: http://bugzilla.suse.com/show_bug.cgi?id=1089467Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      964af639
    • Takashi Sakamoto's avatar
      ALSA: dice: remove local frag of force_two_pcms · 9c367c01
      Takashi Sakamoto authored
      At present, to add PCM substreams for each of available tx/rx streams,
      this driver uses a condition based on model-name. This is not enough
      to support unknown models.
      
      In former commits, this driver gains cache of stream formats. For models
      which support protocol extension, all of available steam formats are
      cached. For known models, hard-coded stream formats are used to generate
      the cache. For unknown models, stream formats at current mode of sampling
      transmission frequency is cached.
      
      Anyway, at least, the cached formats are used to expose constrains of PCM
      substreams for userspace applications. Thus, The cached data can be also
      used to add PCM substreams themselves, instead of the name-based
      conditions.
      
      This commit obsoletes local frag of force_two_pcms.
      Signed-off-by: default avatarTakashi Sakamoto <o-takashi@sakamocchi.jp>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      9c367c01
    • Takashi Sakamoto's avatar
      ALSA: dice: use cache for PCM constraints and rules · bd2b441c
      Takashi Sakamoto authored
      In former commits, proxy structure gets members for cache of stream
      formats. The cache allows to apply correct constraints and rules to
      runtime of PCM substream. They allows userspace applications to change
      current sampling transmission frequency.
      
      This commit uses the cacher for the PCM constraints and rules.
      Signed-off-by: default avatarTakashi Sakamoto <o-takashi@sakamocchi.jp>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      bd2b441c
    • Takashi Sakamoto's avatar
      ALSA: dice: use stream formats to add MIDI substreams · b8f78234
      Takashi Sakamoto authored
      In former commits, proxy structure gets members for cache of stream
      formats. The cache can be used to count the number of MIDI substreams
      to add.
      
      This commit uses the cache for this purpose.
      Signed-off-by: default avatarTakashi Sakamoto <o-takashi@sakamocchi.jp>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      b8f78234
    • Takashi Sakamoto's avatar
      ALSA: dice: enable to change current sampling transmission frequency · afa617f2
      Takashi Sakamoto authored
      This is a preparation for userspace applications to change current sampling
      transmission frequency via ALSA PCM interface.
      Signed-off-by: default avatarTakashi Sakamoto <o-takashi@sakamocchi.jp>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      afa617f2