Documentation: usb: EEM function testing
[deliverable/linux.git] / Documentation / usb / gadget-testing.txt
CommitLineData
e38eb2c8
AP
1This file summarizes information on basic testing of USB functions
2provided by gadgets.
3
41. ACM function
d5862ca6 52. ECM function
7bfbc6e3 63. ECM subset function
4ca560a6 74. EEM function
e38eb2c8
AP
8
9
101. ACM function
11===============
12
13The function is provided by usb_f_acm.ko module.
14
15Function-specific configfs interface
16------------------------------------
17
18The function name to use when creating the function directory is "acm".
19The ACM function provides just one attribute in its function directory:
20
21 port_num
22
23The attribute is read-only.
24
25There can be at most 4 ACM/generic serial/OBEX ports in the system.
26
27
28Testing the ACM function
29------------------------
30
31On the host: cat > /dev/ttyACM<X>
32On the device : cat /dev/ttyGS<Y>
33
34then the other way round
35
36On the device: cat > /dev/ttyGS<Y>
37On the host: cat /dev/ttyACM<X>
d5862ca6
AP
38
392. ECM function
40===============
41
42The function is provided by usb_f_ecm.ko module.
43
44Function-specific configfs interface
45------------------------------------
46
47The function name to use when creating the function directory is "ecm".
48The ECM function provides these attributes in its function directory:
49
50 ifname - network device interface name associated with this
51 function instance
52 qmult - queue length multiplier for high and super speed
53 host_addr - MAC address of host's end of this
54 Ethernet over USB link
55 dev_addr - MAC address of device's end of this
56 Ethernet over USB link
57
58and after creating the functions/ecm.<instance name> they contain default
59values: qmult is 5, dev_addr and host_addr are randomly selected.
60Except for ifname they can be written to until the function is linked to a
61configuration. The ifname is read-only and contains the name of the interface
62which was assigned by the net core, e. g. usb0.
63
64Testing the ECM function
65------------------------
66
67Configure IP addresses of the device and the host. Then:
68
69On the device: ping <host's IP>
70On the host: ping <device's IP>
7bfbc6e3
AP
71
723. ECM subset function
73======================
74
75The function is provided by usb_f_ecm_subset.ko module.
76
77Function-specific configfs interface
78------------------------------------
79
80The function name to use when creating the function directory is "geth".
81The ECM subset function provides these attributes in its function directory:
82
83 ifname - network device interface name associated with this
84 function instance
85 qmult - queue length multiplier for high and super speed
86 host_addr - MAC address of host's end of this
87 Ethernet over USB link
88 dev_addr - MAC address of device's end of this
89 Ethernet over USB link
90
91and after creating the functions/ecm.<instance name> they contain default
92values: qmult is 5, dev_addr and host_addr are randomly selected.
93Except for ifname they can be written to until the function is linked to a
94configuration. The ifname is read-only and contains the name of the interface
95which was assigned by the net core, e. g. usb0.
96
97Testing the ECM subset function
98-------------------------------
99
100Configure IP addresses of the device and the host. Then:
101
102On the device: ping <host's IP>
103On the host: ping <device's IP>
4ca560a6
AP
104
1054. EEM function
106===============
107
108The function is provided by usb_f_eem.ko module.
109
110Function-specific configfs interface
111------------------------------------
112
113The function name to use when creating the function directory is "eem".
114The EEM function provides these attributes in its function directory:
115
116 ifname - network device interface name associated with this
117 function instance
118 qmult - queue length multiplier for high and super speed
119 host_addr - MAC address of host's end of this
120 Ethernet over USB link
121 dev_addr - MAC address of device's end of this
122 Ethernet over USB link
123
124and after creating the functions/eem.<instance name> they contain default
125values: qmult is 5, dev_addr and host_addr are randomly selected.
126Except for ifname they can be written to until the function is linked to a
127configuration. The ifname is read-only and contains the name of the interface
128which was assigned by the net core, e. g. usb0.
129
130Testing the EEM function
131------------------------
132
133Configure IP addresses of the device and the host. Then:
134
135On the device: ping <host's IP>
136On the host: ping <device's IP>
This page took 0.029361 seconds and 5 git commands to generate.