-#define DMA_BUS_MODE_SWR AR_BIT(0) /* software reset */
-#define DMA_BUS_MODE_BLE AR_BIT(7) /* big endian mode */
-#define DMA_BUS_MODE_PBL_SHIFT 8 /* programmable burst length 32 */
-#define DMA_BUS_MODE_DBO AR_BIT(20) /* big-endian descriptors */
-
-#define DMA_STATUS_TI AR_BIT(0) /* transmit interrupt */
-#define DMA_STATUS_TPS AR_BIT(1) /* transmit process stopped */
-#define DMA_STATUS_TU AR_BIT(2) /* transmit buffer unavailable */
-#define DMA_STATUS_TJT AR_BIT(3) /* transmit buffer timeout */
-#define DMA_STATUS_UNF AR_BIT(5) /* transmit underflow */
-#define DMA_STATUS_RI AR_BIT(6) /* receive interrupt */
-#define DMA_STATUS_RU AR_BIT(7) /* receive buffer unavailable */
-#define DMA_STATUS_RPS AR_BIT(8) /* receive process stopped */
-#define DMA_STATUS_ETI AR_BIT(10) /* early transmit interrupt */
-#define DMA_STATUS_FBE AR_BIT(13) /* fatal bus interrupt */
-#define DMA_STATUS_ERI AR_BIT(14) /* early receive interrupt */
-#define DMA_STATUS_AIS AR_BIT(15) /* abnormal interrupt summary */
-#define DMA_STATUS_NIS AR_BIT(16) /* normal interrupt summary */
-#define DMA_STATUS_RS_SHIFT 17 /* receive process state */
-#define DMA_STATUS_TS_SHIFT 20 /* transmit process state */
-#define DMA_STATUS_EB_SHIFT 23 /* error bits */
-
-#define DMA_CONTROL_SR AR_BIT(1) /* start receive */
-#define DMA_CONTROL_ST AR_BIT(13) /* start transmit */
-#define DMA_CONTROL_SF AR_BIT(21) /* store and forward */
-
-#endif // __ARUBA_DMA_H__
-
-
-
-
-
+#define DMA_BUS_MODE_SWR AR_BIT(0) /* software reset */
+#define DMA_BUS_MODE_BLE AR_BIT(7) /* big endian mode */
+#define DMA_BUS_MODE_PBL_SHIFT 8 /* programmable burst length 32 */
+#define DMA_BUS_MODE_DBO AR_BIT(20) /* big-endian descriptors */
+
+#define DMA_STATUS_TI AR_BIT(0) /* transmit interrupt */
+#define DMA_STATUS_TPS AR_BIT(1) /* transmit process stopped */
+#define DMA_STATUS_TU AR_BIT(2) /* transmit buffer unavailable */
+#define DMA_STATUS_TJT AR_BIT(3) /* transmit buffer timeout */
+#define DMA_STATUS_UNF AR_BIT(5) /* transmit underflow */
+#define DMA_STATUS_RI AR_BIT(6) /* receive interrupt */
+#define DMA_STATUS_RU AR_BIT(7) /* receive buffer unavailable */
+#define DMA_STATUS_RPS AR_BIT(8) /* receive process stopped */
+#define DMA_STATUS_ETI AR_BIT(10) /* early transmit interrupt */
+#define DMA_STATUS_FBE AR_BIT(13) /* fatal bus interrupt */
+#define DMA_STATUS_ERI AR_BIT(14) /* early receive interrupt */
+#define DMA_STATUS_AIS AR_BIT(15) /* abnormal interrupt summary */
+#define DMA_STATUS_NIS AR_BIT(16) /* normal interrupt summary */
+#define DMA_STATUS_RS_SHIFT 17 /* receive process state */
+#define DMA_STATUS_TS_SHIFT 20 /* transmit process state */
+#define DMA_STATUS_EB_SHIFT 23 /* error bits */
+
+#define DMA_CONTROL_SR AR_BIT(1) /* start receive */
+#define DMA_CONTROL_ST AR_BIT(13) /* start transmit */
+#define DMA_CONTROL_SF AR_BIT(21) /* store and forward */
+
+
+typedef struct {
+ volatile unsigned int status; // OWN, Device control and status.
+ volatile unsigned int devcs; // pkt Control bits + Length
+ volatile unsigned int addr; // Current Address.
+ volatile unsigned int descr; // Next descriptor in chain.
+} ar2313_descr_t;
+
+
+#endif // __ARUBA_DMA_H__