es325-export.h 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. /*
  2. * es325-export.h --
  3. *
  4. * This program is free software; you can redistribute it and/or modify
  5. * it under the terms of the GNU General Public License version 2 as
  6. * published by the Free Software Foundation.
  7. */
  8. #ifndef _ES325_EXPORT_H
  9. #define _ES325_EXPORT_H
  10. #include <sound/soc.h>
  11. int es325_slim_set_channel_map(struct snd_soc_dai *dai,
  12. unsigned int tx_num, unsigned int *tx_slot,
  13. unsigned int rx_num, unsigned int *rx_slot);
  14. int es325_slim_get_channel_map(struct snd_soc_dai *dai,
  15. unsigned int *tx_num, unsigned int *tx_slot,
  16. unsigned int *rx_num, unsigned int *rx_slot);
  17. int es325_slim_trigger(struct snd_pcm_substream *substream,
  18. int cmd, struct snd_soc_dai *dai);
  19. int es325_slim_hw_params(struct snd_pcm_substream *substream,
  20. struct snd_pcm_hw_params *params,
  21. struct snd_soc_dai *dai);
  22. int es325_remote_cfg_slim_rx(int dai_id);
  23. int es325_remote_cfg_slim_tx(int dai_id);
  24. int es325_remote_close_slim_rx(int dai_id);
  25. int es325_remote_close_slim_tx(int dai_id);
  26. int es325_remote_add_codec_controls(struct snd_soc_codec *codec);
  27. int es325_remote_route_enable(struct snd_soc_dai *dai);
  28. void es325_wrapper_sleep(int dai_id);
  29. void es325_wrapper_wakeup(struct snd_soc_dai *dai);
  30. #define ES325_DAI_ID_OFFSET 10
  31. /* remote dai-id -> local dai->id */
  32. /* ES325_AIF1_PB -> ES325_SLIM_1_PB */
  33. /* ES325_AIF1_CAP -> ES325_SLIM_1_CAP */
  34. #define ES325_AIF1_PB (ES325_DAI_ID_OFFSET + 1)
  35. #define ES325_AIF1_CAP (ES325_DAI_ID_OFFSET + 2)
  36. #endif /* _ES325_EXPORT_H */