Thread (23 messages) 23 messages, 3 authors, 2011-08-11

[PATCH v2 6/8] mmc: atmel-mci: use ATMEL_PDC_SCND_BUF_OFF instead of a literal value

From: ludovic.desroches at atmel.com <hidden>
Date: 2011-08-11 15:25:46
Also in: linux-mmc
Subsystem: atm, microchip mmc/sd/sdio mci driver, multimedia card (mmc), secure digital (sd) and sdio subsystem, the rest · Maintainers: Chas Williams, Aubin Constans, Ulf Hansson, Linus Torvalds

From: Ludovic Desroches <redacted>

Signed-off-by: Ludovic Desroches <redacted>
---
 drivers/mmc/host/atmel-mci.c |    4 ++--
 include/linux/atmel_pdc.h    |    2 ++
 2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/mmc/host/atmel-mci.c b/drivers/mmc/host/atmel-mci.c
index 7955697..c415322 100644
--- a/drivers/mmc/host/atmel-mci.c
+++ b/drivers/mmc/host/atmel-mci.c
@@ -603,8 +603,8 @@ static void atmci_pdc_set_single_buf(struct atmel_mci *host,
 	}
 
 	if (buf_nb == PDC_SECOND_BUF) {
-		pointer_reg += 0x10;
-		counter_reg += 0x10;
+		pointer_reg += ATMEL_PDC_SCND_BUF_OFF;
+		counter_reg += ATMEL_PDC_SCND_BUF_OFF;
 	}
 
 	atmci_writel(host, pointer_reg, sg_dma_address(host->sg));
diff --git a/include/linux/atmel_pdc.h b/include/linux/atmel_pdc.h
index 5058a31..63499ce 100644
--- a/include/linux/atmel_pdc.h
+++ b/include/linux/atmel_pdc.h
@@ -33,4 +33,6 @@
 
 #define ATMEL_PDC_PTSR		0x124	/* Transfer Status Register */
 
+#define ATMEL_PDC_SCND_BUF_OFF	0x10	/* Offset between first and second buffer registers */
+
 #endif
-- 
1.7.0.4
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help