First USB sketch.
[cascardo/kernel/slides/.git] / 13buses / usb
1 %USB
2 %Thadeu Cascardo
3
4 # Universal Serial Bus
5
6 * USB 1.0 and 1.1, 1.5Mbps and 12Mbps
7 * USB 2.0 - up to 480Mbps
8 * USB 3.0 - up to 5Gbps
9 * Wireless USB - over Ultra Wideband
10
11 # USB - Cont.
12
13 * A master/slave bus: the master asks the slave to send data
14 * Auto-configurable and hotplugable
15 * Standards specifications, allowing device classes, with no specific driver
16 * HCDs, USB devices and Gadget devices and their respective drivers
17
18 # USB Basics
19
20 * Configurations
21 * Interfaces
22 * Settings
23 * Endpoints
24 * URBs
25
26 # Endpoints and URBs
27
28 * IN and OUT Endpoints
29 * Control Endpoints
30 * Interrupt Endpoints
31 * Bulk Endpoints
32 * Isochronous Endpoints
33
34 # USB IDs
35
36 * struct usb\\_device\\_id
37 * USB\\_DEVICE
38 * Others
39
40 # USB Driver
41
42 * struct usb\\_driver
43         - name
44         - id\\_table
45         - probe
46         - disconnect
47
48 # USB Interface
49
50 * struct usb\\_interface
51         - struct usb\\_host\\_interface cur\\_altsetting
52                 * desc.bNumEndpoints
53                 * struct usb\\_endpoint\\_descriptor endpoint[].desc
54 * usb\\_get\\_intf
55 * usb\\_put\\_intf
56
57 # Endpoints
58
59 * struct usb\\_endpoint\\_descriptor
60 * usb\\_endpoint\\_is\\_isoc\\_in
61 * usb\\_endpoint\\_num
62
63 # URBs
64
65 * struct urb
66         - status
67         - transfer\\_buffer
68         - actual\\_length
69 * usb\\_alloc\\_urb
70 * usb\\_free\\_usb
71 * usb\\_submit\\_urb
72 * usb\\_kill\\_urb
73 * usb\\_fill\\_control\\_urb
74 * usb\\_fill\\_bulk\\_urb
75 * usb\\_control\\_msg
76
77 # URBs
78
79 * Callbacks execute in interrupt context
80 * May resubmit an URB, but must use GFP\\_ATOMIC