1. 24 4月, 2015 5 次提交
  2. 23 4月, 2015 2 次提交
    • T
      ALSA: core: Fix possible memory leaks at error path in info.c · 886364f6
      Takashi Iwai 提交于
      Currently, snd_info_init() just returns an error without releasing the
      previously assigned resources at error path.  The assigned proc and
      info entries have to be released properly.  This patch covers it.
      
      While we are at it, refactor the code a bit, too.
      Acked-by: NJaroslav Kysela <perex@perex.cz>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      886364f6
    • T
      ALSA: core: Use seq_file for text proc file reads · 4adb7bcb
      Takashi Iwai 提交于
      seq_file is _the_ standard interface for simple text proc files.
      Though, we still need to support the binary proc files and the text
      file write, and also we need to manage the device disconnection
      gracefully.  Thus this patch just replaces the text file read code
      with seq_file while keeping the rest intact.
      
      snd_iprintf() helper function is now a macro to expand itself to
      seq_printf() to be compatible with the existing code.  The seq_file
      object is stored to the unused entry->rbuffer->buffer pointer.
      
      When the output size is expected to be large (greater than PAGE_SIZE),
      the driver should set entry->size field beforehand.  Then the given
      size will be preallocated and the multiple show calls can be avoided.
      Acked-by: NJaroslav Kysela <perex@perex.cz>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      4adb7bcb
  3. 16 4月, 2015 3 次提交
  4. 14 4月, 2015 1 次提交
  5. 13 4月, 2015 5 次提交
    • J
      ALSA: hda/realtek - Enable the ALC292 dock fixup on the Thinkpad T450 · f2aa1110
      Jo-Philipp Wich 提交于
      The Lenovo Thinkpad T450 requires the ALC292_FIXUP_TPT440_DOCK as well in
      order to get working sound output on the docking stations headphone jack.
      
      Patch tested on a Thinkpad T450 (20BVCTO1WW) using kernel 4.0-rc7 in
      conjunction with a ThinkPad Ultradock.
      Signed-off-by: NJo-Philipp Wich <jow@openwrt.org>
      Cc: <stable@vger.kernel.org>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      f2aa1110
    • T
      ALSA: hda - Fix another race in runtime PM refcounting · c3aeda62
      Takashi Iwai 提交于
      Although some races in runtime PM refcount was fixed by the commit
      [664c7155: ALSA: hda - Work around races of power up/down with
      runtime PM], there is still a race in the following case:
      
      CPU0:                   CPU1 :
      runtime suspend:
        codec->in_pm = 1
                              snd_hdac_power_up_pm():
                                pm_runtime_get_sync() skipped
      suspend finished:
        codec->in_pm = 0
                              snd_hdac_power_down_pm():
                                pm_runtime_put_*() is called!
      
      For avoiding this situation, increment in_pm flag atomically when it's
      non-zero, and decrement accordingly, to ensure that in_pm is set
      consistently for the whole concurrent operations.
      
      Also, since atomic_inc_not_zero() and atomic_dec_if_positive() are
      lengthy inline functions, move snd_hdac_power_up_pm() and _down_pm()
      to sound/hda/hdac_device.c as no inline functions.
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      c3aeda62
    • T
      ALSA: hda - Expose codec type sysfs · eacf6e0a
      Takashi Iwai 提交于
      The type field of HD-audio codec object should be exposed to
      user-space so that it can identify which driver type to bind (legacy /
      asoc).
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      eacf6e0a
    • T
      ALSA: ctl: fix to handle several elements added by one operation for userspace element · e1c78df1
      Takashi Sakamoto 提交于
      An element instance can have several elements with the same feature.
      Some userspace applications can add such an element instance by add
      operation with the number of elements. Then, the element instance
      gets a memory object to keep states of these elements.
      
      But the element instance has just one memory object for the elements.
      This causes the same result to each read/write operations to the
      different elements.
      
      This commit fixes this bug by allocating enough memory objects to the
      element instance for each of elements.
      Signed-off-by: NTakashi Sakamoto <o-takashi@sakamocchi.jp>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      e1c78df1
    • K
      ASoC: Intel: fix array_size.cocci warnings · a5e5e12b
      kbuild test robot 提交于
      sound/soc/intel/haswell/sst-haswell-ipc.c:646:28-29: WARNING: Use ARRAY_SIZE
      
       Use ARRAY_SIZE instead of dividing sizeof array with sizeof an element
      
      Semantic patch information:
       This makes an effort to find cases where ARRAY_SIZE can be used such as
       where there is a division of sizeof the array by the sizeof its first
       element or by any indexed element or the element type. It replaces the
       division of the two sizeofs by ARRAY_SIZE.
      
      Generated by: scripts/coccinelle/misc/array_size.cocci
      
      CC: Jie Yang <yang.jie@intel.com>
      Signed-off-by: NFengguang Wu <fengguang.wu@intel.com>
      Signed-off-by: NMark Brown <broonie@kernel.org>
      a5e5e12b
  6. 12 4月, 2015 12 次提交
  7. 11 4月, 2015 10 次提交
  8. 10 4月, 2015 2 次提交