GUI: Fix Tomato RAF theme for all builds. Compilation typo.
[tomato.git] / release / src-rt-6.x.4708 / linux / linux-2.6.36 / drivers / usb / musb / blackfin.h
blobf1afddfef7366f00f6e7b8b9313e31e5d26341cd
1 /*
2 * Copyright (C) 2007 by Analog Devices, Inc.
4 * The Inventra Controller Driver for Linux is free software; you
5 * can redistribute it and/or modify it under the terms of the GNU
6 * General Public License version 2 as published by the Free Software
7 * Foundation.
8 */
10 #ifndef __MUSB_BLACKFIN_H__
11 #define __MUSB_BLACKFIN_H__
14 * Blackfin specific definitions
18 /* The Mentor USB DMA engine on BF52x (silicon v0.0 and v0.1) seems to be
19 * unstable in host mode. This may be caused by Anomaly 05000380. After
20 * digging out the root cause, we will change this number accordingly.
21 * So, need to either use silicon v0.2+ or disable DMA mode in MUSB.
23 #if ANOMALY_05000380 && defined(CONFIG_BF52x) && defined(CONFIG_USB_MUSB_HDRC) && \
24 !defined(CONFIG_MUSB_PIO_ONLY)
25 # error "Please use PIO mode in MUSB driver on bf52x chip v0.0 and v0.1"
26 #endif
28 #undef DUMP_FIFO_DATA
29 #ifdef DUMP_FIFO_DATA
30 static void dump_fifo_data(u8 *buf, u16 len)
32 u8 *tmp = buf;
33 int i;
35 for (i = 0; i < len; i++) {
36 if (!(i % 16) && i)
37 pr_debug("\n");
38 pr_debug("%02x ", *tmp++);
40 pr_debug("\n");
42 #else
43 #define dump_fifo_data(buf, len) do {} while (0)
44 #endif
47 #define USB_DMA_BASE USB_DMA_INTERRUPT
48 #define USB_DMAx_CTRL 0x04
49 #define USB_DMAx_ADDR_LOW 0x08
50 #define USB_DMAx_ADDR_HIGH 0x0C
51 #define USB_DMAx_COUNT_LOW 0x10
52 #define USB_DMAx_COUNT_HIGH 0x14
54 #define USB_DMA_REG(ep, reg) (USB_DMA_BASE + 0x20 * ep + reg)
56 /* Almost 1 second */
57 #define TIMER_DELAY (1 * HZ)
59 static struct timer_list musb_conn_timer;
61 #endif /* __MUSB_BLACKFIN_H__ */