aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal
diff options
context:
space:
mode:
Diffstat (limited to 'os/hal')
-rw-r--r--os/hal/ports/SAMA/LLD/DMAv1/sama_xdmac.c1
-rw-r--r--os/hal/ports/SAMA/LLD/DMAv1/sama_xdmac.h12
2 files changed, 7 insertions, 6 deletions
diff --git a/os/hal/ports/SAMA/LLD/DMAv1/sama_xdmac.c b/os/hal/ports/SAMA/LLD/DMAv1/sama_xdmac.c
index 43e591440..d7d888fb7 100644
--- a/os/hal/ports/SAMA/LLD/DMAv1/sama_xdmac.c
+++ b/os/hal/ports/SAMA/LLD/DMAv1/sama_xdmac.c
@@ -287,6 +287,7 @@ sama_dma_channel_t* dmaChannelAllocate(uint32_t priority,
/* Setting aic */
aicSetSourcePriority(id, priority);
aicEnableInt(id);
+
/* Enabling DMA clocks required by the current channel set.*/
if (id == ID_XDMAC0) {
pmcEnableXDMAC0();
diff --git a/os/hal/ports/SAMA/LLD/DMAv1/sama_xdmac.h b/os/hal/ports/SAMA/LLD/DMAv1/sama_xdmac.h
index 609021e00..475627ef0 100644
--- a/os/hal/ports/SAMA/LLD/DMAv1/sama_xdmac.h
+++ b/os/hal/ports/SAMA/LLD/DMAv1/sama_xdmac.h
@@ -228,12 +228,12 @@ typedef struct {
*
* @special
*/
-#define dmaChannelDisable(dmachp) { \
- (dmachp)->xdmac->XDMAC_GD |= XDMAC_GD_DI0 << ((dmachp)->chid); \
- while (((dmachp)->xdmac->XDMAC_GS) & (XDMAC_GS_ST0 << (dmachp)->chid)) == 1) { \
- ; \
- } \
- dmaGetChannelInt(dmachp); \
+#define dmaChannelDisable(dmachp) { \
+ (dmachp)->xdmac->XDMAC_GD |= XDMAC_GD_DI0 << ((dmachp)->chid); \
+ while ((((dmachp)->xdmac->XDMAC_GS) & (XDMAC_GS_ST0 << (dmachp)->chid)) == 1) { \
+ ; \
+ } \
+ dmaGetChannelInt(dmachp); \
}
/**