]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - drivers/usb/gadget/ci13xxx_udc.h
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/wfg/writeback
[karo-tx-linux.git] / drivers / usb / gadget / ci13xxx_udc.h
index a2492b65f98c41a3b57e795c546f73eb6b551d46..23707775cb434f5ac93c2221fda10ba57804b6e4 100644 (file)
@@ -33,6 +33,7 @@ struct ci13xxx_td {
        /* 0 */
        u32 next;
 #define TD_TERMINATE          BIT(0)
+#define TD_ADDR_MASK          (0xFFFFFFEUL << 5)
        /* 1 */
        u32 token;
 #define TD_STATUS             (0x00FFUL <<  0)
@@ -74,6 +75,8 @@ struct ci13xxx_req {
        struct list_head     queue;
        struct ci13xxx_td   *ptr;
        dma_addr_t           dma;
+       struct ci13xxx_td   *zptr;
+       dma_addr_t           zdma;
 };
 
 /* Extension of usb_ep */
@@ -125,6 +128,10 @@ struct ci13xxx {
        u32                        ep0_dir;    /* ep0 direction */
 #define ep0out ci13xxx_ep[0]
 #define ep0in  ci13xxx_ep[16]
+       u8                         remote_wakeup; /* Is remote wakeup feature
+                                                       enabled by the host? */
+       u8                         suspended;  /* suspended by the host */
+       u8                         test_mode;  /* the selected test mode */
 
        struct usb_gadget_driver  *driver;     /* 3rd party gadget driver */
        struct ci13xxx_udc_driver *udc_driver; /* device controller driver */
@@ -152,6 +159,7 @@ struct ci13xxx {
 #define USBCMD_RS             BIT(0)
 #define USBCMD_RST            BIT(1)
 #define USBCMD_SUTW           BIT(13)
+#define USBCMD_ATDTW          BIT(14)
 
 /* USBSTS & USBINTR */
 #define USBi_UI               BIT(0)
@@ -165,6 +173,7 @@ struct ci13xxx {
 #define DEVICEADDR_USBADR     (0x7FUL << 25)
 
 /* PORTSC */
+#define PORTSC_FPR            BIT(6)
 #define PORTSC_SUSP           BIT(7)
 #define PORTSC_HSP            BIT(9)
 #define PORTSC_PTC            (0x0FUL << 16)