aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorSonic Zhang <sonic.zhang@analog.com>2012-05-15 02:17:35 -0400
committerBob Liu <lliubbo@gmail.com>2012-05-21 02:54:58 -0400
commit913f2f2df797c45e92ab527022cd49deb6eee3ab (patch)
treeecdc3b59ec9aec482792d8e77179702b7c77c23a /arch
parent8bf7135fff46f6ac28baf28a8e4144f685b456a0 (diff)
blackfin: bf60x: anomaly: Add a temporary anomaly 0501001
Add a temporary anomaly 0501001 for data loss in MMR reading if interrupted. Add work around for bfin serial driver as well. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/blackfin/include/asm/bfin_serial.h12
-rw-r--r--arch/blackfin/mach-bf609/include/mach/anomaly.h2
2 files changed, 14 insertions, 0 deletions
diff --git a/arch/blackfin/include/asm/bfin_serial.h b/arch/blackfin/include/asm/bfin_serial.h
index 235c72a1f92d..8597158010b5 100644
--- a/arch/blackfin/include/asm/bfin_serial.h
+++ b/arch/blackfin/include/asm/bfin_serial.h
@@ -282,7 +282,19 @@ struct bfin_uart_regs {
282#define UART_GET_GCTL(p) UART_GET_CTL(p) 282#define UART_GET_GCTL(p) UART_GET_CTL(p)
283#define UART_GET_LCR(p) UART_GET_CTL(p) 283#define UART_GET_LCR(p) UART_GET_CTL(p)
284#define UART_GET_MCR(p) UART_GET_CTL(p) 284#define UART_GET_MCR(p) UART_GET_CTL(p)
285#if ANOMALY_05001001
286#define UART_GET_STAT(p) \
287({ \
288 u32 __ret; \
289 unsigned long flags; \
290 flags = hard_local_irq_save(); \
291 __ret = bfin_read32(port_membase(p) + OFFSET_STAT); \
292 hard_local_irq_restore(flags); \
293 __ret; \
294})
295#else
285#define UART_GET_STAT(p) bfin_read32(port_membase(p) + OFFSET_STAT) 296#define UART_GET_STAT(p) bfin_read32(port_membase(p) + OFFSET_STAT)
297#endif
286#define UART_GET_MSR(p) UART_GET_STAT(p) 298#define UART_GET_MSR(p) UART_GET_STAT(p)
287 299
288#define UART_PUT_CHAR(p, v) bfin_write32(port_membase(p) + OFFSET_THR, v) 300#define UART_PUT_CHAR(p, v) bfin_write32(port_membase(p) + OFFSET_THR, v)
diff --git a/arch/blackfin/mach-bf609/include/mach/anomaly.h b/arch/blackfin/mach-bf609/include/mach/anomaly.h
index 97a9c65bbe32..bdd39aefb565 100644
--- a/arch/blackfin/mach-bf609/include/mach/anomaly.h
+++ b/arch/blackfin/mach-bf609/include/mach/anomaly.h
@@ -57,6 +57,8 @@
57#define ANOMALY_05000481 (1) 57#define ANOMALY_05000481 (1)
58/* IFLUSH sucks at life */ 58/* IFLUSH sucks at life */
59#define ANOMALY_05000491 (1) 59#define ANOMALY_05000491 (1)
60/* Tempopary anomaly ID for data loss in MMR read operation if interrupted */
61#define ANOMALY_05001001 (__SILICON_REVISION__ < 1)
60 62
61/* Anomalies that don't exist on this proc */ 63/* Anomalies that don't exist on this proc */
62#define ANOMALY_05000099 (0) 64#define ANOMALY_05000099 (0)