xref: /openbmc/u-boot/include/usb_cdc_acm.h (revision 15855700)
1 /*
2  * (C) Copyright 2006
3  * Bryan O'Donoghue, deckard@codehermit.ie, CodeHermit
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License as published by
7  * the Free Software Foundation; either version 2 of the License, or
8  * (at your option) any later version.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.	 See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License
16  * along with this program; if not, write to the Free Software
17  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
18  *
19  */
20 
21 /* ACM Control Requests */
22 #define ACM_SEND_ENCAPSULATED_COMMAND	0x00
23 #define ACM_GET_ENCAPSULATED_RESPONSE	0x01
24 #define ACM_SET_COMM_FEATURE		0x02
25 #define ACM_GET_COMM_FEATRUE		0x03
26 #define ACM_CLEAR_COMM_FEATURE		0x04
27 #define ACM_SET_LINE_ENCODING		0x20
28 #define ACM_GET_LINE_ENCODING		0x21
29 #define ACM_SET_CONTROL_LINE_STATE	0x22
30 #define ACM_SEND_BREAK			0x23
31 
32 /* ACM Notification Codes */
33 #define ACM_NETWORK_CONNECTION		0x00
34 #define ACM_RESPONSE_AVAILABLE		0x01
35 #define ACM_SERIAL_STATE		0x20
36 
37 /* Format of response expected by a ACM_GET_LINE_ENCODING request */
38 struct rs232_emu{
39 		unsigned long dter;
40 		unsigned char stop_bits;
41 		unsigned char parity;
42 		unsigned char data_bits;
43 }__attribute__((packed));
44