summaryrefslogtreecommitdiff
path: root/include/usb
diff options
context:
space:
mode:
authorMarek Vasut <marex@denx.de>2013-07-10 03:16:29 +0200
committerMarek Vasut <marex@denx.de>2013-07-29 23:01:31 +0200
commit532d846f891f31e2582428d7572b98103e3ec268 (patch)
tree95017a4a95ef4ba225c6d1c62442f58f4bd75e4a /include/usb
parent6368c9194585ca7a1e35fb6806ff7d062e16299f (diff)
downloadu-boot-imx-532d846f891f31e2582428d7572b98103e3ec268.zip
u-boot-imx-532d846f891f31e2582428d7572b98103e3ec268.tar.gz
u-boot-imx-532d846f891f31e2582428d7572b98103e3ec268.tar.bz2
usb: mv_udc: Move endpoint array into driver data
The endpoints are operated on a per-controller basis, move the endpoint array into controller's private data. Also shuffle the struct mv_ep structure definition just above the definition of the struct mv_drv so they're well grouped together. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Fabio Estevam <fabio.estevam@freescale.com> Cc: Lei Wen <leiwen@marvell.com> Cc: Otavio Salvador <otavio@ossystems.com.br> Cc: Stefano Babic <sbabic@denx.de>
Diffstat (limited to 'include/usb')
-rw-r--r--include/usb/mv_udc.h17
1 files changed, 9 insertions, 8 deletions
diff --git a/include/usb/mv_udc.h b/include/usb/mv_udc.h
index f7405e9..f92ca49 100644
--- a/include/usb/mv_udc.h
+++ b/include/usb/mv_udc.h
@@ -22,13 +22,6 @@
#define EP_MAX_PACKET_SIZE 0x200
#define EP0_MAX_PACKET_SIZE 64
-struct mv_ep {
- struct usb_ep ep;
- struct usb_request req;
- struct list_head queue;
- const struct usb_endpoint_descriptor *desc;
-};
-
struct mv_udc {
u32 pad0[80];
#define MICRO_8FRAME 0x8
@@ -70,10 +63,18 @@ struct mv_udc {
u32 epctrl[16]; /* 0x1c0 */
};
+struct mv_ep {
+ struct usb_ep ep;
+ struct usb_request req;
+ struct list_head queue;
+ const struct usb_endpoint_descriptor *desc;
+};
+
struct mv_drv {
struct usb_gadget gadget;
- struct usb_gadget_driver *driver;
+ struct usb_gadget_driver *driver;
struct mv_udc *udc;
+ struct mv_ep ep[2 * NUM_ENDPOINTS];
};
struct ept_queue_head {