fsl_dma.h 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476
  1. /*
  2. * Copyright (c) 2016, Freescale Semiconductor, Inc.
  3. * Copyright 2016-2017 NXP
  4. *
  5. * Redistribution and use in source and binary forms, with or without modification,
  6. * are permitted provided that the following conditions are met:
  7. *
  8. * o Redistributions of source code must retain the above copyright notice, this list
  9. * of conditions and the following disclaimer.
  10. *
  11. * o Redistributions in binary form must reproduce the above copyright notice, this
  12. * list of conditions and the following disclaimer in the documentation and/or
  13. * other materials provided with the distribution.
  14. *
  15. * o Neither the name of the copyright holder nor the names of its
  16. * contributors may be used to endorse or promote products derived from this
  17. * software without specific prior written permission.
  18. *
  19. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
  20. * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
  21. * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  22. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
  23. * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
  24. * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  25. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  26. * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  27. * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
  28. * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  29. */
  30. #ifndef _FSL_DMA_H_
  31. #define _FSL_DMA_H_
  32. #include "fsl_common.h"
  33. /*!
  34. * @addtogroup dma
  35. * @{
  36. */
  37. /*! @file */
  38. /*******************************************************************************
  39. * Definitions
  40. ******************************************************************************/
  41. /*! @name Driver version */
  42. /*@{*/
  43. /*! @brief DMA driver version */
  44. #define FSL_DMA_DRIVER_VERSION (MAKE_VERSION(2, 0, 0)) /*!< Version 2.0.0. */
  45. /*@}*/
  46. #define DMA_MAX_TRANSFER_COUNT 0x400
  47. /* Channel group consists of 32 channels. channel_group = (channel / 32) */
  48. #define DMA_CHANNEL_GROUP(channel) (((uint8_t)channel) >> 5U)
  49. /* Channel index in channel group. channel_index = (channel % 32) */
  50. #define DMA_CHANNEL_INDEX(channel) (((uint8_t)channel) & 0x1F)
  51. /*! @brief DMA descriptor structure */
  52. typedef struct _dma_descriptor {
  53. uint32_t xfercfg; /*!< Transfer configuration */
  54. void *srcEndAddr; /*!< Last source address of DMA transfer */
  55. void *dstEndAddr; /*!< Last destination address of DMA transfer */
  56. void *linkToNextDesc; /*!< Address of next DMA descriptor in chain */
  57. } dma_descriptor_t;
  58. /*! @brief DMA transfer configuration */
  59. typedef struct _dma_xfercfg {
  60. bool valid; /*!< Descriptor is ready to transfer */
  61. bool reload; /*!< Reload channel configuration register after
  62. current descriptor is exhausted */
  63. bool swtrig; /*!< Perform software trigger. Transfer if fired
  64. when 'valid' is set */
  65. bool clrtrig; /*!< Clear trigger */
  66. bool intA; /*!< Raises IRQ when transfer is done and set IRQA status register flag */
  67. bool intB; /*!< Raises IRQ when transfer is done and set IRQB status register flag */
  68. uint8_t byteWidth; /*!< Byte width of data to transfer */
  69. uint8_t srcInc; /*!< Increment source address by 'srcInc' x 'byteWidth' */
  70. uint8_t dstInc; /*!< Increment destination address by 'dstInc' x 'byteWidth' */
  71. uint16_t transferCount; /*!< Number of transfers */
  72. } dma_xfercfg_t;
  73. /*! @brief DMA channel priority */
  74. typedef enum _dma_priority {
  75. kDMA_ChannelPriority0 = 0, /*!< Highest channel priority - priority 0 */
  76. kDMA_ChannelPriority1, /*!< Channel priority 1 */
  77. kDMA_ChannelPriority2, /*!< Channel priority 2 */
  78. kDMA_ChannelPriority3, /*!< Channel priority 3 */
  79. kDMA_ChannelPriority4, /*!< Channel priority 4 */
  80. kDMA_ChannelPriority5, /*!< Channel priority 5 */
  81. kDMA_ChannelPriority6, /*!< Channel priority 6 */
  82. kDMA_ChannelPriority7, /*!< Lowest channel priority - priority 7 */
  83. } dma_priority_t;
  84. /*! @brief DMA interrupt flags */
  85. typedef enum _dma_int {
  86. kDMA_IntA, /*!< DMA interrupt flag A */
  87. kDMA_IntB, /*!< DMA interrupt flag B */
  88. } dma_irq_t;
  89. /*! @brief DMA trigger type*/
  90. typedef enum _dma_trigger_type {
  91. kDMA_NoTrigger = 0, /*!< Trigger is disabled */
  92. kDMA_LowLevelTrigger = DMA_CHANNEL_CFG_HWTRIGEN(1) | DMA_CHANNEL_CFG_TRIGTYPE(1), /*!< Low level active trigger */
  93. kDMA_HighLevelTrigger = DMA_CHANNEL_CFG_HWTRIGEN(1) | DMA_CHANNEL_CFG_TRIGTYPE(1) | DMA_CHANNEL_CFG_TRIGPOL(1), /*!< High level active trigger */
  94. kDMA_FallingEdgeTrigger = DMA_CHANNEL_CFG_HWTRIGEN(1), /*!< Falling edge active trigger */
  95. kDMA_RisingEdgeTrigger = DMA_CHANNEL_CFG_HWTRIGEN(1) | DMA_CHANNEL_CFG_TRIGPOL(1), /*!< Rising edge active trigger */
  96. } dma_trigger_type_t;
  97. /*! @brief DMA trigger burst */
  98. typedef enum _dma_trigger_burst {
  99. kDMA_SingleTransfer = 0, /*!< Single transfer */
  100. kDMA_LevelBurstTransfer = DMA_CHANNEL_CFG_TRIGBURST(1), /*!< Burst transfer driven by level trigger */
  101. kDMA_EdgeBurstTransfer1 = DMA_CHANNEL_CFG_TRIGBURST(1), /*!< Perform 1 transfer by edge trigger */
  102. kDMA_EdgeBurstTransfer2 = DMA_CHANNEL_CFG_TRIGBURST(1) | DMA_CHANNEL_CFG_BURSTPOWER(1), /*!< Perform 2 transfers by edge trigger */
  103. kDMA_EdgeBurstTransfer4 = DMA_CHANNEL_CFG_TRIGBURST(1) | DMA_CHANNEL_CFG_BURSTPOWER(2), /*!< Perform 4 transfers by edge trigger */
  104. kDMA_EdgeBurstTransfer8 = DMA_CHANNEL_CFG_TRIGBURST(1) | DMA_CHANNEL_CFG_BURSTPOWER(3), /*!< Perform 8 transfers by edge trigger */
  105. kDMA_EdgeBurstTransfer16 = DMA_CHANNEL_CFG_TRIGBURST(1) | DMA_CHANNEL_CFG_BURSTPOWER(4), /*!< Perform 16 transfers by edge trigger */
  106. kDMA_EdgeBurstTransfer32 = DMA_CHANNEL_CFG_TRIGBURST(1) | DMA_CHANNEL_CFG_BURSTPOWER(5), /*!< Perform 32 transfers by edge trigger */
  107. kDMA_EdgeBurstTransfer64 = DMA_CHANNEL_CFG_TRIGBURST(1) | DMA_CHANNEL_CFG_BURSTPOWER(6), /*!< Perform 64 transfers by edge trigger */
  108. kDMA_EdgeBurstTransfer128 = DMA_CHANNEL_CFG_TRIGBURST(1) | DMA_CHANNEL_CFG_BURSTPOWER(7), /*!< Perform 128 transfers by edge trigger */
  109. kDMA_EdgeBurstTransfer256 = DMA_CHANNEL_CFG_TRIGBURST(1) | DMA_CHANNEL_CFG_BURSTPOWER(8), /*!< Perform 256 transfers by edge trigger */
  110. kDMA_EdgeBurstTransfer512 = DMA_CHANNEL_CFG_TRIGBURST(1) | DMA_CHANNEL_CFG_BURSTPOWER(9), /*!< Perform 512 transfers by edge trigger */
  111. kDMA_EdgeBurstTransfer1024 = DMA_CHANNEL_CFG_TRIGBURST(1) | DMA_CHANNEL_CFG_BURSTPOWER(10), /*!< Perform 1024 transfers by edge trigger */
  112. } dma_trigger_burst_t;
  113. /*! @brief DMA burst wrapping */
  114. typedef enum _dma_burst_wrap {
  115. kDMA_NoWrap = 0, /*!< Wrapping is disabled */
  116. kDMA_SrcWrap = DMA_CHANNEL_CFG_SRCBURSTWRAP(1), /*!< Wrapping is enabled for source */
  117. kDMA_DstWrap = DMA_CHANNEL_CFG_DSTBURSTWRAP(1), /*!< Wrapping is enabled for destination */
  118. kDMA_SrcAndDstWrap = DMA_CHANNEL_CFG_SRCBURSTWRAP(1) | DMA_CHANNEL_CFG_DSTBURSTWRAP(1), /*!< Wrapping is enabled for source and destination */
  119. } dma_burst_wrap_t;
  120. /*! @brief DMA transfer type */
  121. typedef enum _dma_transfer_type
  122. {
  123. kDMA_MemoryToMemory = 0x0U, /*!< Transfer from memory to memory (increment source and destination) */
  124. kDMA_PeripheralToMemory, /*!< Transfer from peripheral to memory (increment only destination) */
  125. kDMA_MemoryToPeripheral, /*!< Transfer from memory to peripheral (increment only source)*/
  126. kDMA_StaticToStatic, /*!< Peripheral to static memory (do not increment source or destination) */
  127. } dma_transfer_type_t;
  128. /*! @brief DMA channel trigger */
  129. typedef struct _dma_channel_trigger {
  130. dma_trigger_type_t type;
  131. dma_trigger_burst_t burst;
  132. dma_burst_wrap_t wrap;
  133. } dma_channel_trigger_t;
  134. /*! @brief DMA transfer status */
  135. enum _dma_transfer_status
  136. {
  137. kStatus_DMA_Busy = MAKE_STATUS(kStatusGroup_DMA, 0), /*!< Channel is busy and can't handle the
  138. transfer request. */
  139. };
  140. /*! @brief DMA transfer configuration */
  141. typedef struct _dma_transfer_config
  142. {
  143. uint8_t *srcAddr; /*!< Source data address */
  144. uint8_t *dstAddr; /*!< Destination data address */
  145. uint8_t *nextDesc; /*!< Chain custom descriptor */
  146. dma_xfercfg_t xfercfg; /*!< Transfer options */
  147. bool isPeriph; /*!< DMA transfer is driven by peripheral */
  148. } dma_transfer_config_t;
  149. /*! @brief Callback for DMA */
  150. struct _dma_handle;
  151. /*! @brief Define Callback function for DMA. */
  152. typedef void (*dma_callback)(struct _dma_handle *handle, void *userData, bool transferDone, uint32_t intmode);
  153. /*! @brief DMA transfer handle structure */
  154. typedef struct _dma_handle
  155. {
  156. dma_callback callback; /*!< Callback function. Invoked when transfer
  157. of descriptor with interrupt flag finishes */
  158. void *userData; /*!< Callback function parameter */
  159. DMA_Type *base; /*!< DMA peripheral base address */
  160. uint8_t channel; /*!< DMA channel number */
  161. } dma_handle_t;
  162. /*******************************************************************************
  163. * APIs
  164. ******************************************************************************/
  165. #if defined(__cplusplus)
  166. extern "C" {
  167. #endif /* __cplusplus */
  168. /*!
  169. * @name DMA initialization and De-initialization
  170. * @{
  171. */
  172. /*!
  173. * @brief Initializes DMA peripheral.
  174. *
  175. * This function enable the DMA clock, set descriptor table and
  176. * enable DMA peripheral.
  177. *
  178. * @param base DMA peripheral base address.
  179. */
  180. void DMA_Init(DMA_Type *base);
  181. /*!
  182. * @brief Deinitializes DMA peripheral.
  183. *
  184. * This function gates the DMA clock.
  185. *
  186. * @param base DMA peripheral base address.
  187. */
  188. void DMA_Deinit(DMA_Type *base);
  189. /* @} */
  190. /*!
  191. * @name DMA Channel Operation
  192. * @{
  193. */
  194. /*!
  195. * @brief Return whether DMA channel is processing transfer
  196. *
  197. * @param base DMA peripheral base address.
  198. * @param channel DMA channel number.
  199. * @return True for active state, false otherwise.
  200. */
  201. static inline bool DMA_ChannelIsActive(DMA_Type *base, uint32_t channel)
  202. {
  203. assert(channel < FSL_FEATURE_DMA_NUMBER_OF_CHANNELS);
  204. return (base->COMMON[DMA_CHANNEL_GROUP(channel)].ACTIVE & (1U << DMA_CHANNEL_INDEX(channel))) ? true : false;
  205. }
  206. /*!
  207. * @brief Enables the interrupt source for the DMA transfer.
  208. *
  209. * @param base DMA peripheral base address.
  210. * @param channel DMA channel number.
  211. */
  212. static inline void DMA_EnableChannelInterrupts(DMA_Type *base, uint32_t channel)
  213. {
  214. assert(channel < FSL_FEATURE_DMA_NUMBER_OF_CHANNELS);
  215. base->COMMON[DMA_CHANNEL_GROUP(channel)].INTENSET |= 1U << DMA_CHANNEL_INDEX(channel);
  216. }
  217. /*!
  218. * @brief Disables the interrupt source for the DMA transfer.
  219. *
  220. * @param base DMA peripheral base address.
  221. * @param channel DMA channel number.
  222. */
  223. static inline void DMA_DisableChannelInterrupts(DMA_Type *base, uint32_t channel)
  224. {
  225. assert(channel < FSL_FEATURE_DMA_NUMBER_OF_CHANNELS);
  226. base->COMMON[DMA_CHANNEL_GROUP(channel)].INTENCLR |= 1U << DMA_CHANNEL_INDEX(channel);
  227. }
  228. /*!
  229. * @brief Enable DMA channel.
  230. *
  231. * @param base DMA peripheral base address.
  232. * @param channel DMA channel number.
  233. */
  234. static inline void DMA_EnableChannel(DMA_Type *base, uint32_t channel)
  235. {
  236. assert(channel < FSL_FEATURE_DMA_NUMBER_OF_CHANNELS);
  237. base->COMMON[DMA_CHANNEL_GROUP(channel)].ENABLESET |= 1U << DMA_CHANNEL_INDEX(channel);
  238. }
  239. /*!
  240. * @brief Disable DMA channel.
  241. *
  242. * @param base DMA peripheral base address.
  243. * @param channel DMA channel number.
  244. */
  245. static inline void DMA_DisableChannel(DMA_Type *base, uint32_t channel)
  246. {
  247. assert(channel < FSL_FEATURE_DMA_NUMBER_OF_CHANNELS);
  248. base->COMMON[DMA_CHANNEL_GROUP(channel)].ENABLECLR |= 1U << DMA_CHANNEL_INDEX(channel);
  249. }
  250. /*!
  251. * @brief Set PERIPHREQEN of channel configuration register.
  252. *
  253. * @param base DMA peripheral base address.
  254. * @param channel DMA channel number.
  255. */
  256. static inline void DMA_EnableChannelPeriphRq(DMA_Type *base, uint32_t channel)
  257. {
  258. assert(channel < FSL_FEATURE_DMA_NUMBER_OF_CHANNELS);
  259. base->CHANNEL[channel].CFG |= DMA_CHANNEL_CFG_PERIPHREQEN_MASK;
  260. }
  261. /*!
  262. * @brief Get PERIPHREQEN value of channel configuration register.
  263. *
  264. * @param base DMA peripheral base address.
  265. * @param channel DMA channel number.
  266. * @return True for enabled PeriphRq, false for disabled.
  267. */
  268. static inline void DMA_DisableChannelPeriphRq(DMA_Type *base, uint32_t channel)
  269. {
  270. assert(channel < FSL_FEATURE_DMA_NUMBER_OF_CHANNELS);
  271. base->CHANNEL[channel].CFG &= ~DMA_CHANNEL_CFG_PERIPHREQEN_MASK;
  272. }
  273. /*!
  274. * @brief Set trigger settings of DMA channel.
  275. *
  276. * @param base DMA peripheral base address.
  277. * @param channel DMA channel number.
  278. * @param trigger trigger configuration.
  279. */
  280. void DMA_ConfigureChannelTrigger(DMA_Type *base, uint32_t channel, dma_channel_trigger_t *trigger);
  281. /*!
  282. * @brief Gets the remaining bytes of the current DMA descriptor transfer.
  283. *
  284. * @param base DMA peripheral base address.
  285. * @param channel DMA channel number.
  286. * @return The number of bytes which have not been transferred yet.
  287. */
  288. uint32_t DMA_GetRemainingBytes(DMA_Type *base, uint32_t channel);
  289. /*!
  290. * @brief Set priority of channel configuration register.
  291. *
  292. * @param base DMA peripheral base address.
  293. * @param channel DMA channel number.
  294. * @param priority Channel priority value.
  295. */
  296. static inline void DMA_SetChannelPriority(DMA_Type *base, uint32_t channel, dma_priority_t priority)
  297. {
  298. assert(channel < FSL_FEATURE_DMA_NUMBER_OF_CHANNELS);
  299. base->CHANNEL[channel].CFG = (base->CHANNEL[channel].CFG & (~(DMA_CHANNEL_CFG_CHPRIORITY_MASK))) | DMA_CHANNEL_CFG_CHPRIORITY(priority);
  300. }
  301. /*!
  302. * @brief Get priority of channel configuration register.
  303. *
  304. * @param base DMA peripheral base address.
  305. * @param channel DMA channel number.
  306. * @return Channel priority value.
  307. */
  308. static inline dma_priority_t DMA_GetChannelPriority(DMA_Type *base, uint32_t channel)
  309. {
  310. assert(channel < FSL_FEATURE_DMA_NUMBER_OF_CHANNELS);
  311. return (dma_priority_t)((base->CHANNEL[channel].CFG & DMA_CHANNEL_CFG_CHPRIORITY_MASK) >> DMA_CHANNEL_CFG_CHPRIORITY_SHIFT);
  312. }
  313. /*!
  314. * @brief Create application specific DMA descriptor
  315. * to be used in a chain in transfer
  316. *
  317. * @param desc DMA descriptor address.
  318. * @param xfercfg Transfer configuration for DMA descriptor.
  319. * @param srcAddr Address of last item to transmit
  320. * @param dstAddr Address of last item to receive.
  321. * @param nextDesc Address of next descriptor in chain.
  322. */
  323. void DMA_CreateDescriptor(
  324. dma_descriptor_t *desc,
  325. dma_xfercfg_t *xfercfg,
  326. void *srcAddr,
  327. void *dstAddr,
  328. void *nextDesc
  329. );
  330. /* @} */
  331. /*!
  332. * @name DMA Transactional Operation
  333. * @{
  334. */
  335. /*!
  336. * @brief Abort running transfer by handle.
  337. *
  338. * This function aborts DMA transfer specified by handle.
  339. *
  340. * @param handle DMA handle pointer.
  341. */
  342. void DMA_AbortTransfer(dma_handle_t *handle);
  343. /*!
  344. * @brief Creates the DMA handle.
  345. *
  346. * This function is called if using transaction API for DMA. This function
  347. * initializes the internal state of DMA handle.
  348. *
  349. * @param handle DMA handle pointer. The DMA handle stores callback function and
  350. * parameters.
  351. * @param base DMA peripheral base address.
  352. * @param channel DMA channel number.
  353. */
  354. void DMA_CreateHandle(dma_handle_t *handle, DMA_Type *base, uint32_t channel);
  355. /*!
  356. * @brief Installs a callback function for the DMA transfer.
  357. *
  358. * This callback is called in DMA IRQ handler. Use the callback to do something after
  359. * the current major loop transfer completes.
  360. *
  361. * @param handle DMA handle pointer.
  362. * @param callback DMA callback function pointer.
  363. * @param userData Parameter for callback function.
  364. */
  365. void DMA_SetCallback(dma_handle_t *handle, dma_callback callback, void *userData);
  366. /*!
  367. * @brief Prepares the DMA transfer structure.
  368. *
  369. * This function prepares the transfer configuration structure according to the user input.
  370. *
  371. * @param config The user configuration structure of type dma_transfer_t.
  372. * @param srcAddr DMA transfer source address.
  373. * @param dstAddr DMA transfer destination address.
  374. * @param byteWidth DMA transfer destination address width(bytes).
  375. * @param transferBytes DMA transfer bytes to be transferred.
  376. * @param type DMA transfer type.
  377. * @param nextDesc Chain custom descriptor to transfer.
  378. * @note The data address and the data width must be consistent. For example, if the SRC
  379. * is 4 bytes, so the source address must be 4 bytes aligned, or it shall result in
  380. * source address error(SAE).
  381. */
  382. void DMA_PrepareTransfer(dma_transfer_config_t *config,
  383. void *srcAddr,
  384. void *dstAddr,
  385. uint32_t byteWidth,
  386. uint32_t transferBytes,
  387. dma_transfer_type_t type,
  388. void *nextDesc);
  389. /*!
  390. * @brief Submits the DMA transfer request.
  391. *
  392. * This function submits the DMA transfer request according to the transfer configuration structure.
  393. * If the user submits the transfer request repeatedly, this function packs an unprocessed request as
  394. * a TCD and enables scatter/gather feature to process it in the next time.
  395. *
  396. * @param handle DMA handle pointer.
  397. * @param config Pointer to DMA transfer configuration structure.
  398. * @retval kStatus_DMA_Success It means submit transfer request succeed.
  399. * @retval kStatus_DMA_QueueFull It means TCD queue is full. Submit transfer request is not allowed.
  400. * @retval kStatus_DMA_Busy It means the given channel is busy, need to submit request later.
  401. */
  402. status_t DMA_SubmitTransfer(dma_handle_t *handle, dma_transfer_config_t *config);
  403. /*!
  404. * @brief DMA start transfer.
  405. *
  406. * This function enables the channel request. User can call this function after submitting the transfer request
  407. * or before submitting the transfer request.
  408. *
  409. * @param handle DMA handle pointer.
  410. */
  411. void DMA_StartTransfer(dma_handle_t *handle);
  412. /*!
  413. * @brief DMA IRQ handler for descriptor transfer complete.
  414. *
  415. * This function clears the channel major interrupt flag and call
  416. * the callback function if it is not NULL.
  417. */
  418. void DMA_HandleIRQ(void);
  419. /* @} */
  420. #if defined(__cplusplus)
  421. }
  422. #endif /* __cplusplus */
  423. /* @} */
  424. #endif /*_FSL_DMA_H_*/