1. 23 9月, 2014 2 次提交
  2. 23 7月, 2014 3 次提交
  3. 17 7月, 2014 2 次提交
  4. 09 7月, 2014 1 次提交
  5. 03 7月, 2014 4 次提交
  6. 02 7月, 2014 1 次提交
  7. 28 6月, 2014 1 次提交
  8. 22 6月, 2014 10 次提交
    • L
      ASoC: dapm: Remove platform field from widget and dapm context struct · 88a8fe3d
      Lars-Peter Clausen 提交于
      The platform field in the snd_soc_dapm_widget and snd_soc_dapm_context structs
      is now unused can be removed. New code that wants to get the platform for a
      widget or dapm context should use snd_soc_dapm_to_platform(w->dapm) or
      snd_soc_dapm_to_platform(dapm).
      Signed-off-by: NLars-Peter Clausen <lars@metafoo.de>
      Signed-off-by: NMark Brown <broonie@linaro.org>
      88a8fe3d
    • L
      ASoC: dapm: Remove DAI DAPM context · 9420d97b
      Lars-Peter Clausen 提交于
      The DAI DAPM context was added in commit be09ad90 ("ASoC: core: Add platform DAI
      widget mapping") and the only user was removed again in commit ae10e7e8 ("ASoC:
      core: Only add platform DAI widgets once."). Now that we have a per component
      DAPM context it is unlikely that we'll need the DAI DAPM context again.
      Signed-off-by: NLars-Peter Clausen <lars@metafoo.de>
      Signed-off-by: NMark Brown <broonie@linaro.org>
      9420d97b
    • L
      ASoC: Add component level stream_event() and seq_notifier() support · 14e8bdeb
      Lars-Peter Clausen 提交于
      This patch adds stream_event() and seq_notifier() callbacks similar to those
      found in the snd_soc_codec_driver and snd_soc_platform driver struct to the
      snd_soc_component_driver struct. This is meant to unify the handling of these
      callbacks across different types of components and will eventually allow their
      removal from the CODEC and platfrom driver structs.
      
      The new callbacks are slightly different from the old ones in that they take a
      snd_soc_component as a parameter rather than a snd_soc_dapm_context. This was
      done since otherwise casting from the DAPM context to the component would
      typically be the first thing to do in the callback. And the interface becomes
      slightly cleaner by passing a snd_soc_component to all callbacks in the
      snd_soc_component_driver struct.
      
      The patch also already removes the stream_event() callback from the
      snd_soc_codec_driver and snd_soc_platform_driver structs as it is currently
      unused.
      Signed-off-by: NLars-Peter Clausen <lars@metafoo.de>
      Signed-off-by: NMark Brown <broonie@linaro.org>
      14e8bdeb
    • L
      ASoC: Use component DAPM context for platforms · bc9af9fa
      Lars-Peter Clausen 提交于
      The snd_soc_platform dapm field is not accessed outside of the ASoC core. Switch
      it over to using the snd_soc_component DAPM context.
      Signed-off-by: NLars-Peter Clausen <lars@metafoo.de>
      Signed-off-by: NMark Brown <broonie@linaro.org>
      bc9af9fa
    • L
      ASoC: Add DAPM support at the component level · ce0fc93a
      Lars-Peter Clausen 提交于
      This patch adds full DAPM support at the component level. Previously there was
      only full DAPM support for CODECs and partial DAPM support (e.g. no Mixers nor
      MUXs) for platforms. Having DAPM support at the component level will allow all
      types of components to use DAPM and also help in consolidating the DAPM support
      between CODECs and platforms.
      
      Since the DAPM context is directly embedded into the snd_soc_codec and
      snd_soc_platform struct and the 'dapm' field is directly referenced in a lot of
      drivers moving the field just right now is not possible without causing code
      churn. The approach this patch takes is to add two new fields to the component
      struct. One field which is the pointer to the actual DAPM context used by the
      component and one DAPM context that will be used as the default if no other
      context was specified. For CODECs and platforms the pointer is initialized to
      point to the CODEC or platform DAPM context. All generic code when referencing
      a component's DAPM struct will go via the pointer. This will make it possible to
      eventually seamlessly move the DAPM context from snd_soc_codec and
      snd_soc_platform struct over once all direct references have been eliminated.
      Signed-off-by: NLars-Peter Clausen <lars@metafoo.de>
      Signed-off-by: NMark Brown <broonie@linaro.org>
      ce0fc93a
    • L
      ASoC: Add a set_bias_level() callback to the DAPM context struct · 68f831c2
      Lars-Peter Clausen 提交于
      Currently the DAPM code directly looks at the CODEC driver struct to get a
      handle to the set_bias_level() callback. This patch adds a new set_bias_level()
      callback to the DAPM context struct. The DAPM code will use this new callback
      instead of the CODEC callback. For CODECs the new callback is set up to call the
      CODEC specific set_bias_level callback(). Not looking directly at the CODEC
      driver struct will allow non CODEC DAPM contexts to implement a set_bias_level()
      callback.
      
      This is also similar to how the seq_notifier() and stream_event() callbacks are
      currently handled.
      Signed-off-by: NLars-Peter Clausen <lars@metafoo.de>
      Signed-off-by: NMark Brown <broonie@linaro.org>
      68f831c2
    • L
      ASoC: Auto disconnect pins from all DAPM contexts · 7df37884
      Lars-Peter Clausen 提交于
      Currently only pins in CODEC DAPM contexts are automatically marked as
      non-connected if the card has the fully_routed flag set. This makes sense since
      widgets which qualify for auto-disconnection are only found in CODEC DAPM
      contexts. But with componentisation this is going to change, so consider all
      widgets for auto-disconnection.
      
      Also it is probably faster to walk the widgets list only once rather than once
      for each CODEC.
      Signed-off-by: NLars-Peter Clausen <lars@metafoo.de>
      Signed-off-by: NMark Brown <broonie@linaro.org>
      7df37884
    • L
      ASoC: Split component registration into two steps · bb13109d
      Lars-Peter Clausen 提交于
      Split snd_soc_component_register() into snd_soc_component_initialize() and
      snd_soc_component_add(). Using a 2-stage registration approach has the advantage
      that it is possible to modify the component after it has been initialized, but
      before it is made visible to the system. This e.g. allows CODECs or platforms to
      overwrite some of the default settings made in snd_soc_component_initialize().
      
      Similar snd_soc_component_unregister() is split into two steps as well,
      snd_soc_component_delete(), which removes the component from the system, and
      snd_soc_component_cleanup(), which frees all the resources allocated by the
      component.
      
      Furthermore this patch makes sure that if a component is visible on two list
      (e.g. the component list and the CODEC list) it is added or removed to both
      lists atomically.
      Signed-off-by: NLars-Peter Clausen <lars@metafoo.de>
      Signed-off-by: NMark Brown <broonie@linaro.org>
      bb13109d
    • L
      ASoC: Move name and id from CODEC/platform to component · f4333203
      Lars-Peter Clausen 提交于
      The component struct already has a name and id field which are initialized to
      the same values as the same fields in the CODEC and platform structs. So remove
      them from the CODEC and platform structs and used the ones from the component
      struct instead.
      Signed-off-by: NLars-Peter Clausen <lars@metafoo.de>
      Signed-off-by: NMark Brown <broonie@linaro.org>
      f4333203
    • L
      ASoC: Move name_prefix from CODEC to component · 94f99c87
      Lars-Peter Clausen 提交于
      Move the name_prefix from the CODEC struct to the component struct. This will
      eventually allow to specify prefixes for all types of components. It is also
      necessary to make the DAPM code component type independent (i.e. a DAPM context
      does not need to know whether it belongs to a CODEC or a platform or something
      else).
      Signed-off-by: NLars-Peter Clausen <lars@metafoo.de>
      Signed-off-by: NMark Brown <broonie@linaro.org>
      94f99c87
  9. 07 5月, 2014 3 次提交
  10. 06 5月, 2014 1 次提交
  11. 03 5月, 2014 1 次提交
  12. 02 5月, 2014 1 次提交
  13. 30 4月, 2014 1 次提交
    • J
      ASoC: core: Fix component_list corruption when unloading modules · 4da53393
      Jarkko Nikula 提交于
      This fixes module unload regressions introduced by commits 98e639fb
      ("ASoC: Track which components have been registered with
      snd_soc_register_component()") and b37f1d12 ("ASoC: Let snd_soc_platform
      subclass snd_soc_component").
      
      First commit causes component_list to be corrupted when removing codec and
      second when removing platform. Reason for both is that components associated
      with platform or codec are never removed from the list because for them
      registered_as_component field in struct snd_soc_component is always false.
      
      Now list becomes corrupted when snd_soc_unregister_platform() or
      snd_soc_unregister_codec() frees the platform or codec structure and where
      the associated struct snd_soc_component is embedded.
      
      Fix these by moving component unregistration and cleanup to a new local
      function __snd_soc_unregister_component() that takes component as its
      argument.
      
      Since component is known for platforms and codecs the
      __snd_soc_unregister_component() can be called directly and
      snd_soc_unregister_component() takes care to find and unregister only
      components that were registered using snd_soc_register_component().
      Signed-off-by: NJarkko Nikula <jarkko.nikula@linux.intel.com>
      Acked-by: NLars-Peter Clausen <lars@metafoo.de>
      Signed-off-by: NMark Brown <broonie@linaro.org>
      4da53393
  14. 27 4月, 2014 1 次提交
  15. 24 4月, 2014 1 次提交
  16. 23 4月, 2014 2 次提交
    • N
      ASoC: core: Don't break component searching if both id and num_dai are 0 · 3dcba280
      Nicolin Chen 提交于
      The commit e41975ed (ASoC: core: Fix the DAI name getting) added a break
      within the "if (id < 0 || id >= pos->num_dai)" while the original design
      of the search didn't break the loop if that condition contented but only
      mark the ret error and let it go on to search the next component.
      
      In a case like dmaengine which's not a dai but as a component sharing an
      identical name with a dai, both the id and pos->num_dai here could be 0.
      If we break the search, we may never find the dai we want as it might be
      placed behind its dmaengine in the component list.
      
      So this patch fixes the issue above by following the original design to
      let the search carry on.
      Signed-off-by: NNicolin Chen <Guangyu.Chen@freescale.com>
      Signed-off-by: NMark Brown <broonie@linaro.org>
      3dcba280
    • J
      ASoC: core: Update snd_soc_of_parse_daifmt() interface · 389cb834
      Jyri Sarha 提交于
      Adds struct device_node **bitclkmaster and struct device_node **framemaster
      function parameters. With the new syntax bitclock-master and frame-master
      properties can explicitly indicate the dai-link bit-clock and frame masters
      with a phandle. This patch also makes the minimal changes to simple-card
      for it to work with the updated snd_soc_of_parse_daifmt(). Simple-card appears
      to be the only user of snd_soc_of_parse_daifmt() for now.
      Signed-off-by: NJyri Sarha <jsarha@ti.com>
      Acked-by: NJean-Francois Moine <moinejf@free.fr>
      Signed-off-by: NMark Brown <broonie@linaro.org>
      389cb834
  17. 22 4月, 2014 2 次提交
    • L
      ASoC: Move standard kcontrol helpers to the component level · 907fe36a
      Lars-Peter Clausen 提交于
      After moving the IO layer inside ASoC to the component level we can now easily
      move the standard control helpers also to the component level. This allows to
      reuse the same standard helper control implementations for other components.
      Signed-off-by: NLars-Peter Clausen <lars@metafoo.de>
      Signed-off-by: NMark Brown <broonie@linaro.org>
      907fe36a
    • L
      ASoC: Move IO abstraction to the component level · e2c330b9
      Lars-Peter Clausen 提交于
      We currently have two very similar IO abstractions in ASoC, one for CODECs, the
      other for platforms. Moving this to the component level will allow us to unify
      those two. It will also enable us to move the standard kcontrol helpers as well
      as DAPM support to the component level.
      
      The new component level abstraction layer is primarily build around regmap.
      There is a per component pointer for the regmap instance for the underlying
      device. There are four new function snd_soc_component_read(),
      snd_soc_component_write(), snd_soc_component_update_bits() and
      snd_soc_component_update_bits_async(). They have the same signature as their
      regmap counter-part and will internally forward the call one-to-one to regmap.
      If the component it not using regmap it will fallback to using the custom IO
      callbacks. This is done to be able to support drivers that haven't been
      converted to regmap yet, but it is expected that this will eventually be removed
      in the future once all component drivers have been converted to regmap.
      Signed-off-by: NLars-Peter Clausen <lars@metafoo.de>
      Signed-off-by: NMark Brown <broonie@linaro.org>
      e2c330b9
  18. 19 4月, 2014 1 次提交
  19. 15 4月, 2014 2 次提交