Fedora kernel-2.6.17-1.2142_FC4 patched with stable patch-2.6.17.4-vs2.0.2-rc26.diff
[linux-2.6.git] / drivers / usb / serial / visor.h
1 /*
2  * USB HandSpring Visor driver
3  *
4  *      Copyright (C) 1999 - 2003
5  *          Greg Kroah-Hartman (greg@kroah.com)
6  *
7  *      This program is free software; you can redistribute it and/or modify
8  *      it under the terms of the GNU General Public License as published by
9  *      the Free Software Foundation; either version 2 of the License, or
10  *      (at your option) any later version.
11  *
12  * See Documentation/usb/usb-serial.txt for more information on using this driver
13  * 
14  */
15
16 #ifndef __LINUX_USB_SERIAL_VISOR_H
17 #define __LINUX_USB_SERIAL_VISOR_H
18
19
20 #define HANDSPRING_VENDOR_ID            0x082d
21 #define HANDSPRING_VISOR_ID             0x0100
22 #define HANDSPRING_TREO_ID              0x0200
23 #define HANDSPRING_TREO600_ID           0x0300
24
25 #define PALM_VENDOR_ID                  0x0830
26 #define PALM_M500_ID                    0x0001
27 #define PALM_M505_ID                    0x0002
28 #define PALM_M515_ID                    0x0003
29 #define PALM_I705_ID                    0x0020
30 #define PALM_M125_ID                    0x0040
31 #define PALM_M130_ID                    0x0050
32 #define PALM_TUNGSTEN_T_ID              0x0060
33 #define PALM_TREO_650                   0x0061
34 #define PALM_TUNGSTEN_Z_ID              0x0031
35 #define PALM_ZIRE31_ID                  0x0061
36 #define PALM_ZIRE_ID                    0x0070
37 #define PALM_M100_ID                    0x0080
38
39 #define GSPDA_VENDOR_ID         0x115e
40 #define GSPDA_XPLORE_M68_ID             0xf100
41
42 #define SONY_VENDOR_ID                  0x054C
43 #define SONY_CLIE_3_5_ID                0x0038
44 #define SONY_CLIE_4_0_ID                0x0066
45 #define SONY_CLIE_S360_ID               0x0095
46 #define SONY_CLIE_4_1_ID                0x009A
47 #define SONY_CLIE_NX60_ID               0x00DA
48 #define SONY_CLIE_NZ90V_ID              0x00E9
49 #define SONY_CLIE_UX50_ID               0x0144
50 #define SONY_CLIE_TJ25_ID               0x0169
51
52 #define SAMSUNG_VENDOR_ID               0x04E8
53 #define SAMSUNG_SCH_I330_ID             0x8001
54 #define SAMSUNG_SPH_I500_ID             0x6601
55
56 #define TAPWAVE_VENDOR_ID               0x12EF
57 #define TAPWAVE_ZODIAC_ID               0x0100
58
59 #define GARMIN_VENDOR_ID                0x091E
60 #define GARMIN_IQUE_3600_ID             0x0004
61
62 #define ACEECA_VENDOR_ID                0x4766
63 #define ACEECA_MEZ1000_ID               0x0001
64
65 #define KYOCERA_VENDOR_ID               0x0C88
66 #define KYOCERA_7135_ID                 0x0021 
67
68 #define FOSSIL_VENDOR_ID                0x0E67
69 #define FOSSIL_ABACUS_ID                0x0002
70
71 /****************************************************************************
72  * Handspring Visor Vendor specific request codes (bRequest values)
73  * A big thank you to Handspring for providing the following information.
74  * If anyone wants the original file where these values and structures came
75  * from, send email to <greg@kroah.com>.
76  ****************************************************************************/
77
78 /****************************************************************************
79  * VISOR_REQUEST_BYTES_AVAILABLE asks the visor for the number of bytes that
80  * are available to be transferred to the host for the specified endpoint.
81  * Currently this is not used, and always returns 0x0001
82  ****************************************************************************/
83 #define VISOR_REQUEST_BYTES_AVAILABLE           0x01
84
85 /****************************************************************************
86  * VISOR_CLOSE_NOTIFICATION is set to the device to notify it that the host
87  * is now closing the pipe. An empty packet is sent in response.
88  ****************************************************************************/
89 #define VISOR_CLOSE_NOTIFICATION                0x02
90
91 /****************************************************************************
92  * VISOR_GET_CONNECTION_INFORMATION is sent by the host during enumeration to
93  * get the endpoints used by the connection.
94  ****************************************************************************/
95 #define VISOR_GET_CONNECTION_INFORMATION        0x03
96
97
98 /****************************************************************************
99  * VISOR_GET_CONNECTION_INFORMATION returns data in the following format
100  ****************************************************************************/
101 struct visor_connection_info {
102         __le16  num_ports;
103         struct {
104                 __u8    port_function_id;
105                 __u8    port;
106         } connections[2];
107 };
108
109
110 /* struct visor_connection_info.connection[x].port defines: */
111 #define VISOR_ENDPOINT_1                0x01
112 #define VISOR_ENDPOINT_2                0x02
113
114 /* struct visor_connection_info.connection[x].port_function_id defines: */
115 #define VISOR_FUNCTION_GENERIC          0x00
116 #define VISOR_FUNCTION_DEBUGGER         0x01
117 #define VISOR_FUNCTION_HOTSYNC          0x02
118 #define VISOR_FUNCTION_CONSOLE          0x03
119 #define VISOR_FUNCTION_REMOTE_FILE_SYS  0x04
120
121
122 /****************************************************************************
123  * PALM_GET_SOME_UNKNOWN_INFORMATION is sent by the host during enumeration to
124  * get some information from the M series devices, that is currently unknown.
125  ****************************************************************************/
126 #define PALM_GET_EXT_CONNECTION_INFORMATION     0x04
127
128 /**
129  * struct palm_ext_connection_info - return data from a PALM_GET_EXT_CONNECTION_INFORMATION request
130  * @num_ports: maximum number of functions/connections in use
131  * @endpoint_numbers_different: will be 1 if in and out endpoints numbers are
132  *      different, otherwise it is 0.  If value is 1, then
133  *      connections.end_point_info is non-zero.  If value is 0, then
134  *      connections.port contains the endpoint number, which is the same for in
135  *      and out.
136  * @port_function_id: contains the creator id of the applicaton that opened
137  *      this connection.
138  * @port: contains the in/out endpoint number.  Is 0 if in and out endpoint
139  *      numbers are different.
140  * @end_point_info: high nubbe is in endpoint and low nibble will indicate out
141  *      endpoint.  Is 0 if in and out endpoints are the same.
142  *
143  * The maximum number of connections currently supported is 2
144  */
145 struct palm_ext_connection_info {
146         __u8 num_ports;         
147         __u8 endpoint_numbers_different;
148         __le16 reserved1;
149         struct {
150                 __u32 port_function_id;
151                 __u8 port;
152                 __u8 end_point_info;
153                 __le16 reserved;
154         } connections[2];
155 };
156
157 #endif
158