1. 29 6月, 2022 1 次提交
  2. 06 6月, 2022 1 次提交
    • C
      ASoC: codecs: Add HD-Audio codec driver · b5df2a7d
      Cezary Rojewski 提交于
      Add generic ASoC equivalent of ALSA HD-Audio codec. This codec is
      designed to follow HDA_DEV_LEGACY convention. Driver wrapps existing
      hda_codec.c handlers to prevent code duplication within the newly added
      code. Number of DAIs created is dependent on capabilities exposed by the
      codec itself. Because of this, single solution can be applied to support
      every single HD-Audio codec type.
      
      At the same time, through the ASoC topology, platform drivers may limit
      the number of endpoints available to the userspace as codec driver
      exposes BE DAIs only.
      
      Both hda_codec_probe() and hda_codec_remove() declare their expectations
      on device's usage_count and suspended-status. This is to catch any
      unexpected behavior as PM-related code for HD-Audio has been changing
      quite a bit throughout the years.
      
      In order for codec DAI list to reflect its actual PCM capabilities, PCMs
      need to be built and that can only happen once codec device is
      constructed. To do that, a valid component->card->snd_card pointer is
      needed. Said pointer will be provided by the framework once all card
      components are accounted for and their probing can begin. Usage of
      "binder" BE DAI solves the problem - codec can be listed as one of
      HD-Audio card components without declaring any actual BE DAIs
      statically.
      
      Relation with hdac_hda:
      
      Addition of parallel solution is motivated by behavioral differences
      between hdac_hda.c and its legacy equivalent found in sound/pci/hda
      e.g.: lack of dynamic, based on codec capabilities, resource allocation
      and high cost of removing such differences on actively used targets.
      Major goal of codec driver presented here is to follow HD-Audio legacy
      behavior in 1:1 fashion by becoming a wrapper. Doing so increases code
      coverage of the legacy code and reduces the maintenance cost for both
      solutions.
      Signed-off-by: NCezary Rojewski <cezary.rojewski@intel.com>
      Link: https://lore.kernel.org/r/20220511162403.3987658-3-cezary.rojewski@intel.comSigned-off-by: NMark Brown <broonie@kernel.org>
      b5df2a7d
  3. 19 5月, 2022 2 次提交
  4. 10 5月, 2022 1 次提交
  5. 26 4月, 2022 1 次提交
  6. 07 4月, 2022 1 次提交
  7. 06 4月, 2022 1 次提交
  8. 04 4月, 2022 1 次提交
  9. 07 3月, 2022 1 次提交
  10. 28 2月, 2022 1 次提交
  11. 08 2月, 2022 6 次提交
  12. 03 2月, 2022 1 次提交
  13. 24 1月, 2022 1 次提交
  14. 31 12月, 2021 1 次提交
  15. 22 12月, 2021 1 次提交
  16. 20 12月, 2021 1 次提交
  17. 02 12月, 2021 1 次提交
  18. 26 11月, 2021 1 次提交
  19. 25 11月, 2021 1 次提交
  20. 16 11月, 2021 1 次提交
  21. 27 10月, 2021 1 次提交
  22. 13 10月, 2021 2 次提交
  23. 08 10月, 2021 1 次提交
  24. 07 10月, 2021 1 次提交
  25. 02 10月, 2021 1 次提交
  26. 27 9月, 2021 1 次提交
  27. 13 9月, 2021 2 次提交
  28. 23 8月, 2021 1 次提交
  29. 06 8月, 2021 1 次提交
  30. 22 7月, 2021 1 次提交
    • A
      ASoC: codecs: wcd938x: fix wcd module dependency · b9a4b57f
      Arnd Bergmann 提交于
      With SND_SOC_ALL_CODECS=y and SND_SOC_WCD938X_SDW=m, there is a link
      error from a reverse dependency, since the built-in codec driver calls
      into the modular soundwire back-end:
      
      x86_64-linux-ld: sound/soc/codecs/wcd938x.o: in function `wcd938x_codec_free':
      wcd938x.c:(.text+0x2c0): undefined reference to `wcd938x_sdw_free'
      x86_64-linux-ld: sound/soc/codecs/wcd938x.o: in function `wcd938x_codec_hw_params':
      wcd938x.c:(.text+0x2f6): undefined reference to `wcd938x_sdw_hw_params'
      x86_64-linux-ld: sound/soc/codecs/wcd938x.o: in function `wcd938x_codec_set_sdw_stream':
      wcd938x.c:(.text+0x332): undefined reference to `wcd938x_sdw_set_sdw_stream'
      x86_64-linux-ld: sound/soc/codecs/wcd938x.o: in function `wcd938x_tx_swr_ctrl':
      wcd938x.c:(.text+0x23de): undefined reference to `wcd938x_swr_get_current_bank'
      x86_64-linux-ld: sound/soc/codecs/wcd938x.o: in function `wcd938x_bind':
      wcd938x.c:(.text+0x2579): undefined reference to `wcd938x_sdw_device_get'
      x86_64-linux-ld: wcd938x.c:(.text+0x25a1): undefined reference to `wcd938x_sdw_device_get'
      x86_64-linux-ld: wcd938x.c:(.text+0x262a): undefined reference to `__devm_regmap_init_sdw'
      
      Work around this using two small hacks: An added Kconfig dependency
      prevents the main driver from being built-in when soundwire support
      itself is a loadable module to allow calling devm_regmap_init_sdw(),
      and a Makefile trick links the wcd938x-sdw backend as built-in
      if needed to solve the dependency between the two modules.
      
      Fixes: 04544222 ("ASoC: codecs: wcd938x: add audio routing and Kconfig")
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Link: https://lore.kernel.org/r/20210721150510.1837221-1-arnd@kernel.orgSigned-off-by: NMark Brown <broonie@kernel.org>
      b9a4b57f
  31. 15 7月, 2021 1 次提交
    • P
      ASoC: codecs: add SoundWire mockup device support · 81d3d3d0
      Pierre-Louis Bossart 提交于
      To test the host controller and bus management code, it is currently
      required to have a physical SoundWire peripheral attached to the
      bus. To help with pre-silicon or early hardware enablement, it would
      be very useful to have a SoundWire 'mockup' device that is exposed in
      platform firmware but does not drive any signal on the bus.
      
      This is different to the existing ASoC 'dummy' codec uses for I2S/TDM,
      the SoundWire spec makes it clear that a device that is not attached
      to the bus is not permitted to interact with the bus, be it for
      command/control or data.
      
      This patch exposes a 'mockup' device, with a minimalist driver, with 4
      partID values reserved by Intel for such test configurations. The
      mockup device exposes one full-duplex DAI based on 2 ports (DP1 for
      playback and DP8 for capture). The capture data port is just virtual,
      such a mockup device is prevented by the SoundWire specification from
      presenting any data generated by a Source port without being Attached.
      
      All the callbacks exposed by the SoundWire Slave interface are
      populated, even if they just return immediately. This is intentional
      to describe what a minimal codec driver should do and implement and
      help new codec vendors provide support for their devices.
      Signed-off-by: NPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
      Reviewed-by: NRander Wang <rander.wang@intel.com>
      Signed-off-by: NBard Liao <yung-chuan.liao@linux.intel.com>
      Link: https://lore.kernel.org/r/20210714032209.11284-2-yung-chuan.liao@linux.intel.comSigned-off-by: NMark Brown <broonie@kernel.org>
      81d3d3d0
  32. 14 7月, 2021 1 次提交