aboutsummaryrefslogtreecommitdiffstats
path: root/os
diff options
context:
space:
mode:
authoredolomb <none@example.com>2017-10-01 16:05:58 +0000
committeredolomb <none@example.com>2017-10-01 16:05:58 +0000
commit8314ce1ebf26dc8bd7221da18d32731904593229 (patch)
treef132fc9a7163882f7c505ed0acbe2008c19b8727 /os
parentc6f5c2669fc095ec3e97d42ec64e172da97b9648 (diff)
downloadChibiOS-8314ce1ebf26dc8bd7221da18d32731904593229.tar.gz
ChibiOS-8314ce1ebf26dc8bd7221da18d32731904593229.tar.bz2
ChibiOS-8314ce1ebf26dc8bd7221da18d32731904593229.zip
Minor changes in sama_xdmac driver
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@10738 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os')
-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); \
}
/**