omap-twl4030.h 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. /**
  2. * omap-twl4030.h - ASoC machine driver for TI SoC based boards with twl4030
  3. * codec, header.
  4. *
  5. * Copyright (C) 2012 Texas Instruments Incorporated - http://www.ti.com
  6. * All rights reserved.
  7. *
  8. * Author: Peter Ujfalusi <peter.ujfalusi@ti.com>
  9. *
  10. * This program is free software; you can redistribute it and/or
  11. * modify it under the terms of the GNU General Public License
  12. * version 2 as published by the Free Software Foundation.
  13. *
  14. * This program is distributed in the hope that it will be useful, but
  15. * WITHOUT ANY WARRANTY; without even the implied warranty of
  16. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  17. * General Public License for more details.
  18. *
  19. * You should have received a copy of the GNU General Public License
  20. * along with this program; if not, write to the Free Software
  21. * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
  22. * 02110-1301 USA
  23. */
  24. #ifndef _OMAP_TWL4030_H_
  25. #define _OMAP_TWL4030_H_
  26. /* To select if only one channel is connected in a stereo port */
  27. #define OMAP_TWL4030_LEFT (1 << 0)
  28. #define OMAP_TWL4030_RIGHT (1 << 1)
  29. struct omap_tw4030_pdata {
  30. const char *card_name;
  31. /* Voice port is connected to McBSP3 */
  32. bool voice_connected;
  33. /* The driver will parse the connection flags if this flag is set */
  34. bool custom_routing;
  35. /* Flags to indicate connected audio ports. */
  36. u8 has_hs;
  37. u8 has_hf;
  38. u8 has_predriv;
  39. u8 has_carkit;
  40. bool has_ear;
  41. bool has_mainmic;
  42. bool has_submic;
  43. bool has_hsmic;
  44. bool has_carkitmic;
  45. bool has_digimic0;
  46. bool has_digimic1;
  47. u8 has_linein;
  48. /* Jack detect GPIO or <= 0 if it is not implemented */
  49. int jack_detect;
  50. };
  51. #endif /* _OMAP_TWL4030_H_ */