1. 29 7月, 2015 1 次提交
  2. 22 7月, 2015 2 次提交
    • L
      ASoC: dapm: Avoid duplicating immutable strings · 48068961
      Lars-Peter Clausen 提交于
      When creating a new widget from a template the name string of the template
      is duplicated for the newly created widget. This is necessary because in
      some cases the string might be stored on the stack or other volatile
      memory locations.
      
      But most of the time the string is static const data, which means it is
      possible to use it directly without having to worry that it might get freed
      or changed.
      
      Use kstrdup_const() to handle duplicating the string. This function is
      capable of detecting whether a string is immutable and if it is returns the
      input without duplicating it. This will slightly reduce the runtime memory
      footprint of DAPM and also speed up initialization.
      Signed-off-by: NLars-Peter Clausen <lars@metafoo.de>
      Signed-off-by: NMark Brown <broonie@kernel.org>
      48068961
    • L
      ASoC: dapm: Add helper function to free a widget · b97e2698
      Lars-Peter Clausen 提交于
      snd_soc_tplg_widget_remove_all() has a verbatim copy of an older version of
      the widget freeing code from dapm_free_widgets(). Add a new helper function
      that takes care of freeing a widget and use it in both places.
      
      This removes the duplicated code and also makes sure that future changes to
      the widget freeing code only have to be made in one location.
      Signed-off-by: NLars-Peter Clausen <lars@metafoo.de>
      Signed-off-by: NMark Brown <broonie@kernel.org>
      b97e2698
  3. 21 7月, 2015 1 次提交
    • L
      ASoC: dapm: Don't add prefix to widget stream name · a798c24a
      Lars-Peter Clausen 提交于
      Commit fdb6eb0a ("ASoC: dapm: Modify widget stream name according to
      prefix") fixed the case where a DAPM route between a DAI widget and a
      DAC/ADC/AIF widget with a matching stream name was not created when the
      DAPM context was using a prefix.
      
      Unfortunately the patch introduced a few issues on its own like leaking the
      dynamically allocated stream name memory and also not checking whether the
      allocation succeeded in the first place.
      
      It is also incomplete in that it still does not handle the case where
      stream name of the widget is a substring of the stream name of the DAI,
      which is explicitly allowed and works fine if no DAPM prefix is used.
      
      Revert the commit and take a slightly different approach to solving the
      issue. Instead of comparing the widget's stream name to the name of the DAI
      widget compare it to the stream name of the DAI widget. The stream name of
      the DAI widget is identical to the name of the DAI widget except that it
      wont have the DAPM prefix added. So this approach behaves identical
      regardless to whether the DAPM context uses a prefix or not.
      
      We don't have to worry about potentially matching with a widget with the
      same stream name, but from a different DAPM context with a different
      prefix, since the code already makes sure that both the DAI widget and the
      matched widget are from the same DAPM context.
      
      Fixes: fdb6eb0a ("ASoC: dapm: Modify widget stream name according to prefix")
      Signed-off-by: NLars-Peter Clausen <lars@metafoo.de>
      Signed-off-by: NMark Brown <broonie@kernel.org>
      Cc: stable@vger.kernel.org
      a798c24a
  4. 09 7月, 2015 2 次提交
  5. 07 7月, 2015 1 次提交
  6. 01 7月, 2015 1 次提交
    • V
      genalloc: rename of_get_named_gen_pool() to of_gen_pool_get() · abdd4a70
      Vladimir Zapolskiy 提交于
      To be consistent with other kernel interface namings, rename
      of_get_named_gen_pool() to of_gen_pool_get().  In the original function
      name "_named" suffix references to a device tree property, which contains
      a phandle to a device and the corresponding device driver is assumed to
      register a gen_pool object.
      
      Due to a weak relation and to avoid any confusion (e.g.  in future
      possible scenario if gen_pool objects are named) the suffix is removed.
      
      [sfr@canb.auug.org.au: crypto/marvell/cesa - fix up for of_get_named_gen_pool() rename]
      Signed-off-by: NVladimir Zapolskiy <vladimir_zapolskiy@mentor.com>
      Cc: Nicolas Ferre <nicolas.ferre@atmel.com>
      Cc: Philipp Zabel <p.zabel@pengutronix.de>
      Cc: Shawn Guo <shawn.guo@linaro.org>
      Cc: Sascha Hauer <kernel@pengutronix.de>
      Cc: Alexandre Belloni <alexandre.belloni@free-electrons.com>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
      Cc: Vinod Koul <vinod.koul@intel.com>
      Cc: Takashi Iwai <tiwai@suse.de>
      Cc: Jaroslav Kysela <perex@perex.cz>
      Signed-off-by: NStephen Rothwell <sfr@canb.auug.org.au>
      Cc: Herbert Xu <herbert@gondor.apana.org.au>
      Cc: Boris BREZILLON <boris.brezillon@free-electrons.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      abdd4a70
  7. 30 6月, 2015 1 次提交
    • C
      ALSA: Fix uninintialized error return · 0755e74b
      Colin Ian King 提交于
      Static analysis with cppcheck found the following error:
        [sound/core/init.c:118]: (error) Uninitialized variable: err
      
      ..this was introduced by commit 2471b6c8
      ("ALSA: info: Register proc entries recursively, too") where the call
      to snd_info_card_register was removed and no longer setting the error
      return in err.  When snd_info_create_card_entry fails to allocate a
      an entry, the error path exits with garbage in err.  Fix is to return
      -ENOMEM if entry fails to be allocated.
      
      Fixes: 2471b6c8 ("ALSA: info: Register proc entries recursively, too")
      Signed-off-by: NColin Ian King <colin.king@canonical.com>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      0755e74b
  8. 29 6月, 2015 3 次提交
  9. 27 6月, 2015 1 次提交
  10. 26 6月, 2015 3 次提交
  11. 25 6月, 2015 3 次提交
  12. 23 6月, 2015 1 次提交
    • T
      ALSA: pcm: Fix pcm_class sysfs output · 60b93030
      Takashi Iwai 提交于
      The pcm_class sysfs of each PCM substream gives only "none" since the
      recent code change to embed the struct device.  Fix the code to point
      directly to the embedded device object properly.
      
      Fixes: ef46c7af ('ALSA: pcm: Embed struct device')
      Cc: <stable@vger.kernel.org> # v4.0+
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      60b93030
  13. 20 6月, 2015 1 次提交
  14. 19 6月, 2015 1 次提交
    • R
      ASoC: wm_adsp: Move DSP Rate controls into the codec · 336d0442
      Richard Fitzgerald 提交于
      The rate controls are codec-specific, it's not possible to
      generically say what the range or the meaning of each control
      is (or even if they exist at all) - that depends on the
      particular codec.
      
      This is currently being handled for Arizona codecs by putting
      an Arizona-specific table of controls inside the wm_adsp driver.
      This creates a dependency between wm_adsp and arizona.c, and is an
      awkward solution if the ADSP is used in another family of codecs
      
      Fix this by moving the Arizona-specific rate controls into the
      Arizona codec drivers.
      Signed-off-by: NRichard Fitzgerald <rf@opensource.wolfsonmicro.com>
      Signed-off-by: NMark Brown <broonie@kernel.org>
      336d0442
  15. 18 6月, 2015 1 次提交
  16. 17 6月, 2015 4 次提交
  17. 16 6月, 2015 13 次提交