csl_cpIntc.h 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125
  1. /**
  2. * @file csl_cpIntc.h
  3. *
  4. * @brief
  5. * This is the main header file for the CPINTC Module which defines
  6. * all the data structures and exported API.
  7. *
  8. * \par
  9. * ============================================================================
  10. * @n (C) Copyright 2008, 2009, Texas Instruments, Inc.
  11. *
  12. * Redistribution and use in source and binary forms, with or without
  13. * modification, are permitted provided that the following conditions
  14. * are met:
  15. *
  16. * Redistributions of source code must retain the above copyright
  17. * notice, this list of conditions and the following disclaimer.
  18. *
  19. * Redistributions in binary form must reproduce the above copyright
  20. * notice, this list of conditions and the following disclaimer in the
  21. * documentation and/or other materials provided with the
  22. * distribution.
  23. *
  24. * Neither the name of Texas Instruments Incorporated nor the names of
  25. * its contributors may be used to endorse or promote products derived
  26. * from this software without specific prior written permission.
  27. *
  28. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  29. * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  30. * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
  31. * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
  32. * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  33. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  34. * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
  35. * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
  36. * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  37. * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
  38. * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  39. *
  40. */
  41. /** @defgroup CSL_CPINTC_API CPINTC
  42. *
  43. * @section Introduction
  44. *
  45. * @subsection xxx Overview
  46. * The CPINTC is the interrupt controller which handles the system interrupts
  47. * for the host, processes & prioritizes them and then is responsible for
  48. * delivering these to the host.
  49. *
  50. * @subsection References
  51. * -# CPINTC Architecture Specification.
  52. *
  53. * @subsection Assumptions
  54. * The abbreviations CPINTC, cpintc have been used throughout this
  55. * document to refer to Interrupt Controller.
  56. */
  57. #ifndef CSL_CPINTC_H
  58. #define CSL_CPINTC_H
  59. #ifdef __cplusplus
  60. extern "C" {
  61. #endif
  62. #include <ti/csl/soc.h>
  63. #include <ti/csl/csl.h>
  64. #include <ti/csl/cslr_cpintc.h>
  65. /**
  66. @defgroup CSL_CPINTC_SYMBOL CPINTC Symbols Defined
  67. @ingroup CSL_CPINTC_API
  68. */
  69. /**
  70. @defgroup CSL_CPINTC_DATASTRUCT CPINTC Data Structures
  71. @ingroup CSL_CPINTC_API
  72. */
  73. /**
  74. @defgroup CSL_CPINTC_FUNCTION CPINTC Functions
  75. @ingroup CSL_CPINTC_API
  76. */
  77. /** @addtogroup CSL_CPINTC_DATASTRUCT
  78. @{ */
  79. /** @brief Register Overlay Memory map for the CPINTC0 Registers. */
  80. typedef volatile CSL_CPINTCRegs* CSL_CPINTC_RegsOvly;
  81. /** @brief This is the handle to the CPINTC instance */
  82. typedef Uint32 CSL_CPINTC_Handle;
  83. /** @brief This defines the system interrupt */
  84. typedef Uint32 CSL_CPINTCSystemInterrupt;
  85. /** @brief This defines the host interrupt */
  86. typedef Uint32 CSL_CPINTCHostInterrupt;
  87. /** @brief This defines the channels */
  88. typedef Uint32 CSL_CPINTCChannel;
  89. /** @brief This defines the nesting level */
  90. typedef Uint16 CSL_CPINTCNestingLevel;
  91. /** @brief Enumeration defines the type of Nesting Modes which is supported by the CPINTC */
  92. typedef enum CSL_CPINTCNestingMode_e
  93. {
  94. CPINTC_NO_NESTING = 0x0,
  95. CPINTC_AUTOMATIC_GLB_NESTING = 0x1,
  96. CPINTC_AUTOMATIC_IND_NESTING = 0x2,
  97. CPINTC_MANUAL_NESTING = 0x3
  98. }CSL_CPINTCNestingMode;
  99. /**
  100. @}
  101. */
  102. /* Device specific API which opens the CPINTC instance and returns a handle used in all subsequent calls */
  103. extern CSL_CPINTC_Handle CSL_CPINTC_open (Int32 instNum);
  104. #ifdef __cplusplus
  105. }
  106. #endif
  107. #endif /* CSL_CPINTC_H */