diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/usb/musb.h | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/include/linux/usb/musb.h b/include/linux/usb/musb.h index 7acef0234c0e..f3d68f62dae8 100644 --- a/include/linux/usb/musb.h +++ b/include/linux/usb/musb.h | |||
@@ -22,12 +22,47 @@ enum musb_mode { | |||
22 | 22 | ||
23 | struct clk; | 23 | struct clk; |
24 | 24 | ||
25 | enum musb_fifo_style { | ||
26 | FIFO_RXTX, | ||
27 | FIFO_TX, | ||
28 | FIFO_RX | ||
29 | } __attribute__ ((packed)); | ||
30 | |||
31 | enum musb_buf_mode { | ||
32 | BUF_SINGLE, | ||
33 | BUF_DOUBLE | ||
34 | } __attribute__ ((packed)); | ||
35 | |||
36 | struct musb_fifo_cfg { | ||
37 | u8 hw_ep_num; | ||
38 | enum musb_fifo_style style; | ||
39 | enum musb_buf_mode mode; | ||
40 | u16 maxpacket; | ||
41 | }; | ||
42 | |||
43 | #define MUSB_EP_FIFO(ep, st, m, pkt) \ | ||
44 | { \ | ||
45 | .hw_ep_num = ep, \ | ||
46 | .style = st, \ | ||
47 | .mode = m, \ | ||
48 | .maxpacket = pkt, \ | ||
49 | } | ||
50 | |||
51 | #define MUSB_EP_FIFO_SINGLE(ep, st, pkt) \ | ||
52 | MUSB_EP_FIFO(ep, st, BUF_SINGLE, pkt) | ||
53 | |||
54 | #define MUSB_EP_FIFO_DOUBLE(ep, st, pkt) \ | ||
55 | MUSB_EP_FIFO(ep, st, BUF_DOUBLE, pkt) | ||
56 | |||
25 | struct musb_hdrc_eps_bits { | 57 | struct musb_hdrc_eps_bits { |
26 | const char name[16]; | 58 | const char name[16]; |
27 | u8 bits; | 59 | u8 bits; |
28 | }; | 60 | }; |
29 | 61 | ||
30 | struct musb_hdrc_config { | 62 | struct musb_hdrc_config { |
63 | struct musb_fifo_cfg *fifo_cfg; /* board fifo configuration */ | ||
64 | unsigned fifo_cfg_size; /* size of the fifo configuration */ | ||
65 | |||
31 | /* MUSB configuration-specific details */ | 66 | /* MUSB configuration-specific details */ |
32 | unsigned multipoint:1; /* multipoint device */ | 67 | unsigned multipoint:1; /* multipoint device */ |
33 | unsigned dyn_fifo:1 __deprecated; /* supports dynamic fifo sizing */ | 68 | unsigned dyn_fifo:1 __deprecated; /* supports dynamic fifo sizing */ |