11da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds/************************************************************************ 21da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * 31da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * USBVEND.H Vendor-specific USB definitions 41da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * 51da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * NOTE: This must be kept in sync with the Edgeport firmware and 61da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * must be kept backward-compatible with older firmware. 71da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * 81da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds ************************************************************************ 91da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * 101da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * Copyright (C) 1998 Inside Out Networks, Inc. 111da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * This program is free software; you can redistribute it and/or modify 121da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * it under the terms of the GNU General Public License as published by 131da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * the Free Software Foundation; either version 2 of the License, or 141da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * (at your option) any later version. 151da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * 161da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds ************************************************************************/ 171da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 181da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#if !defined(_USBVEND_H) 191da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define _USBVEND_H 201da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 211da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds/************************************************************************ 221da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * 231da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * D e f i n e s / T y p e d e f s 241da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * 251da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds ************************************************************************/ 261da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 271da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 281da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Definitions of USB product IDs 29a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman// 301da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 311da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define USB_VENDOR_ID_ION 0x1608 // Our VID 321da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define USB_VENDOR_ID_TI 0x0451 // TI VID 336e8cf7751f9fb913095d6142d068f41fbf0424bbGreg Kroah-Hartman#define USB_VENDOR_ID_AXIOHM 0x05D9 /* Axiohm VID */ 341da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 351da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 361da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Definitions of USB product IDs (PID) 371da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// We break the USB-defined PID into an OEM Id field (upper 6 bits) 381da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// and a Device Id (bottom 10 bits). The Device Id defines what 391da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// device this actually is regardless of what the OEM wants to 401da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// call it. 411da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 421da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 431da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// ION-device OEM IDs 441da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_OEM_ID_ION 0 // 00h Inside Out Networks 451da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_OEM_ID_NLYNX 1 // 01h NLynx Systems 461da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_OEM_ID_GENERIC 2 // 02h Generic OEM 471da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_OEM_ID_MAC 3 // 03h Mac Version 481da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_OEM_ID_MEGAWOLF 4 // 04h Lupusb OEM Mac version (MegaWolf) 491da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_OEM_ID_MULTITECH 5 // 05h Multitech Rapidports 501da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_OEM_ID_AGILENT 6 // 06h AGILENT board 511da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 521da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 531da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// ION-device Device IDs 541da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Product IDs - assigned to match middle digit of serial number (No longer true) 551da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 561da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_80251_NETCHIP 0x020 // This bit is set in the PID if this edgeport hardware$ 57a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman // is based on the 80251+Netchip. 581da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 591da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_GENERATION_1 0x00 // Value for 930 based edgeports 601da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_GENERATION_2 0x01 // Value for 80251+Netchip. 611da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_GENERATION_3 0x02 // Value for Texas Instruments TUSB5052 chip 621da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_GENERATION_4 0x03 // Watchport Family of products 631da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_GENERATION_MASK 0x03 641da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 651da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_HUB_MASK 0x0080 // This bit in the PID designates a HUB device 661da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // for example 8C would be a 421 4 port hub 671da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // and 8D would be a 2 port embedded hub 681da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 691da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define EDGEPORT_DEVICE_ID_MASK 0x0ff // Not including OEM or GENERATION fields 701da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 711da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_UNCONFIGURED_EDGE_DEVICE 0x000 // In manufacturing only 721da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_4 0x001 // Edgeport/4 RS232 731da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_8R 0x002 // Edgeport with RJ45 no Ring 741da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_RAPIDPORT_4 0x003 // Rapidport/4 751da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_4T 0x004 // Edgeport/4 RS232 for Telxon (aka "Fleetport") 761da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_2 0x005 // Edgeport/2 RS232 771da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_4I 0x006 // Edgeport/4 RS422 781da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_2I 0x007 // Edgeport/2 RS422/RS485 791da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_8RR 0x008 // Edgeport with RJ45 with Data and RTS/CTS only 801da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// ION_DEVICE_ID_EDGEPORT_8_HANDBUILT 0x009 // Hand-built Edgeport/8 (Placeholder, used in middle digit of serial number only!) 811da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// ION_DEVICE_ID_MULTIMODEM_4X56 0x00A // MultiTech version of RP/4 (Placeholder, used in middle digit of serial number only!) 821da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_PARALLEL_PORT 0x00B // Edgeport/(4)21 Parallel port (USS720) 831da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_421 0x00C // Edgeport/421 Hub+RS232+Parallel 841da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_21 0x00D // Edgeport/21 RS232+Parallel 851da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_8_DUAL_CPU 0x00E // Half of an Edgeport/8 (the kind with 2 EP/4s on 1 PCB) 861da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_8 0x00F // Edgeport/8 (single-CPU) 871da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_2_DIN 0x010 // Edgeport/2 RS232 with Apple DIN connector 881da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_4_DIN 0x011 // Edgeport/4 RS232 with Apple DIN connector 891da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_16_DUAL_CPU 0x012 // Half of an Edgeport/16 (the kind with 2 EP/8s) 901da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_COMPATIBLE 0x013 // Edgeport Compatible, for NCR, Axiohm etc. testing 911da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_8I 0x014 // Edgeport/8 RS422 (single-CPU) 921da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_1 0x015 // Edgeport/1 RS232 931da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EPOS44 0x016 // Half of an EPOS/44 (TIUMP BASED) 941da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_42 0x017 // Edgeport/42 951da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_412_8 0x018 // Edgeport/412 8 port part 961da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_412_4 0x019 // Edgeport/412 4 port part 971da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_22I 0x01A // Edgeport/22I is an Edgeport/4 with ports 1&2 RS422 and ports 3&4 RS232 981da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 991da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Compact Form factor TI based devices 2c, 21c, 22c, 221c 1001da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_2C 0x01B // Edgeport/2c is a TI based Edgeport/2 - Small I2c 1011da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_221C 0x01C // Edgeport/221c is a TI based Edgeport/2 with lucent chip and 1021da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // 2 external hub ports - Large I2C 1031da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_22C 0x01D // Edgeport/22c is a TI based Edgeport/2 with 1041da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // 2 external hub ports - Large I2C 1051da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_21C 0x01E // Edgeport/21c is a TI based Edgeport/2 with lucent chip 1061da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // Small I2C 1071da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 1081da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 1091da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds/* 1101da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * DANGER DANGER The 0x20 bit was used to indicate a 8251/netchip GEN 2 device. 1111da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * Since the MAC, Linux, and Optimal drivers still used the old code 1121da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * I suggest that you skip the 0x20 bit when creating new PIDs 1131da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds */ 1141da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 1151da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 1161da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Generation 3 devices -- 3410 based edgport/1 (256 byte I2C) 1171da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_TI3410_EDGEPORT_1 0x040 // Edgeport/1 RS232 1181da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_TI3410_EDGEPORT_1I 0x041 // Edgeport/1i- RS422 model 1191da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 1201da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Ti based software switchable RS232/RS422/RS485 devices 1211da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_4S 0x042 // Edgeport/4s - software switchable model 1221da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_8S 0x043 // Edgeport/8s - software switchable model 1231da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 1241da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Usb to Ethernet dongle 1251da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_EDGEPORT_E 0x0E0 // Edgeport/E Usb to Ethernet 1261da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 1271da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Edgeport TI based devices 1281da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_TI_EDGEPORT_4 0x0201 // Edgeport/4 RS232 1291da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_TI_EDGEPORT_2 0x0205 // Edgeport/2 RS232 1301da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_TI_EDGEPORT_4I 0x0206 // Edgeport/4i RS422 1311da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_TI_EDGEPORT_2I 0x0207 // Edgeport/2i RS422/RS485 1321da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_TI_EDGEPORT_421 0x020C // Edgeport/421 4 hub 2 RS232 + Parallel (lucent on a different hub port) 1331da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_TI_EDGEPORT_21 0x020D // Edgeport/21 2 RS232 + Parallel (lucent on a different hub port) 134fc4cbd755b75c7687b923da5b75ba4a64652582eMartin K. Petersen#define ION_DEVICE_ID_TI_EDGEPORT_416 0x0212 // Edgeport/416 1351da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_TI_EDGEPORT_1 0x0215 // Edgeport/1 RS232 1361da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_TI_EDGEPORT_42 0x0217 // Edgeport/42 4 hub 2 RS232 137a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman#define ION_DEVICE_ID_TI_EDGEPORT_22I 0x021A // Edgeport/22I is an Edgeport/4 with ports 1&2 RS422 and ports 3&4 RS232 1381da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_TI_EDGEPORT_2C 0x021B // Edgeport/2c RS232 1391da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_TI_EDGEPORT_221C 0x021C // Edgeport/221c is a TI based Edgeport/2 with lucent chip and 1401da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // 2 external hub ports - Large I2C 1411da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_TI_EDGEPORT_22C 0x021D // Edgeport/22c is a TI based Edgeport/2 with 1421da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // 2 external hub ports - Large I2C 1431da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_TI_EDGEPORT_21C 0x021E // Edgeport/21c is a TI based Edgeport/2 with lucent chip 1441da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 145a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman// Generation 3 devices -- 3410 based edgport/1 (256 byte I2C) 146fc4cbd755b75c7687b923da5b75ba4a64652582eMartin K. Petersen#define ION_DEVICE_ID_TI_TI3410_EDGEPORT_1 0x0240 // Edgeport/1 RS232 147fc4cbd755b75c7687b923da5b75ba4a64652582eMartin K. Petersen#define ION_DEVICE_ID_TI_TI3410_EDGEPORT_1I 0x0241 // Edgeport/1i- RS422 model 1481da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 1491da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Ti based software switchable RS232/RS422/RS485 devices 150fc4cbd755b75c7687b923da5b75ba4a64652582eMartin K. Petersen#define ION_DEVICE_ID_TI_EDGEPORT_4S 0x0242 // Edgeport/4s - software switchable model 151fc4cbd755b75c7687b923da5b75ba4a64652582eMartin K. Petersen#define ION_DEVICE_ID_TI_EDGEPORT_8S 0x0243 // Edgeport/8s - software switchable model 152fc4cbd755b75c7687b923da5b75ba4a64652582eMartin K. Petersen#define ION_DEVICE_ID_TI_EDGEPORT_8 0x0244 // Edgeport/8 (single-CPU) 153fc4cbd755b75c7687b923da5b75ba4a64652582eMartin K. Petersen#define ION_DEVICE_ID_TI_EDGEPORT_416B 0x0247 // Edgeport/416 1541da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 1551da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 1561da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds/************************************************************************ 1571da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * 1581da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * Generation 4 devices 1591da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * 1601da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds ************************************************************************/ 1611da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 1621da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Watchport based on 3410 both 1-wire and binary products (16K I2C) 1631da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_WP_UNSERIALIZED 0x300 // Watchport based on 3410 both 1-wire and binary products 1641da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_WP_PROXIMITY 0x301 // Watchport/P Discontinued 1651da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_WP_MOTION 0x302 // Watchport/M 1661da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_WP_MOISTURE 0x303 // Watchport/W 1671da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_WP_TEMPERATURE 0x304 // Watchport/T 1681da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_WP_HUMIDITY 0x305 // Watchport/H 1691da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 1701da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_WP_POWER 0x306 // Watchport 1711da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_WP_LIGHT 0x307 // Watchport 1721da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_WP_RADIATION 0x308 // Watchport 1731da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_WP_ACCELERATION 0x309 // Watchport/A 1741da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_WP_DISTANCE 0x30A // Watchport/D Discontinued 1751da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_WP_PROX_DIST 0x30B // Watchport/D uses distance sensor 1761da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // Default to /P function 1771da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 1781da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_PLUS_PWR_HP4CD 0x30C // 5052 Plus Power HubPort/4CD+ (for Dell) 179a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman#define ION_DEVICE_ID_PLUS_PWR_HP4C 0x30D // 5052 Plus Power HubPort/4C+ 1801da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_PLUS_PWR_PCI 0x30E // 3410 Plus Power PCI Host Controller 4 port 1811da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 1821da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 1831da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 1841da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Definitions for AXIOHM USB product IDs 1851da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 1861da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define USB_VENDOR_ID_AXIOHM 0x05D9 // Axiohm VID 1871da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 1881da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define AXIOHM_DEVICE_ID_MASK 0xffff 1891da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define AXIOHM_DEVICE_ID_EPIC_A758 0xA758 1901da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define AXIOHM_DEVICE_ID_EPIC_A794 0xA794 1911da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define AXIOHM_DEVICE_ID_EPIC_A225 0xA225 1921da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 1931da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 1941da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 1951da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Definitions for NCR USB product IDs 1961da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 1971da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define USB_VENDOR_ID_NCR 0x0404 // NCR VID 1981da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 1991da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define NCR_DEVICE_ID_MASK 0xffff 2001da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define NCR_DEVICE_ID_EPIC_0202 0x0202 2011da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define NCR_DEVICE_ID_EPIC_0203 0x0203 2021da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define NCR_DEVICE_ID_EPIC_0310 0x0310 2031da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define NCR_DEVICE_ID_EPIC_0311 0x0311 2041da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define NCR_DEVICE_ID_EPIC_0312 0x0312 2051da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 2061da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 2071da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 2081da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Definitions for SYMBOL USB product IDs 2091da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 2101da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define USB_VENDOR_ID_SYMBOL 0x05E0 // Symbol VID 2111da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define SYMBOL_DEVICE_ID_MASK 0xffff 2121da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define SYMBOL_DEVICE_ID_KEYFOB 0x0700 2131da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 2141da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 2151da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 2161da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Definitions for other product IDs 2171da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define ION_DEVICE_ID_MT4X56USB 0x1403 // OEM device 2181da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 2191da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 220a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman#define GENERATION_ID_FROM_USB_PRODUCT_ID(ProductId) \ 221a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman ((__u16) ((ProductId >> 8) & (ION_GENERATION_MASK))) 2221da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 223a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman#define MAKE_USB_PRODUCT_ID(OemId, DeviceId) \ 224a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman ((__u16) (((OemId) << 10) || (DeviceId))) 2251da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 226a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman#define DEVICE_ID_FROM_USB_PRODUCT_ID(ProductId) \ 227a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman ((__u16) ((ProductId) & (EDGEPORT_DEVICE_ID_MASK))) 2281da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 229a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman#define OEM_ID_FROM_USB_PRODUCT_ID(ProductId) \ 230a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman ((__u16) (((ProductId) >> 10) & 0x3F)) 2311da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 2321da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 2331da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Definitions of parameters for download code. Note that these are 2341da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// specific to a given version of download code and must change if the 2351da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// corresponding download code changes. 2361da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 2371da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 2381da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// TxCredits value below which driver won't bother sending (to prevent too many small writes). 2391da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Send only if above 25% 240a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman#define EDGE_FW_GET_TX_CREDITS_SEND_THRESHOLD(InitialCredit, MaxPacketSize) (max(((InitialCredit) / 4), (MaxPacketSize))) 2411da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 2421da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define EDGE_FW_BULK_MAX_PACKET_SIZE 64 // Max Packet Size for Bulk In Endpoint (EP1) 2431da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define EDGE_FW_BULK_READ_BUFFER_SIZE 1024 // Size to use for Bulk reads 2441da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 2451da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define EDGE_FW_INT_MAX_PACKET_SIZE 32 // Max Packet Size for Interrupt In Endpoint 2461da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // Note that many units were shipped with MPS=16, we 2471da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // force an upgrade to this value). 2481da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define EDGE_FW_INT_INTERVAL 2 // 2ms polling on IntPipe 2491da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 2501da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 2511da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 2521da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Definitions of I/O Networks vendor-specific requests 2531da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// for default endpoint 2541da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 2551da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// bmRequestType = 01000000 Set vendor-specific, to device 2561da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// bmRequestType = 11000000 Get vendor-specific, to device 2571da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 2581da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// These are the definitions for the bRequest field for the 2591da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// above bmRequestTypes. 2601da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 2611da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// For the read/write Edgeport memory commands, the parameters 2621da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// are as follows: 2631da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// wValue = 16-bit address 2641da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// wIndex = unused (though we could put segment 00: or FF: here) 2651da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// wLength = # bytes to read/write (max 64) 266a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman// 2671da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 2681da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define USB_REQUEST_ION_RESET_DEVICE 0 // Warm reboot Edgeport, retaining USB address 2691da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define USB_REQUEST_ION_GET_EPIC_DESC 1 // Get Edgeport Compatibility Descriptor 2701da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// unused 2 // Unused, available 2711da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define USB_REQUEST_ION_READ_RAM 3 // Read EdgePort RAM at specified addr 2721da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define USB_REQUEST_ION_WRITE_RAM 4 // Write EdgePort RAM at specified addr 2731da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define USB_REQUEST_ION_READ_ROM 5 // Read EdgePort ROM at specified addr 2741da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define USB_REQUEST_ION_WRITE_ROM 6 // Write EdgePort ROM at specified addr 2751da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define USB_REQUEST_ION_EXEC_DL_CODE 7 // Begin execution of RAM-based download 2761da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // code by jumping to address in wIndex:wValue 2771da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 8 // Unused, available 2781da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define USB_REQUEST_ION_ENABLE_SUSPEND 9 // Enable/Disable suspend feature 2791da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // (wValue != 0: Enable; wValue = 0: Disable) 2801da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 281a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman#define USB_REQUEST_ION_SEND_IOSP 10 // Send an IOSP command to the edgeport over the control pipe 2821da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define USB_REQUEST_ION_RECV_IOSP 11 // Receive an IOSP command from the edgeport over the control pipe 2831da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 2841da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 2851da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define USB_REQUEST_ION_DIS_INT_TIMER 0x80 // Sent to Axiohm to enable/ disable 2861da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // interrupt token timer 2871da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // wValue = 1, enable (default) 2881da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // wValue = 0, disable 2891da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 2901da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 2911da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Define parameter values for our vendor-specific commands 2921da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 2931da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 2941da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 295093cf723b2b06d774929ea07982f6a466ff22314Steven Cole// Edgeport Compatibility Descriptor 2961da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 2971da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// This descriptor is only returned by Edgeport-compatible devices 2981da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// supporting the EPiC spec. True ION devices do not return this 2991da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// descriptor, but instead return STALL on receipt of the 3001da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// GET_EPIC_DESC command. The driver interprets a STALL to mean that 3011da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// this is a "real" Edgeport. 3021da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 3031da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 304a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartmanstruct edge_compatibility_bits { 3051da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // This __u32 defines which Vendor-specific commands/functionality 3061da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // the device supports on the default EP0 pipe. 3071da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 3081da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u32 VendEnableSuspend : 1; // 0001 Set if device supports ION_ENABLE_SUSPEND 3091da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u32 VendUnused : 31; // Available for future expansion, must be 0 3101da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 3111da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // This __u32 defines which IOSP commands are supported over the 3121da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // bulk pipe EP1. 3131da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 3141da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // xxxx Set if device supports: 3151da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u32 IOSPOpen : 1; // 0001 OPEN / OPEN_RSP (Currently must be 1) 3161da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u32 IOSPClose : 1; // 0002 CLOSE 3171da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u32 IOSPChase : 1; // 0004 CHASE / CHASE_RSP 3181da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u32 IOSPSetRxFlow : 1; // 0008 SET_RX_FLOW 3191da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u32 IOSPSetTxFlow : 1; // 0010 SET_TX_FLOW 3201da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u32 IOSPSetXChar : 1; // 0020 SET_XON_CHAR/SET_XOFF_CHAR 3211da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u32 IOSPRxCheck : 1; // 0040 RX_CHECK_REQ/RX_CHECK_RSP 3221da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u32 IOSPSetClrBreak : 1; // 0080 SET_BREAK/CLEAR_BREAK 3231da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u32 IOSPWriteMCR : 1; // 0100 MCR register writes (set/clr DTR/RTS) 3241da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u32 IOSPWriteLCR : 1; // 0200 LCR register writes (wordlen/stop/parity) 3251da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u32 IOSPSetBaudRate : 1; // 0400 setting Baud rate (writes to LCR.80h and DLL/DLM register) 3261da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u32 IOSPDisableIntPipe : 1; // 0800 Do not use the interrupt pipe for TxCredits or RxButesAvailable 3271da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u32 IOSPRxDataAvail : 1; // 1000 Return status of RX Fifo (Data available in Fifo) 3281da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u32 IOSPTxPurge : 1; // 2000 Purge TXBuffer and/or Fifo in Edgeport hardware 3291da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u32 IOSPUnused : 18; // Available for future expansion, must be 0 3301da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 3311da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // This __u32 defines which 'general' features are supported 3321da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 3331da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u32 TrueEdgeport : 1; // 0001 Set if device is a 'real' Edgeport 3341da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // (Used only by driver, NEVER set by an EPiC device) 3351da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u32 GenUnused : 31; // Available for future expansion, must be 0 3361da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds}; 3371da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 3386e8cf7751f9fb913095d6142d068f41fbf0424bbGreg Kroah-Hartman#define EDGE_COMPATIBILITY_MASK0 0x0001 3396e8cf7751f9fb913095d6142d068f41fbf0424bbGreg Kroah-Hartman#define EDGE_COMPATIBILITY_MASK1 0x3FFF 3406e8cf7751f9fb913095d6142d068f41fbf0424bbGreg Kroah-Hartman#define EDGE_COMPATIBILITY_MASK2 0x0001 3416e8cf7751f9fb913095d6142d068f41fbf0424bbGreg Kroah-Hartman 342a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartmanstruct edge_compatibility_descriptor { 3431da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 Length; // Descriptor Length (per USB spec) 3441da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 DescType; // Descriptor Type (per USB spec, =DEVICE type) 3451da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 EpicVer; // Version of EPiC spec supported 346a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman // (Currently must be 1) 3471da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 NumPorts; // Number of serial ports supported 3481da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 iDownloadFile; // Index of string containing download code filename 349a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman // 0=no download, FF=download compiled into driver. 350a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman __u8 Unused[3]; // Available for future expansion, must be 0 351a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman // (Currently must be 0). 3521da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 MajorVersion; // Firmware version: xx. 3531da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 MinorVersion; // yy. 3541da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __le16 BuildNumber; // zzzz (LE format) 3551da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 3561da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // The following structure contains __u32s, with each bit 3571da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // specifying whether the EPiC device supports the given 3581da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // command or functionality. 3591da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds struct edge_compatibility_bits Supports; 3601da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds}; 3611da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 3621da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Values for iDownloadFile 3631da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define EDGE_DOWNLOAD_FILE_NONE 0 // No download requested 3641da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define EDGE_DOWNLOAD_FILE_INTERNAL 0xFF // Download the file compiled into driver (930 version) 3651da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define EDGE_DOWNLOAD_FILE_I930 0xFF // Download the file compiled into driver (930 version) 3661da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define EDGE_DOWNLOAD_FILE_80251 0xFE // Download the file compiled into driver (80251 version) 3671da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 3681da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 3691da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 3701da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds/* 3711da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * Special addresses for READ/WRITE_RAM/ROM 3721da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds */ 3731da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 3741da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Version 1 (original) format of DeviceParams 3751da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define EDGE_MANUF_DESC_ADDR_V1 0x00FF7F00 3761da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define EDGE_MANUF_DESC_LEN_V1 sizeof(EDGE_MANUF_DESCRIPTOR_V1) 3771da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 3781da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Version 2 format of DeviceParams. This format is longer (3C0h) 3791da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// and starts lower in memory, at the uppermost 1K in ROM. 3801da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define EDGE_MANUF_DESC_ADDR 0x00FF7C00 3811da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define EDGE_MANUF_DESC_LEN sizeof(struct edge_manuf_descriptor) 3821da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 3831da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Boot params descriptor 3841da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define EDGE_BOOT_DESC_ADDR 0x00FF7FC0 3851da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define EDGE_BOOT_DESC_LEN sizeof(struct edge_boot_descriptor) 3861da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 3871da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Define the max block size that may be read or written 3881da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// in a read/write RAM/ROM command. 389a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman#define MAX_SIZE_REQ_ION_READ_MEM ((__u16)64) 390a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman#define MAX_SIZE_REQ_ION_WRITE_MEM ((__u16)64) 3911da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 3921da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 3931da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 3941da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Notes for the following two ION vendor-specific param descriptors: 3951da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 3961da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 1. These have a standard USB descriptor header so they look like a 3971da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// normal descriptor. 3981da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 2. Any strings in the structures are in USB-defined string 3991da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// descriptor format, so that they may be separately retrieved, 4001da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// if necessary, with a minimum of work on the 930. This also 4011da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// requires them to be in UNICODE format, which, for English at 4021da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// least, simply means extending each __u8 into a __u16. 4031da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 3. For all fields, 00 means 'uninitialized'. 4041da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 4. All unused areas should be set to 00 for future expansion. 4051da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 4061da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4071da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// This structure is ver 2 format. It contains ALL USB descriptors as 4081da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// well as the configuration parameters that were in the original V1 4091da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// structure. It is NOT modified when new boot code is downloaded; rather, 4101da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// these values are set or modified by manufacturing. It is located at 4111da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// xC00-xFBF (length 3C0h) in the ROM. 4121da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// This structure is a superset of the v1 structure and is arranged so 4131da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// that all of the v1 fields remain at the same address. We are just 4141da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// adding more room to the front of the structure to hold the descriptors. 4151da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 4161da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// The actual contents of this structure are defined in a 930 assembly 4171da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// file, converted to a binary image, and then written by the serialization 4181da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// program. The C definition of this structure just defines a dummy 4191da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// area for general USB descriptors and the descriptor tables (the root 4201da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// descriptor starts at xC00). At the bottom of the structure are the 4211da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// fields inherited from the v1 structure. 4221da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4231da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MAX_SERIALNUMBER_LEN 12 4241da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MAX_ASSEMBLYNUMBER_LEN 14 4251da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4261da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvaldsstruct edge_manuf_descriptor { 4271da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4281da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u16 RootDescTable[0x10]; // C00 Root of descriptor tables (just a placeholder) 4291da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 DescriptorArea[0x2E0]; // C20 Descriptors go here, up to 2E0h (just a placeholder) 4301da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4311da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // Start of v1-compatible section 4321da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 Length; // F00 Desc length for what follows, per USB (= C0h ) 4331da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 DescType; // F01 Desc type, per USB (=DEVICE type) 4341da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 DescVer; // F02 Desc version/format (currently 2) 4351da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 NumRootDescEntries; // F03 # entries in RootDescTable 4361da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4371da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 RomSize; // F04 Size of ROM/E2PROM in K 4381da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 RamSize; // F05 Size of external RAM in K 4391da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 CpuRev; // F06 CPU revision level (chg only if s/w visible) 4401da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 BoardRev; // F07 PCB revision level (chg only if s/w visible) 4411da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4421da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 NumPorts; // F08 Number of ports 4431da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 DescDate[3]; // F09 MM/DD/YY when descriptor template was compiler, 4441da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // so host can track changes to USB-only descriptors. 4451da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4461da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 SerNumLength; // F0C USB string descriptor len 4471da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 SerNumDescType; // F0D USB descriptor type (=STRING type) 4481da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __le16 SerialNumber[MAX_SERIALNUMBER_LEN]; // F0E "01-01-000100" Unicode Serial Number 4491da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4501da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 AssemblyNumLength; // F26 USB string descriptor len 4511da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 AssemblyNumDescType; // F27 USB descriptor type (=STRING type) 4521da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __le16 AssemblyNumber[MAX_ASSEMBLYNUMBER_LEN]; // F28 "350-1000-01-A " assembly number 4531da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4541da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 OemAssyNumLength; // F44 USB string descriptor len 4551da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 OemAssyNumDescType; // F45 USB descriptor type (=STRING type) 4561da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __le16 OemAssyNumber[MAX_ASSEMBLYNUMBER_LEN]; // F46 "xxxxxxxxxxxxxx" OEM assembly number 4571da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4581da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 ManufDateLength; // F62 USB string descriptor len 4591da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 ManufDateDescType; // F63 USB descriptor type (=STRING type) 4601da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __le16 ManufDate[6]; // F64 "MMDDYY" manufacturing date 4611da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4621da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 Reserved3[0x4D]; // F70 -- unused, set to 0 -- 4631da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4641da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 UartType; // FBD Uart Type 4651da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 IonPid; // FBE Product ID, == LSB of USB DevDesc.PID 4661da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // (Note: Edgeport/4s before 11/98 will have 4671da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // 00 here instead of 01) 4681da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 IonConfig; // FBF Config byte for ION manufacturing use 4691da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // FBF end of structure, total len = 3C0h 4701da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4711da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds}; 4721da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4731da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4741da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_DESC_VER_1 1 // Original definition of MANUF_DESC 4751da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_DESC_VER_2 2 // Ver 2, starts at xC00h len 3C0h 4761da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4771da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4781da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Uart Types 4791da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Note: Since this field was added only recently, all Edgeport/4 units 4801da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// shipped before 11/98 will have 00 in this field. Therefore, 4811da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// both 00 and 01 values mean '654. 4821da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_UART_EXAR_654_EARLY 0 // Exar 16C654 in Edgeport/4s before 11/98 4831da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_UART_EXAR_654 1 // Exar 16C654 4841da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_UART_EXAR_2852 2 // Exar 16C2852 4851da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4861da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 4871da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Note: The CpuRev and BoardRev values do not conform to manufacturing 4881da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// revisions; they are to be incremented only when the CPU or hardware 4891da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// changes in a software-visible way, such that the 930 software or 4901da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// the host driver needs to handle the hardware differently. 4911da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 4921da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4931da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Values of bottom 5 bits of CpuRev & BoardRev for 4941da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Implementation 0 (ie, 930-based) 4951da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_CPU_REV_AD4 1 // 930 AD4, with EP1 Rx bug (needs RXSPM) 4961da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_CPU_REV_AD5 2 // 930 AD5, with above bug (supposedly) fixed 4971da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_CPU_80251 0x20 // Intel 80251 4981da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 4991da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5001da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_BOARD_REV_A 1 // Original version, == Manuf Rev A 5011da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_BOARD_REV_B 2 // Manuf Rev B, wakeup interrupt works 5021da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_BOARD_REV_C 3 // Manuf Rev C, 2/4 ports, rs232/rs422 5031da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_BOARD_REV_GENERATION_2 0x20 // Second generaiton edgeport 5041da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5051da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5061da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Values of bottom 5 bits of CpuRev & BoardRev for 5071da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Implementation 1 (ie, 251+Netchip-based) 5081da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_CPU_REV_1 1 // C251TB Rev 1 (Need actual Intel rev here) 5091da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5101da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_BOARD_REV_A 1 // First rev of 251+Netchip design 5111da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5121da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_SERNUM_LENGTH sizeof(((struct edge_manuf_descriptor *)0)->SerialNumber) 5131da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_ASSYNUM_LENGTH sizeof(((struct edge_manuf_descriptor *)0)->AssemblyNumber) 5141da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_OEMASSYNUM_LENGTH sizeof(((struct edge_manuf_descriptor *)0)->OemAssyNumber) 5151da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_MANUFDATE_LENGTH sizeof(((struct edge_manuf_descriptor *)0)->ManufDate) 5161da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5171da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_ION_CONFIG_DIAG_NO_LOOP 0x20 // As below but no ext loopback test 5181da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_ION_CONFIG_DIAG 0x40 // 930 based device: 1=Run h/w diags, 0=norm 5191da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // TIUMP Device : 1=IONSERIAL needs to run Final Test 5201da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define MANUF_ION_CONFIG_MASTER 0x80 // 930 based device: 1=Master mode, 0=Normal 5211da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // TIUMP Device : 1=First device on a multi TIUMP Device 5221da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5231da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 5241da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// This structure describes parameters for the boot code, and 5251da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// is programmed along with new boot code. These are values 5261da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// which are specific to a given build of the boot code. It 5271da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// is exactly 64 bytes long and is fixed at address FF:xFC0 5281da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// - FF:xFFF. Note that the 930-mandated UCONFIG bytes are 5291da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// included in this structure. 5301da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// 5311da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvaldsstruct edge_boot_descriptor { 5321da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 Length; // C0 Desc length, per USB (= 40h) 5331da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 DescType; // C1 Desc type, per USB (= DEVICE type) 5341da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 DescVer; // C2 Desc version/format 5351da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 Reserved1; // C3 -- unused, set to 0 -- 5361da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5371da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __le16 BootCodeLength; // C4 Boot code goes from FF:0000 to FF:(len-1) 5381da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // (LE format) 5391da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5401da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 MajorVersion; // C6 Firmware version: xx. 5411da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 MinorVersion; // C7 yy. 5421da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __le16 BuildNumber; // C8 zzzz (LE format) 543a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman 5441da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u16 EnumRootDescTable; // CA Root of ROM-based descriptor table 5451da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 NumDescTypes; // CC Number of supported descriptor types 5461da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5471da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 Reserved4; // CD Fix Compiler Packing 5481da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5491da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __le16 Capabilities; // CE-CF Capabilities flags (LE format) 5501da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 Reserved2[0x28]; // D0 -- unused, set to 0 -- 5511da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 UConfig0; // F8 930-defined CPU configuration byte 0 5521da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 UConfig1; // F9 930-defined CPU configuration byte 1 5531da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 Reserved3[6]; // FA -- unused, set to 0 -- 5541da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // FF end of structure, total len = 80 5551da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds}; 5561da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5571da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5581da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define BOOT_DESC_VER_1 1 // Original definition of BOOT_PARAMS 5591da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define BOOT_DESC_VER_2 2 // 2nd definition, descriptors not included in boot 5601da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5611da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5621da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // Capabilities flags 5631da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5641da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define BOOT_CAP_RESET_CMD 0x0001 // If set, boot correctly supports ION_RESET_DEVICE 5651da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5661da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5671da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds/************************************************************************ 5681da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds T I U M P D E F I N I T I O N S 5691da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds ***********************************************************************/ 5701da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5711da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Chip definitions in I2C 5721da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define UMP5152 0x52 5731da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define UMP3410 0x10 5741da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5751da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5761da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds//************************************************************************ 5771da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// TI I2C Format Definitions 5781da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds//************************************************************************ 5791da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define I2C_DESC_TYPE_INFO_BASIC 0x01 5801da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define I2C_DESC_TYPE_FIRMWARE_BASIC 0x02 5811da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define I2C_DESC_TYPE_DEVICE 0x03 5821da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define I2C_DESC_TYPE_CONFIG 0x04 5831da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define I2C_DESC_TYPE_STRING 0x05 5841da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define I2C_DESC_TYPE_FIRMWARE_AUTO 0x07 // for 3410 download 5851da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define I2C_DESC_TYPE_CONFIG_KLUDGE 0x14 // for 3410 5861da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define I2C_DESC_TYPE_WATCHPORT_VERSION 0x15 // firmware version number for watchport 5871da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define I2C_DESC_TYPE_WATCHPORT_CALIBRATION_DATA 0x16 // Watchport Calibration Data 5881da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5891da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define I2C_DESC_TYPE_FIRMWARE_BLANK 0xf2 5901da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5911da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Special section defined by ION 5921da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define I2C_DESC_TYPE_ION 0 // Not defined by TI 5931da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 5941da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 595a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartmanstruct ti_i2c_desc { 5961da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 Type; // Type of descriptor 5971da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u16 Size; // Size of data only not including header 5981da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 CheckSum; // Checksum (8 bit sum of data only) 5991da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 Data[0]; // Data starts here 600a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman} __attribute__((packed)); 6011da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 6021da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// for 5152 devices only (type 2 record) 6031da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// for 3410 the version is stored in the WATCHPORT_FIRMWARE_VERSION descriptor 604a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartmanstruct ti_i2c_firmware_rec { 6051da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 Ver_Major; // Firmware Major version number 6061da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 Ver_Minor; // Firmware Minor version number 6071da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 Data[0]; // Download starts here 608a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman} __attribute__((packed)); 6091da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 6101da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 611a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartmanstruct watchport_firmware_version { 6121da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Added 2 bytes for version number 6131da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 Version_Major; // Download Version (for Watchport) 6141da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 Version_Minor; 615a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman} __attribute__((packed)); 6161da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 6171da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 6181da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// Structure of header of download image in fw_down.h 619a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartmanstruct ti_i2c_image_header { 6201da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __le16 Length; 6211da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 CheckSum; 622a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman} __attribute__((packed)); 6231da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 624a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartmanstruct ti_basic_descriptor { 6251da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 Power; // Self powered 6261da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // bit 7: 1 - power switching supported 6271da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // 0 - power switching not supported 6281da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // 6291da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // bit 0: 1 - self powered 6301da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // 0 - bus powered 6311da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // 6321da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds // 6331da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u16 HubVid; // VID HUB 6341da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u16 HubPid; // PID HUB 6351da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u16 DevPid; // PID Edgeport 6361da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 HubTime; // Time for power on to power good 6371da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 HubCurrent; // HUB Current = 100ma 6381da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds} __attribute__((packed)); 6391da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 6401da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 6411da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// CPU / Board Rev Definitions 6421da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define TI_CPU_REV_5052 2 // 5052 based edgeports 6431da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define TI_CPU_REV_3410 3 // 3410 based edgeports 6441da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 6451da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define TI_BOARD_REV_TI_EP 0 // Basic ti based edgeport 6461da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define TI_BOARD_REV_COMPACT 1 // Compact board 6471da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define TI_BOARD_REV_WATCHPORT 2 // Watchport 6481da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 6491da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 6501da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define TI_GET_CPU_REVISION(x) (__u8)((((x)>>4)&0x0f)) 6511da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define TI_GET_BOARD_REVISION(x) (__u8)(((x)&0x0f)) 6521da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 6531da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define TI_I2C_SIZE_MASK 0x1f // 5 bits 6541da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define TI_GET_I2C_SIZE(x) ((((x) & TI_I2C_SIZE_MASK)+1)*256) 6551da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 656a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman#define TI_MAX_I2C_SIZE (16 * 1024) 6571da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 658a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman#define TI_MANUF_VERSION_0 0 6591da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 6601da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds// IonConig2 flags 6611da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define TI_CONFIG2_RS232 0x01 6621da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define TI_CONFIG2_RS422 0x02 6631da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define TI_CONFIG2_RS485 0x04 6641da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define TI_CONFIG2_SWITCHABLE 0x08 6651da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 6661da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define TI_CONFIG2_WATCHPORT 0x10 6671da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 6681da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 669a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartmanstruct edge_ti_manuf_descriptor { 6701da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 IonConfig; // Config byte for ION manufacturing use 6711da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 IonConfig2; // Expansion 6721da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 Version; // Version 6731da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 CpuRev_BoardRev; // CPU revision level (0xF0) and Board Rev Level (0x0F) 6741da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 NumPorts; // Number of ports for this UMP 6751da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 NumVirtualPorts; // Number of Virtual ports 6761da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 HubConfig1; // Used to configure the Hub 6771da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 HubConfig2; // Used to configure the Hub 6781da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 TotalPorts; // Total Number of Com Ports for the entire device (All UMPs) 6791da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds __u8 Reserved; // Reserved 680a320471147fe61ed9260295958f07cc23ec360c8Greg Kroah-Hartman} __attribute__((packed)); 6811da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 6821da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds 6831da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#endif // if !defined(_USBVEND_H) 684