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