da7213.h 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. /*
  2. * da7213.h - DA7213 ASoC Codec Driver Platform Data
  3. *
  4. * Copyright (c) 2013 Dialog Semiconductor
  5. *
  6. * Author: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>
  7. *
  8. * This program is free software; you can redistribute it and/or modify
  9. * it under the terms of the GNU General Public License version 2 as
  10. * published by the Free Software Foundation.
  11. */
  12. #ifndef _DA7213_PDATA_H
  13. #define _DA7213_PDATA_H
  14. enum da7213_micbias_voltage {
  15. DA7213_MICBIAS_1_6V = 0,
  16. DA7213_MICBIAS_2_2V = 1,
  17. DA7213_MICBIAS_2_5V = 2,
  18. DA7213_MICBIAS_3_0V = 3,
  19. };
  20. enum da7213_dmic_data_sel {
  21. DA7213_DMIC_DATA_LRISE_RFALL = 0,
  22. DA7213_DMIC_DATA_LFALL_RRISE = 1,
  23. };
  24. enum da7213_dmic_samplephase {
  25. DA7213_DMIC_SAMPLE_ON_CLKEDGE = 0,
  26. DA7213_DMIC_SAMPLE_BETWEEN_CLKEDGE = 1,
  27. };
  28. enum da7213_dmic_clk_rate {
  29. DA7213_DMIC_CLK_3_0MHZ = 0,
  30. DA7213_DMIC_CLK_1_5MHZ = 1,
  31. };
  32. struct da7213_platform_data {
  33. /* Mic Bias voltage */
  34. enum da7213_micbias_voltage micbias1_lvl;
  35. enum da7213_micbias_voltage micbias2_lvl;
  36. /* DMIC config */
  37. enum da7213_dmic_data_sel dmic_data_sel;
  38. enum da7213_dmic_samplephase dmic_samplephase;
  39. enum da7213_dmic_clk_rate dmic_clk_rate;
  40. };
  41. #endif /* _DA7213_PDATA_H */