ti-sysc.h 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. #ifndef __TI_SYSC_DATA_H__
  2. #define __TI_SYSC_DATA_H__
  3. enum ti_sysc_module_type {
  4. TI_SYSC_OMAP2,
  5. TI_SYSC_OMAP2_TIMER,
  6. TI_SYSC_OMAP3_SHAM,
  7. TI_SYSC_OMAP3_AES,
  8. TI_SYSC_OMAP4,
  9. TI_SYSC_OMAP4_TIMER,
  10. TI_SYSC_OMAP4_SIMPLE,
  11. TI_SYSC_OMAP34XX_SR,
  12. TI_SYSC_OMAP36XX_SR,
  13. TI_SYSC_OMAP4_SR,
  14. TI_SYSC_OMAP4_MCASP,
  15. TI_SYSC_OMAP4_USB_HOST_FS,
  16. };
  17. /**
  18. * struct sysc_regbits - TI OCP_SYSCONFIG register field offsets
  19. * @midle_shift: Offset of the midle bit
  20. * @clkact_shift: Offset of the clockactivity bit
  21. * @sidle_shift: Offset of the sidle bit
  22. * @enwkup_shift: Offset of the enawakeup bit
  23. * @srst_shift: Offset of the softreset bit
  24. * @autoidle_shift: Offset of the autoidle bit
  25. * @dmadisable_shift: Offset of the dmadisable bit
  26. * @emufree_shift; Offset of the emufree bit
  27. *
  28. * Note that 0 is a valid shift, and for ti-sysc.c -ENODEV can be used if a
  29. * feature is not available.
  30. */
  31. struct sysc_regbits {
  32. s8 midle_shift;
  33. s8 clkact_shift;
  34. s8 sidle_shift;
  35. s8 enwkup_shift;
  36. s8 srst_shift;
  37. s8 autoidle_shift;
  38. s8 dmadisable_shift;
  39. s8 emufree_shift;
  40. };
  41. #define SYSC_QUIRK_16BIT BIT(2)
  42. #define SYSC_QUIRK_UNCACHED BIT(1)
  43. #define SYSC_QUIRK_USE_CLOCKACT BIT(0)
  44. /**
  45. * struct sysc_capabilities - capabilities for an interconnect target module
  46. *
  47. * @sysc_mask: bitmask of supported SYSCONFIG register bits
  48. * @regbits: bitmask of SYSCONFIG register bits
  49. * @mod_quirks: bitmask of module specific quirks
  50. */
  51. struct sysc_capabilities {
  52. const enum ti_sysc_module_type type;
  53. const u32 sysc_mask;
  54. const struct sysc_regbits *regbits;
  55. const u32 mod_quirks;
  56. };
  57. /**
  58. * struct sysc_config - configuration for an interconnect target module
  59. * @quirks: bitmask of enabled quirks
  60. */
  61. struct sysc_config {
  62. u32 quirks;
  63. };
  64. #endif /* __TI_SYSC_DATA_H__ */