]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/usb/gadget/omap_udc.h
Merge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus
[linux-2.6-omap-h63xx.git] / drivers / usb / gadget / omap_udc.h
index c9e68541622c9e86c12372fd03b25b3766c3f432..c6b9cbc7230a5bb121feb288dd9ce3228c9f984d 100644 (file)
@@ -20,6 +20,7 @@
 #define        UDC_CTRL_REG                    UDC_REG(0x0C)   /* Endpoint control */
 #      define  UDC_CLR_HALT            (1 << 7)
 #      define  UDC_SET_HALT            (1 << 6)
+#      define  UDC_CLRDATA_TOGGLE      (1 << 3)
 #      define  UDC_SET_FIFO_EN         (1 << 2)
 #      define  UDC_CLR_EP              (1 << 1)
 #      define  UDC_RESET_EP            (1 << 0)
 
 /* DMA configuration registers:  up to three channels in each direction.  */
 #define        UDC_RXDMA_CFG_REG               UDC_REG(0x40)   /* 3 eps for RX DMA */
+#      define  UDC_DMA_REQ             (1 << 12)
 #define        UDC_TXDMA_CFG_REG               UDC_REG(0x44)   /* 3 eps for TX DMA */
 #define        UDC_DATA_DMA_REG                UDC_REG(0x48)   /* rx/tx fifo addr */
 
@@ -162,6 +164,7 @@ struct omap_udc {
        spinlock_t                      lock;
        struct omap_ep                  ep[32];
        u16                             devstat;
+       u16                             clr_halt;
        struct otg_transceiver          *transceiver;
        struct list_head                iso;
        unsigned                        softconnect:1;
@@ -171,27 +174,24 @@ struct omap_udc {
        unsigned                        ep0_set_config:1;
        unsigned                        ep0_reset_config:1;
        unsigned                        ep0_setup:1;
-
        struct completion               *done;
+       struct clk                      *dc_clk;
+       struct clk                      *hhc_clk;
+       unsigned                        clk_requested:1;
 };
 
 /*-------------------------------------------------------------------------*/
 
-#ifdef DEBUG
-#define DBG(stuff...)          printk(KERN_DEBUG "udc: " stuff)
-#else
-#define DBG(stuff...)          do{}while(0)
-#endif
-
 #ifdef VERBOSE
 #    define VDBG               DBG
 #else
 #    define VDBG(stuff...)     do{}while(0)
 #endif
 
-#define ERR(stuff...)          printk(KERN_ERR "udc: " stuff)
-#define WARN(stuff...)         printk(KERN_WARNING "udc: " stuff)
-#define INFO(stuff...)         printk(KERN_INFO "udc: " stuff)
+#define ERR(stuff...)          pr_err("udc: " stuff)
+#define WARN(stuff...)         pr_warning("udc: " stuff)
+#define INFO(stuff...)         pr_info("udc: " stuff)
+#define DBG(stuff...)          pr_debug("udc: " stuff)
 
 /*-------------------------------------------------------------------------*/