1. 20 3月, 2013 1 次提交
  2. 12 3月, 2013 1 次提交
    • T
      ALSA: hda - Fix snd_hda_get_num_raw_conns() to return a correct value · b5f82b10
      Takashi Iwai 提交于
      In the connection list expansion in hda_codec.c and hda_proc.c, the
      value returned from snd_hda_get_num_raw_conns() is used as the array
      size to store the connection list.  However, the function returns
      simply a raw value of the AC_PAR_CONNLIST_LEN parameter, and the
      widget list with ranges isn't considered there.  Thus it may return a
      smaller size than the actual list, which results in -ENOSPC in
      snd_hda_get_raw_conections().
      
      This patch fixes the bug by parsing the connection list correctly also
      for snd_hda_get_num_raw_conns().
      Reported-and-tested-by: NDavid Henningsson <david.henningsson@canonical.com>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      b5f82b10
  3. 07 3月, 2013 2 次提交
  4. 13 2月, 2013 1 次提交
    • T
      ALSA: hda - Fix broken workaround for HDMI/SPDIF conflicts · ea9b43ad
      Takashi Iwai 提交于
      The commit [dcda5806: ALSA: hda - Add workaround for conflicting
      IEC958 controls] introduced a workaround for cards that have both
      SPDIF and HDMI devices for giving device=1 to SPDIF control elements.
      It turned out, however, that this workaround doesn't work well -
      
      - The workaround checks only conflicts in a single codec, but SPDIF
        and HDMI are provided by multiple codecs in many cases, and
      
      - ALSA mixer abstraction doesn't care about the device number in ctl
        elements, thus you'll get errors from amixer such as
        % amixer scontrols -c 0
        ALSA lib simple_none.c:1551:(simple_add1) helem (MIXER,'IEC958
        Playback Switch',0,1,0) appears twice or more
        amixer: Mixer hw:0 load error: Invalid argument
      
      This patch fixes the previous broken workaround.  Instead of changing
      the device number of SPDIF ctl elements, shift the element indices of
      such controls up to 16.  Also, the conflict check is performed over
      all codecs found on the bus.
      
      HDMI devices will be put to dev=0,index=0 as before.  Only the
      conflicting SPDIF device is moved to a different place.  The new place
      of SPDIF device is supposed by the updated alsa-lib HDA-Intel.conf,
      respectively.
      Reported-by: NStephan Raue <stephan@openelec.tv>
      Reported-by: NAnssi Hannula <anssi.hannula@iki.fi>
      Cc: <stable@vger.kernel.org> [v3.8]
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      ea9b43ad
  5. 08 2月, 2013 2 次提交
    • M
      ALSA: hda - Support rereading widgets under the function group · a15d05db
      Mengdong Lin 提交于
      A codec may allow software to hide some unused pin/cvt widgets.
      
      Sometimes BIOS does not enable the hidden widgets properly although they are
      needed for the board. Thus the driver need to enable them as a board-specific
      fixup and the whole tree will change.
      
      This patch implements a common code for rereading codec widgets. So the fixup
      code can call it after enabling the hidden widgets.
      Signed-off-by: NMengdong Lin <mengdong.lin@intel.com>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      a15d05db
    • T
      ALSA: hda - Remove limit of widget connections · 4eea3091
      Takashi Iwai 提交于
      Currently we set the max number of connections to be 32, but there
      seems codec that gives longer connection lists like AD1988, and we see
      errors in proc output and else.  (Though, in the case of AD1988, it's
      a list of all codecs connected to a single vendor widget, so this must
      be something fishy, but it's still valid from the h/w design POV.)
      
      This patch tries to remove this restriction.  For efficiency, we still
      use the fixed size array in the parser, but takes a dynamic array when
      the size is reported to be greater than that.
      
      Now the fixed array size is found only in patch_hdmi.c, but it should
      be fine, as the codec itself can't support so many pins.
      Reported-by: NRaymond Yau <superquad.vortex2@gmail.com>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      4eea3091
  6. 25 1月, 2013 3 次提交
  7. 23 1月, 2013 1 次提交
    • T
      ALSA: hda - Fix inconsistent pin states after resume · 31614bb8
      Takashi Iwai 提交于
      The commit [26a6cb6c: ALSA: hda - Implement a poll loop for jacks as a
      module parameter] introduced the polling jack detection code, but it
      also moved the call of snd_hda_jack_set_dirty_all() in the resume path
      after resume/init ops call.  This caused a regression when the jack
      state has been changed during power-down (e.g. in the power save
      mode).  Since the driver doesn't probe the new jack state but keeps
      using the cached value due to no dirty flag, the pin state remains
      also as if the jack is still plugged.
      
      The fix is simply moving snd_hda_jack_set_dirty_all() to the original
      position.
      Reported-by: NManolo Díaz <diaz.manolo@gmail.com>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      31614bb8
  8. 22 1月, 2013 1 次提交
  9. 15 1月, 2013 1 次提交
  10. 12 1月, 2013 15 次提交
  11. 03 1月, 2013 1 次提交
  12. 07 12月, 2012 1 次提交
  13. 01 12月, 2012 1 次提交
  14. 28 11月, 2012 1 次提交
    • T
      ALSA: hda - Call snd_array_init() early and only once · 361dab3e
      Takashi Iwai 提交于
      This is a preliminary patch for introducing a protection to access
      races of snd_array instances.  Call snd_array_init() appropriately
      at the initialization time and don't call it twice.
      
      Also the allocations of codec-spec structs are cleaned up by helper
      functions in patch_sigmatel.c and patch_analog.c.
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      361dab3e
  15. 24 11月, 2012 1 次提交
  16. 23 11月, 2012 1 次提交
    • T
      ALSA: hda - Don't overwrite the pin default configs · 3fdf1469
      Takashi Iwai 提交于
      Since we keep the pin default config values anyway internally, we
      don't have to set the values in the codec.  This patch removes the
      code writing the pincfg values.
      
      As a gratis bonus, we can remove also the code restoring the original
      pincfg values at PM resume or module free.  This will give us more
      benefit, as it can reduce the unnecessary power-up of codecs.
      
      This won't change the driver functionality.  The only difference would
      be that the codec proc file will show the original pincfg values
      instead of the actually referred values.  The actually referred values
      can be determined from sysfs *_pin_configs files.
      (Also hda-emu was updated to follow this change.)
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      3fdf1469
  17. 19 11月, 2012 1 次提交
  18. 09 11月, 2012 1 次提交
  19. 04 11月, 2012 1 次提交
  20. 17 10月, 2012 1 次提交
    • T
      ALSA: hda - Add workaround for conflicting IEC958 controls · dcda5806
      Takashi Iwai 提交于
      When both an SPDIF and an HDMI device are created on the same card
      instance, multiple IEC958 controls are created with indices=0, 1, ...
      But the alsa-lib configuration can't know which index corresponds
      actually to which PCM device, and both the SPDIF and the HDMI
      configurations point to the first IEC958 control wrongly.
      
      This patch introduces a (hackish and ugly) workaround: the IEC958
      controls for the SPDIF device are re-labeled with device=1 when HDMI
      coexists.  The device=1 corresponds to the actual PCM device for
      SPDIF, so it's anyway a better representation.  In future, HDMI
      controls should be moved with the corresponding PCM device number,
      too.
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      dcda5806
  21. 15 10月, 2012 1 次提交
  22. 10 10月, 2012 1 次提交