1
0
Files
kernel-49/drivers/usb/serial/io_usbvend.h
Eric Biggers cb74d5c7ab Merge 4.9.320 into android-4.9-q
Changes in 4.9.320
	9p: missing chunk of "fs/9p: Don't update file type when updating file attributes"
	random: remove stale maybe_reseed_primary_crng
	random: remove stale urandom_init_wait
	random: remove variable limit
	random: fix comment for unused random_min_urandom_seed
	random: convert get_random_int/long into get_random_u32/u64
	random: move random_min_urandom_seed into CONFIG_SYSCTL ifdef block
	random: invalidate batched entropy after crng init
	random: silence compiler warnings and fix race
	random: add wait_for_random_bytes() API
	random: add get_random_{bytes,u32,u64,int,long,once}_wait family
	random: warn when kernel uses unseeded randomness
	random: do not ignore early device randomness
	random: suppress spammy warnings about unseeded randomness
	random: reorder READ_ONCE() in get_random_uXX
	random: fix warning message on ia64 and parisc
	random: use a different mixing algorithm for add_device_randomness()
	random: set up the NUMA crng instances after the CRNG is fully initialized
	random: fix possible sleeping allocation from irq context
	random: rate limit unseeded randomness warnings
	random: add a spinlock_t to struct batched_entropy
	char/random: silence a lockdep splat with printk()
	Revert "char/random: silence a lockdep splat with printk()"
	random: always use batched entropy for get_random_u{32,64}
	random: fix data race on crng_node_pool
	crypto: chacha20 - Fix keystream alignment for chacha20_block()
	random: always fill buffer in get_random_bytes_wait
	random: optimize add_interrupt_randomness
	drivers/char/random.c: remove unused dont_count_entropy
	random: Fix whitespace pre random-bytes work
	random: Return nbytes filled from hw RNG
	random: add a config option to trust the CPU's hwrng
	random: remove preempt disabled region
	random: Make crng state queryable
	random: make CPU trust a boot parameter
	drivers/char/random.c: constify poolinfo_table
	drivers/char/random.c: remove unused stuct poolinfo::poolbits
	drivers/char/random.c: make primary_crng static
	random: only read from /dev/random after its pool has received 128 bits
	random: move rand_initialize() earlier
	random: document get_random_int() family
	latent_entropy: avoid build error when plugin cflags are not set
	random: fix soft lockup when trying to read from an uninitialized blocking pool
	random: Support freezable kthreads in add_hwgenerator_randomness()
	fdt: add support for rng-seed
	random: Use wait_event_freezable() in add_hwgenerator_randomness()
	char/random: Add a newline at the end of the file
	Revert "hwrng: core - Freeze khwrng thread during suspend"
	crypto: Deduplicate le32_to_cpu_array() and cpu_to_le32_array()
	crypto: blake2s - generic C library implementation and selftest
	lib/crypto: blake2s: move hmac construction into wireguard
	lib/crypto: sha1: re-roll loops to reduce code size
	random: Don't wake crng_init_wait when crng_init == 1
	random: Add a urandom_read_nowait() for random APIs that don't warn
	random: add GRND_INSECURE to return best-effort non-cryptographic bytes
	random: ignore GRND_RANDOM in getentropy(2)
	random: make /dev/random be almost like /dev/urandom
	random: fix crash on multiple early calls to add_bootloader_randomness()
	random: remove the blocking pool
	random: delete code to pull data into pools
	random: remove kernel.random.read_wakeup_threshold
	random: remove unnecessary unlikely()
	random: convert to ENTROPY_BITS for better code readability
	random: Add and use pr_fmt()
	random: fix typo in add_timer_randomness()
	random: remove some dead code of poolinfo
	random: split primary/secondary crng init paths
	random: avoid warnings for !CONFIG_NUMA builds
	x86: Remove arch_has_random, arch_has_random_seed
	powerpc: Remove arch_has_random, arch_has_random_seed
	linux/random.h: Remove arch_has_random, arch_has_random_seed
	linux/random.h: Use false with bool
	linux/random.h: Mark CONFIG_ARCH_RANDOM functions __must_check
	powerpc: Use bool in archrandom.h
	random: add arch_get_random_*long_early()
	random: avoid arch_get_random_seed_long() when collecting IRQ randomness
	random: remove dead code left over from blocking pool
	MAINTAINERS: co-maintain random.c
	crypto: blake2s - include <linux/bug.h> instead of <asm/bug.h>
	crypto: blake2s - adjust include guard naming
	random: document add_hwgenerator_randomness() with other input functions
	random: remove unused irq_flags argument from add_interrupt_randomness()
	random: use BLAKE2s instead of SHA1 in extraction
	random: do not sign extend bytes for rotation when mixing
	random: do not re-init if crng_reseed completes before primary init
	random: mix bootloader randomness into pool
	random: harmonize "crng init done" messages
	random: use IS_ENABLED(CONFIG_NUMA) instead of ifdefs
	random: initialize ChaCha20 constants with correct endianness
	random: early initialization of ChaCha constants
	random: avoid superfluous call to RDRAND in CRNG extraction
	random: don't reset crng_init_cnt on urandom_read()
	random: fix typo in comments
	random: cleanup poolinfo abstraction
	crypto: chacha20 - Fix chacha20_block() keystream alignment (again)
	random: cleanup integer types
	random: remove incomplete last_data logic
	random: remove unused extract_entropy() reserved argument
	random: try to actively add entropy rather than passively wait for it
	random: rather than entropy_store abstraction, use global
	random: remove unused OUTPUT_POOL constants
	random: de-duplicate INPUT_POOL constants
	random: prepend remaining pool constants with POOL_
	random: cleanup fractional entropy shift constants
	random: access input_pool_data directly rather than through pointer
	random: simplify arithmetic function flow in account()
	random: continually use hwgenerator randomness
	random: access primary_pool directly rather than through pointer
	random: only call crng_finalize_init() for primary_crng
	random: use computational hash for entropy extraction
	random: simplify entropy debiting
	random: use linear min-entropy accumulation crediting
	random: always wake up entropy writers after extraction
	random: make credit_entropy_bits() always safe
	random: remove use_input_pool parameter from crng_reseed()
	random: remove batched entropy locking
	random: fix locking in crng_fast_load()
	random: use RDSEED instead of RDRAND in entropy extraction
	random: inline leaves of rand_initialize()
	random: ensure early RDSEED goes through mixer on init
	random: do not xor RDRAND when writing into /dev/random
	random: absorb fast pool into input pool after fast load
	random: use hash function for crng_slow_load()
	random: remove outdated INT_MAX >> 6 check in urandom_read()
	random: zero buffer after reading entropy from userspace
	random: tie batched entropy generation to base_crng generation
	random: remove ifdef'd out interrupt bench
	random: remove unused tracepoints
	random: add proper SPDX header
	random: deobfuscate irq u32/u64 contributions
	random: introduce drain_entropy() helper to declutter crng_reseed()
	random: remove useless header comment
	random: remove whitespace and reorder includes
	random: group initialization wait functions
	random: group entropy extraction functions
	random: group entropy collection functions
	random: group userspace read/write functions
	random: group sysctl functions
	random: rewrite header introductory comment
	workqueue: make workqueue available early during boot
	random: defer fast pool mixing to worker
	random: do not take pool spinlock at boot
	random: unify early init crng load accounting
	random: check for crng_init == 0 in add_device_randomness()
	hwrng: core - do not use multiple blank lines
	hwrng: core - rewrite better comparison to NULL
	hwrng: core - Rewrite the header
	hwrng: core - Move hwrng miscdev minor number to include/linux/miscdevice.h
	hwrng: core - remove unused PFX macro
	hwrng: use rng source with best quality
	hwrng: remember rng chosen by user
	random: pull add_hwgenerator_randomness() declaration into random.h
	random: clear fast pool, crng, and batches in cpuhp bring up
	random: round-robin registers as ulong, not u32
	random: only wake up writers after zap if threshold was passed
	random: cleanup UUID handling
	random: unify cycles_t and jiffies usage and types
	random: do crng pre-init loading in worker rather than irq
	random: give sysctl_random_min_urandom_seed a more sensible value
	random: don't let 644 read-only sysctls be written to
	random: replace custom notifier chain with standard one
	random: use SipHash as interrupt entropy accumulator
	random: make consistent usage of crng_ready()
	random: reseed more often immediately after booting
	random: check for signal and try earlier when generating entropy
	random: skip fast_init if hwrng provides large chunk of entropy
	random: treat bootloader trust toggle the same way as cpu trust toggle
	random: re-add removed comment about get_random_{u32,u64} reseeding
	random: mix build-time latent entropy into pool at init
	random: do not split fast init input in add_hwgenerator_randomness()
	random: do not allow user to keep crng key around on stack
	random: check for signal_pending() outside of need_resched() check
	random: check for signals every PAGE_SIZE chunk of /dev/[u]random
	random: make random_get_entropy() return an unsigned long
	random: document crng_fast_key_erasure() destination possibility
	random: fix sysctl documentation nits
	init: call time_init() before rand_initialize()
	ia64: define get_cycles macro for arch-override
	s390: define get_cycles macro for arch-override
	parisc: define get_cycles macro for arch-override
	alpha: define get_cycles macro for arch-override
	powerpc: define get_cycles macro for arch-override
	timekeeping: Add raw clock fallback for random_get_entropy()
	m68k: use fallback for random_get_entropy() instead of zero
	mips: use fallback for random_get_entropy() instead of just c0 random
	arm: use fallback for random_get_entropy() instead of zero
	nios2: use fallback for random_get_entropy() instead of zero
	x86/tsc: Use fallback for random_get_entropy() instead of zero
	um: use fallback for random_get_entropy() instead of zero
	sparc: use fallback for random_get_entropy() instead of zero
	xtensa: use fallback for random_get_entropy() instead of zero
	uapi: rename ext2_swab() to swab() and share globally in swab.h
	random: insist on random_get_entropy() existing in order to simplify
	random: do not use batches when !crng_ready()
	random: do not pretend to handle premature next security model
	random: order timer entropy functions below interrupt functions
	random: do not use input pool from hard IRQs
	random: help compiler out with fast_mix() by using simpler arguments
	siphash: use one source of truth for siphash permutations
	random: use symbolic constants for crng_init states
	random: avoid initializing twice in credit race
	random: remove ratelimiting for in-kernel unseeded randomness
	random: use proper jiffies comparison macro
	random: handle latent entropy and command line from random_init()
	random: credit architectural init the exact amount
	random: use static branch for crng_ready()
	random: remove extern from functions in header
	random: use proper return types on get_random_{int,long}_wait()
	random: move initialization functions out of hot pages
	random: move randomize_page() into mm where it belongs
	random: convert to using fops->write_iter()
	random: wire up fops->splice_{read,write}_iter()
	random: check for signals after page of pool writes
	Revert "random: use static branch for crng_ready()"
	crypto: drbg - add FIPS 140-2 CTRNG for noise source
	crypto: drbg - always seeded with SP800-90B compliant noise source
	crypto: drbg - prepare for more fine-grained tracking of seeding state
	crypto: drbg - track whether DRBG was seeded with !rng_is_initialized()
	crypto: drbg - move dynamic ->reseed_threshold adjustments to __drbg_seed()
	crypto: drbg - always try to free Jitter RNG instance
	crypto: drbg - make reseeding from get_random_bytes() synchronous
	random: avoid checking crng_ready() twice in random_init()
	random: mark bootloader randomness code as __init
	random: account for arch randomness in bits
	ASoC: cs42l52: Fix TLV scales for mixer controls
	ASoC: cs53l30: Correct number of volume levels on SX controls
	ASoC: cs42l52: Correct TLV for Bypass Volume
	ASoC: cs42l56: Correct typo in minimum level for SX volume controls
	ata: libata-core: fix NULL pointer deref in ata_host_alloc_pinfo()
	ASoC: wm8962: Fix suspend while playing music
	scsi: vmw_pvscsi: Expand vcpuHint to 16 bits
	scsi: lpfc: Fix port stuck in bypassed state after LIP in PT2PT topology
	virtio-mmio: fix missing put_device() when vm_cmdline_parent registration failed
	nfc: nfcmrvl: Fix memory leak in nfcmrvl_play_deferred
	ipv6: Fix signed integer overflow in l2tp_ip6_sendmsg
	net: ethernet: mtk_eth_soc: fix misuse of mem alloc interface netdev[napi]_alloc_frag
	random: credit cpu and bootloader seeds by default
	pNFS: Don't keep retrying if the server replied NFS4ERR_LAYOUTUNAVAILABLE
	misc: atmel-ssc: Fix IRQ check in ssc_probe
	irqchip/gic/realview: Fix refcount leak in realview_gic_of_init
	irqchip/gic-v3: Iterate over possible CPUs by for_each_possible_cpu()
	comedi: vmk80xx: fix expression for tx buffer size
	USB: serial: option: add support for Cinterion MV31 with new baseline
	USB: serial: io_ti: add Agilent E5805A support
	usb: gadget: lpc32xx_udc: Fix refcount leak in lpc32xx_udc_probe
	serial: 8250: Store to lsr_save_flags after lsr read
	ext4: fix bug_on ext4_mb_use_inode_pa
	ext4: make variable "count" signed
	ext4: add reserved GDT blocks check
	l2tp: don't use inet_shutdown on ppp session destroy
	l2tp: fix race in pppol2tp_release with session object destroy
	s390/mm: use non-quiescing sske for KVM switch to keyed guest
	xprtrdma: fix incorrect header size calculations
	swiotlb: fix info leak with DMA_FROM_DEVICE
	Reinstate some of "swiotlb: rework "fix info leak with DMA_FROM_DEVICE""
	fuse: fix pipe buffer lifetime for direct_io
	tcp: change source port randomizarion at connect() time
	tcp: add some entropy in __inet_hash_connect()
	secure_seq: use the 64 bits of the siphash for port offset calculation
	tcp: use different parts of the port_offset for index and offset
	tcp: add small random increments to the source port
	tcp: dynamically allocate the perturb table used by source ports
	tcp: increase source port perturb table to 2^16
	tcp: drop the hash_32() part from the index calculation
	Linux 4.9.320

Conflicts:
	crypto/chacha20_generic.c
	drivers/char/random.c
	drivers/of/fdt.c
	include/crypto/chacha20.h
	lib/chacha20.c

Merge resolution notes:
  - Added CHACHA20_KEY_SIZE and CHACHA20_BLOCK_SIZE constants to
    chacha.h, to minimize changes from the 4.9.320 version of random.c

  - Updated lib/vsprintf.c for
    "random: replace custom notifier chain with standard one".

Change-Id: Ia7a12d8883b808f88bbe807d6150552bb084f6b3
Signed-off-by: Eric Biggers <ebiggers@google.com>
2022-07-04 10:26:10 +03:00

685 lines
28 KiB
C

/************************************************************************
*
* USBVEND.H Vendor-specific USB definitions
*
* NOTE: This must be kept in sync with the Edgeport firmware and
* must be kept backward-compatible with older firmware.
*
************************************************************************
*
* Copyright (C) 1998 Inside Out Networks, Inc.
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
************************************************************************/
#if !defined(_USBVEND_H)
#define _USBVEND_H
/************************************************************************
*
* D e f i n e s / T y p e d e f s
*
************************************************************************/
//
// Definitions of USB product IDs
//
#define USB_VENDOR_ID_ION 0x1608 // Our VID
#define USB_VENDOR_ID_TI 0x0451 // TI VID
#define USB_VENDOR_ID_AXIOHM 0x05D9 /* Axiohm VID */
//
// Definitions of USB product IDs (PID)
// We break the USB-defined PID into an OEM Id field (upper 6 bits)
// and a Device Id (bottom 10 bits). The Device Id defines what
// device this actually is regardless of what the OEM wants to
// call it.
//
// ION-device OEM IDs
#define ION_OEM_ID_ION 0 // 00h Inside Out Networks
#define ION_OEM_ID_NLYNX 1 // 01h NLynx Systems
#define ION_OEM_ID_GENERIC 2 // 02h Generic OEM
#define ION_OEM_ID_MAC 3 // 03h Mac Version
#define ION_OEM_ID_MEGAWOLF 4 // 04h Lupusb OEM Mac version (MegaWolf)
#define ION_OEM_ID_MULTITECH 5 // 05h Multitech Rapidports
#define ION_OEM_ID_AGILENT 6 // 06h AGILENT board
// ION-device Device IDs
// Product IDs - assigned to match middle digit of serial number (No longer true)
#define ION_DEVICE_ID_80251_NETCHIP 0x020 // This bit is set in the PID if this edgeport hardware$
// is based on the 80251+Netchip.
#define ION_DEVICE_ID_GENERATION_1 0x00 // Value for 930 based edgeports
#define ION_DEVICE_ID_GENERATION_2 0x01 // Value for 80251+Netchip.
#define ION_DEVICE_ID_GENERATION_3 0x02 // Value for Texas Instruments TUSB5052 chip
#define ION_DEVICE_ID_GENERATION_4 0x03 // Watchport Family of products
#define ION_GENERATION_MASK 0x03
#define ION_DEVICE_ID_HUB_MASK 0x0080 // This bit in the PID designates a HUB device
// for example 8C would be a 421 4 port hub
// and 8D would be a 2 port embedded hub
#define EDGEPORT_DEVICE_ID_MASK 0x0ff // Not including OEM or GENERATION fields
#define ION_DEVICE_ID_UNCONFIGURED_EDGE_DEVICE 0x000 // In manufacturing only
#define ION_DEVICE_ID_EDGEPORT_4 0x001 // Edgeport/4 RS232
#define ION_DEVICE_ID_EDGEPORT_8R 0x002 // Edgeport with RJ45 no Ring
#define ION_DEVICE_ID_RAPIDPORT_4 0x003 // Rapidport/4
#define ION_DEVICE_ID_EDGEPORT_4T 0x004 // Edgeport/4 RS232 for Telxon (aka "Fleetport")
#define ION_DEVICE_ID_EDGEPORT_2 0x005 // Edgeport/2 RS232
#define ION_DEVICE_ID_EDGEPORT_4I 0x006 // Edgeport/4 RS422
#define ION_DEVICE_ID_EDGEPORT_2I 0x007 // Edgeport/2 RS422/RS485
#define ION_DEVICE_ID_EDGEPORT_8RR 0x008 // Edgeport with RJ45 with Data and RTS/CTS only
// ION_DEVICE_ID_EDGEPORT_8_HANDBUILT 0x009 // Hand-built Edgeport/8 (Placeholder, used in middle digit of serial number only!)
// ION_DEVICE_ID_MULTIMODEM_4X56 0x00A // MultiTech version of RP/4 (Placeholder, used in middle digit of serial number only!)
#define ION_DEVICE_ID_EDGEPORT_PARALLEL_PORT 0x00B // Edgeport/(4)21 Parallel port (USS720)
#define ION_DEVICE_ID_EDGEPORT_421 0x00C // Edgeport/421 Hub+RS232+Parallel
#define ION_DEVICE_ID_EDGEPORT_21 0x00D // Edgeport/21 RS232+Parallel
#define ION_DEVICE_ID_EDGEPORT_8_DUAL_CPU 0x00E // Half of an Edgeport/8 (the kind with 2 EP/4s on 1 PCB)
#define ION_DEVICE_ID_EDGEPORT_8 0x00F // Edgeport/8 (single-CPU)
#define ION_DEVICE_ID_EDGEPORT_2_DIN 0x010 // Edgeport/2 RS232 with Apple DIN connector
#define ION_DEVICE_ID_EDGEPORT_4_DIN 0x011 // Edgeport/4 RS232 with Apple DIN connector
#define ION_DEVICE_ID_EDGEPORT_16_DUAL_CPU 0x012 // Half of an Edgeport/16 (the kind with 2 EP/8s)
#define ION_DEVICE_ID_EDGEPORT_COMPATIBLE 0x013 // Edgeport Compatible, for NCR, Axiohm etc. testing
#define ION_DEVICE_ID_EDGEPORT_8I 0x014 // Edgeport/8 RS422 (single-CPU)
#define ION_DEVICE_ID_EDGEPORT_1 0x015 // Edgeport/1 RS232
#define ION_DEVICE_ID_EPOS44 0x016 // Half of an EPOS/44 (TIUMP BASED)
#define ION_DEVICE_ID_EDGEPORT_42 0x017 // Edgeport/42
#define ION_DEVICE_ID_EDGEPORT_412_8 0x018 // Edgeport/412 8 port part
#define ION_DEVICE_ID_EDGEPORT_412_4 0x019 // Edgeport/412 4 port part
#define ION_DEVICE_ID_EDGEPORT_22I 0x01A // Edgeport/22I is an Edgeport/4 with ports 1&2 RS422 and ports 3&4 RS232
// Compact Form factor TI based devices 2c, 21c, 22c, 221c
#define ION_DEVICE_ID_EDGEPORT_2C 0x01B // Edgeport/2c is a TI based Edgeport/2 - Small I2c
#define ION_DEVICE_ID_EDGEPORT_221C 0x01C // Edgeport/221c is a TI based Edgeport/2 with lucent chip and
// 2 external hub ports - Large I2C
#define ION_DEVICE_ID_EDGEPORT_22C 0x01D // Edgeport/22c is a TI based Edgeport/2 with
// 2 external hub ports - Large I2C
#define ION_DEVICE_ID_EDGEPORT_21C 0x01E // Edgeport/21c is a TI based Edgeport/2 with lucent chip
// Small I2C
/*
* DANGER DANGER The 0x20 bit was used to indicate a 8251/netchip GEN 2 device.
* Since the MAC, Linux, and Optimal drivers still used the old code
* I suggest that you skip the 0x20 bit when creating new PIDs
*/
// Generation 3 devices -- 3410 based edgport/1 (256 byte I2C)
#define ION_DEVICE_ID_TI3410_EDGEPORT_1 0x040 // Edgeport/1 RS232
#define ION_DEVICE_ID_TI3410_EDGEPORT_1I 0x041 // Edgeport/1i- RS422 model
// Ti based software switchable RS232/RS422/RS485 devices
#define ION_DEVICE_ID_EDGEPORT_4S 0x042 // Edgeport/4s - software switchable model
#define ION_DEVICE_ID_EDGEPORT_8S 0x043 // Edgeport/8s - software switchable model
// Usb to Ethernet dongle
#define ION_DEVICE_ID_EDGEPORT_E 0x0E0 // Edgeport/E Usb to Ethernet
// Edgeport TI based devices
#define ION_DEVICE_ID_TI_EDGEPORT_4 0x0201 // Edgeport/4 RS232
#define ION_DEVICE_ID_TI_EDGEPORT_2 0x0205 // Edgeport/2 RS232
#define ION_DEVICE_ID_TI_EDGEPORT_4I 0x0206 // Edgeport/4i RS422
#define ION_DEVICE_ID_TI_EDGEPORT_2I 0x0207 // Edgeport/2i RS422/RS485
#define ION_DEVICE_ID_TI_EDGEPORT_421 0x020C // Edgeport/421 4 hub 2 RS232 + Parallel (lucent on a different hub port)
#define ION_DEVICE_ID_TI_EDGEPORT_21 0x020D // Edgeport/21 2 RS232 + Parallel (lucent on a different hub port)
#define ION_DEVICE_ID_TI_EDGEPORT_416 0x0212 // Edgeport/416
#define ION_DEVICE_ID_TI_EDGEPORT_1 0x0215 // Edgeport/1 RS232
#define ION_DEVICE_ID_TI_EDGEPORT_42 0x0217 // Edgeport/42 4 hub 2 RS232
#define ION_DEVICE_ID_TI_EDGEPORT_22I 0x021A // Edgeport/22I is an Edgeport/4 with ports 1&2 RS422 and ports 3&4 RS232
#define ION_DEVICE_ID_TI_EDGEPORT_2C 0x021B // Edgeport/2c RS232
#define ION_DEVICE_ID_TI_EDGEPORT_221C 0x021C // Edgeport/221c is a TI based Edgeport/2 with lucent chip and
// 2 external hub ports - Large I2C
#define ION_DEVICE_ID_TI_EDGEPORT_22C 0x021D // Edgeport/22c is a TI based Edgeport/2 with
// 2 external hub ports - Large I2C
#define ION_DEVICE_ID_TI_EDGEPORT_21C 0x021E // Edgeport/21c is a TI based Edgeport/2 with lucent chip
// Generation 3 devices -- 3410 based edgport/1 (256 byte I2C)
#define ION_DEVICE_ID_TI_TI3410_EDGEPORT_1 0x0240 // Edgeport/1 RS232
#define ION_DEVICE_ID_TI_TI3410_EDGEPORT_1I 0x0241 // Edgeport/1i- RS422 model
// Ti based software switchable RS232/RS422/RS485 devices
#define ION_DEVICE_ID_TI_EDGEPORT_4S 0x0242 // Edgeport/4s - software switchable model
#define ION_DEVICE_ID_TI_EDGEPORT_8S 0x0243 // Edgeport/8s - software switchable model
#define ION_DEVICE_ID_TI_EDGEPORT_8 0x0244 // Edgeport/8 (single-CPU)
#define ION_DEVICE_ID_TI_EDGEPORT_416B 0x0247 // Edgeport/416
/************************************************************************
*
* Generation 4 devices
*
************************************************************************/
// Watchport based on 3410 both 1-wire and binary products (16K I2C)
#define ION_DEVICE_ID_WP_UNSERIALIZED 0x300 // Watchport based on 3410 both 1-wire and binary products
#define ION_DEVICE_ID_WP_PROXIMITY 0x301 // Watchport/P Discontinued
#define ION_DEVICE_ID_WP_MOTION 0x302 // Watchport/M
#define ION_DEVICE_ID_WP_MOISTURE 0x303 // Watchport/W
#define ION_DEVICE_ID_WP_TEMPERATURE 0x304 // Watchport/T
#define ION_DEVICE_ID_WP_HUMIDITY 0x305 // Watchport/H
#define ION_DEVICE_ID_WP_POWER 0x306 // Watchport
#define ION_DEVICE_ID_WP_LIGHT 0x307 // Watchport
#define ION_DEVICE_ID_WP_RADIATION 0x308 // Watchport
#define ION_DEVICE_ID_WP_ACCELERATION 0x309 // Watchport/A
#define ION_DEVICE_ID_WP_DISTANCE 0x30A // Watchport/D Discontinued
#define ION_DEVICE_ID_WP_PROX_DIST 0x30B // Watchport/D uses distance sensor
// Default to /P function
#define ION_DEVICE_ID_PLUS_PWR_HP4CD 0x30C // 5052 Plus Power HubPort/4CD+ (for Dell)
#define ION_DEVICE_ID_PLUS_PWR_HP4C 0x30D // 5052 Plus Power HubPort/4C+
#define ION_DEVICE_ID_PLUS_PWR_PCI 0x30E // 3410 Plus Power PCI Host Controller 4 port
//
// Definitions for AXIOHM USB product IDs
//
#define USB_VENDOR_ID_AXIOHM 0x05D9 // Axiohm VID
#define AXIOHM_DEVICE_ID_MASK 0xffff
#define AXIOHM_DEVICE_ID_EPIC_A758 0xA758
#define AXIOHM_DEVICE_ID_EPIC_A794 0xA794
#define AXIOHM_DEVICE_ID_EPIC_A225 0xA225
//
// Definitions for NCR USB product IDs
//
#define USB_VENDOR_ID_NCR 0x0404 // NCR VID
#define NCR_DEVICE_ID_MASK 0xffff
#define NCR_DEVICE_ID_EPIC_0202 0x0202
#define NCR_DEVICE_ID_EPIC_0203 0x0203
#define NCR_DEVICE_ID_EPIC_0310 0x0310
#define NCR_DEVICE_ID_EPIC_0311 0x0311
#define NCR_DEVICE_ID_EPIC_0312 0x0312
//
// Definitions for SYMBOL USB product IDs
//
#define USB_VENDOR_ID_SYMBOL 0x05E0 // Symbol VID
#define SYMBOL_DEVICE_ID_MASK 0xffff
#define SYMBOL_DEVICE_ID_KEYFOB 0x0700
//
// Definitions for other product IDs
#define ION_DEVICE_ID_MT4X56USB 0x1403 // OEM device
#define ION_DEVICE_ID_E5805A 0x1A01 // OEM device (rebranded Edgeport/4)
#define GENERATION_ID_FROM_USB_PRODUCT_ID(ProductId) \
((__u16) ((ProductId >> 8) & (ION_GENERATION_MASK)))
#define MAKE_USB_PRODUCT_ID(OemId, DeviceId) \
((__u16) (((OemId) << 10) || (DeviceId)))
#define DEVICE_ID_FROM_USB_PRODUCT_ID(ProductId) \
((__u16) ((ProductId) & (EDGEPORT_DEVICE_ID_MASK)))
#define OEM_ID_FROM_USB_PRODUCT_ID(ProductId) \
((__u16) (((ProductId) >> 10) & 0x3F))
//
// Definitions of parameters for download code. Note that these are
// specific to a given version of download code and must change if the
// corresponding download code changes.
//
// TxCredits value below which driver won't bother sending (to prevent too many small writes).
// Send only if above 25%
#define EDGE_FW_GET_TX_CREDITS_SEND_THRESHOLD(InitialCredit, MaxPacketSize) (max(((InitialCredit) / 4), (MaxPacketSize)))
#define EDGE_FW_BULK_MAX_PACKET_SIZE 64 // Max Packet Size for Bulk In Endpoint (EP1)
#define EDGE_FW_BULK_READ_BUFFER_SIZE 1024 // Size to use for Bulk reads
#define EDGE_FW_INT_MAX_PACKET_SIZE 32 // Max Packet Size for Interrupt In Endpoint
// Note that many units were shipped with MPS=16, we
// force an upgrade to this value).
#define EDGE_FW_INT_INTERVAL 2 // 2ms polling on IntPipe
//
// Definitions of I/O Networks vendor-specific requests
// for default endpoint
//
// bmRequestType = 01000000 Set vendor-specific, to device
// bmRequestType = 11000000 Get vendor-specific, to device
//
// These are the definitions for the bRequest field for the
// above bmRequestTypes.
//
// For the read/write Edgeport memory commands, the parameters
// are as follows:
// wValue = 16-bit address
// wIndex = unused (though we could put segment 00: or FF: here)
// wLength = # bytes to read/write (max 64)
//
#define USB_REQUEST_ION_RESET_DEVICE 0 // Warm reboot Edgeport, retaining USB address
#define USB_REQUEST_ION_GET_EPIC_DESC 1 // Get Edgeport Compatibility Descriptor
// unused 2 // Unused, available
#define USB_REQUEST_ION_READ_RAM 3 // Read EdgePort RAM at specified addr
#define USB_REQUEST_ION_WRITE_RAM 4 // Write EdgePort RAM at specified addr
#define USB_REQUEST_ION_READ_ROM 5 // Read EdgePort ROM at specified addr
#define USB_REQUEST_ION_WRITE_ROM 6 // Write EdgePort ROM at specified addr
#define USB_REQUEST_ION_EXEC_DL_CODE 7 // Begin execution of RAM-based download
// code by jumping to address in wIndex:wValue
// 8 // Unused, available
#define USB_REQUEST_ION_ENABLE_SUSPEND 9 // Enable/Disable suspend feature
// (wValue != 0: Enable; wValue = 0: Disable)
#define USB_REQUEST_ION_SEND_IOSP 10 // Send an IOSP command to the edgeport over the control pipe
#define USB_REQUEST_ION_RECV_IOSP 11 // Receive an IOSP command from the edgeport over the control pipe
#define USB_REQUEST_ION_DIS_INT_TIMER 0x80 // Sent to Axiohm to enable/ disable
// interrupt token timer
// wValue = 1, enable (default)
// wValue = 0, disable
//
// Define parameter values for our vendor-specific commands
//
//
// Edgeport Compatibility Descriptor
//
// This descriptor is only returned by Edgeport-compatible devices
// supporting the EPiC spec. True ION devices do not return this
// descriptor, but instead return STALL on receipt of the
// GET_EPIC_DESC command. The driver interprets a STALL to mean that
// this is a "real" Edgeport.
//
struct edge_compatibility_bits {
// This __u32 defines which Vendor-specific commands/functionality
// the device supports on the default EP0 pipe.
__u32 VendEnableSuspend : 1; // 0001 Set if device supports ION_ENABLE_SUSPEND
__u32 VendUnused : 31; // Available for future expansion, must be 0
// This __u32 defines which IOSP commands are supported over the
// bulk pipe EP1.
// xxxx Set if device supports:
__u32 IOSPOpen : 1; // 0001 OPEN / OPEN_RSP (Currently must be 1)
__u32 IOSPClose : 1; // 0002 CLOSE
__u32 IOSPChase : 1; // 0004 CHASE / CHASE_RSP
__u32 IOSPSetRxFlow : 1; // 0008 SET_RX_FLOW
__u32 IOSPSetTxFlow : 1; // 0010 SET_TX_FLOW
__u32 IOSPSetXChar : 1; // 0020 SET_XON_CHAR/SET_XOFF_CHAR
__u32 IOSPRxCheck : 1; // 0040 RX_CHECK_REQ/RX_CHECK_RSP
__u32 IOSPSetClrBreak : 1; // 0080 SET_BREAK/CLEAR_BREAK
__u32 IOSPWriteMCR : 1; // 0100 MCR register writes (set/clr DTR/RTS)
__u32 IOSPWriteLCR : 1; // 0200 LCR register writes (wordlen/stop/parity)
__u32 IOSPSetBaudRate : 1; // 0400 setting Baud rate (writes to LCR.80h and DLL/DLM register)
__u32 IOSPDisableIntPipe : 1; // 0800 Do not use the interrupt pipe for TxCredits or RxButesAvailable
__u32 IOSPRxDataAvail : 1; // 1000 Return status of RX Fifo (Data available in Fifo)
__u32 IOSPTxPurge : 1; // 2000 Purge TXBuffer and/or Fifo in Edgeport hardware
__u32 IOSPUnused : 18; // Available for future expansion, must be 0
// This __u32 defines which 'general' features are supported
__u32 TrueEdgeport : 1; // 0001 Set if device is a 'real' Edgeport
// (Used only by driver, NEVER set by an EPiC device)
__u32 GenUnused : 31; // Available for future expansion, must be 0
};
#define EDGE_COMPATIBILITY_MASK0 0x0001
#define EDGE_COMPATIBILITY_MASK1 0x3FFF
#define EDGE_COMPATIBILITY_MASK2 0x0001
struct edge_compatibility_descriptor {
__u8 Length; // Descriptor Length (per USB spec)
__u8 DescType; // Descriptor Type (per USB spec, =DEVICE type)
__u8 EpicVer; // Version of EPiC spec supported
// (Currently must be 1)
__u8 NumPorts; // Number of serial ports supported
__u8 iDownloadFile; // Index of string containing download code filename
// 0=no download, FF=download compiled into driver.
__u8 Unused[3]; // Available for future expansion, must be 0
// (Currently must be 0).
__u8 MajorVersion; // Firmware version: xx.
__u8 MinorVersion; // yy.
__le16 BuildNumber; // zzzz (LE format)
// The following structure contains __u32s, with each bit
// specifying whether the EPiC device supports the given
// command or functionality.
struct edge_compatibility_bits Supports;
};
// Values for iDownloadFile
#define EDGE_DOWNLOAD_FILE_NONE 0 // No download requested
#define EDGE_DOWNLOAD_FILE_INTERNAL 0xFF // Download the file compiled into driver (930 version)
#define EDGE_DOWNLOAD_FILE_I930 0xFF // Download the file compiled into driver (930 version)
#define EDGE_DOWNLOAD_FILE_80251 0xFE // Download the file compiled into driver (80251 version)
/*
* Special addresses for READ/WRITE_RAM/ROM
*/
// Version 1 (original) format of DeviceParams
#define EDGE_MANUF_DESC_ADDR_V1 0x00FF7F00
#define EDGE_MANUF_DESC_LEN_V1 sizeof(EDGE_MANUF_DESCRIPTOR_V1)
// Version 2 format of DeviceParams. This format is longer (3C0h)
// and starts lower in memory, at the uppermost 1K in ROM.
#define EDGE_MANUF_DESC_ADDR 0x00FF7C00
#define EDGE_MANUF_DESC_LEN sizeof(struct edge_manuf_descriptor)
// Boot params descriptor
#define EDGE_BOOT_DESC_ADDR 0x00FF7FC0
#define EDGE_BOOT_DESC_LEN sizeof(struct edge_boot_descriptor)
// Define the max block size that may be read or written
// in a read/write RAM/ROM command.
#define MAX_SIZE_REQ_ION_READ_MEM ((__u16)64)
#define MAX_SIZE_REQ_ION_WRITE_MEM ((__u16)64)
//
// Notes for the following two ION vendor-specific param descriptors:
//
// 1. These have a standard USB descriptor header so they look like a
// normal descriptor.
// 2. Any strings in the structures are in USB-defined string
// descriptor format, so that they may be separately retrieved,
// if necessary, with a minimum of work on the 930. This also
// requires them to be in UNICODE format, which, for English at
// least, simply means extending each __u8 into a __u16.
// 3. For all fields, 00 means 'uninitialized'.
// 4. All unused areas should be set to 00 for future expansion.
//
// This structure is ver 2 format. It contains ALL USB descriptors as
// well as the configuration parameters that were in the original V1
// structure. It is NOT modified when new boot code is downloaded; rather,
// these values are set or modified by manufacturing. It is located at
// xC00-xFBF (length 3C0h) in the ROM.
// This structure is a superset of the v1 structure and is arranged so
// that all of the v1 fields remain at the same address. We are just
// adding more room to the front of the structure to hold the descriptors.
//
// The actual contents of this structure are defined in a 930 assembly
// file, converted to a binary image, and then written by the serialization
// program. The C definition of this structure just defines a dummy
// area for general USB descriptors and the descriptor tables (the root
// descriptor starts at xC00). At the bottom of the structure are the
// fields inherited from the v1 structure.
#define MAX_SERIALNUMBER_LEN 12
#define MAX_ASSEMBLYNUMBER_LEN 14
struct edge_manuf_descriptor {
__u16 RootDescTable[0x10]; // C00 Root of descriptor tables (just a placeholder)
__u8 DescriptorArea[0x2E0]; // C20 Descriptors go here, up to 2E0h (just a placeholder)
// Start of v1-compatible section
__u8 Length; // F00 Desc length for what follows, per USB (= C0h )
__u8 DescType; // F01 Desc type, per USB (=DEVICE type)
__u8 DescVer; // F02 Desc version/format (currently 2)
__u8 NumRootDescEntries; // F03 # entries in RootDescTable
__u8 RomSize; // F04 Size of ROM/E2PROM in K
__u8 RamSize; // F05 Size of external RAM in K
__u8 CpuRev; // F06 CPU revision level (chg only if s/w visible)
__u8 BoardRev; // F07 PCB revision level (chg only if s/w visible)
__u8 NumPorts; // F08 Number of ports
__u8 DescDate[3]; // F09 MM/DD/YY when descriptor template was compiler,
// so host can track changes to USB-only descriptors.
__u8 SerNumLength; // F0C USB string descriptor len
__u8 SerNumDescType; // F0D USB descriptor type (=STRING type)
__le16 SerialNumber[MAX_SERIALNUMBER_LEN]; // F0E "01-01-000100" Unicode Serial Number
__u8 AssemblyNumLength; // F26 USB string descriptor len
__u8 AssemblyNumDescType; // F27 USB descriptor type (=STRING type)
__le16 AssemblyNumber[MAX_ASSEMBLYNUMBER_LEN]; // F28 "350-1000-01-A " assembly number
__u8 OemAssyNumLength; // F44 USB string descriptor len
__u8 OemAssyNumDescType; // F45 USB descriptor type (=STRING type)
__le16 OemAssyNumber[MAX_ASSEMBLYNUMBER_LEN]; // F46 "xxxxxxxxxxxxxx" OEM assembly number
__u8 ManufDateLength; // F62 USB string descriptor len
__u8 ManufDateDescType; // F63 USB descriptor type (=STRING type)
__le16 ManufDate[6]; // F64 "MMDDYY" manufacturing date
__u8 Reserved3[0x4D]; // F70 -- unused, set to 0 --
__u8 UartType; // FBD Uart Type
__u8 IonPid; // FBE Product ID, == LSB of USB DevDesc.PID
// (Note: Edgeport/4s before 11/98 will have
// 00 here instead of 01)
__u8 IonConfig; // FBF Config byte for ION manufacturing use
// FBF end of structure, total len = 3C0h
};
#define MANUF_DESC_VER_1 1 // Original definition of MANUF_DESC
#define MANUF_DESC_VER_2 2 // Ver 2, starts at xC00h len 3C0h
// Uart Types
// Note: Since this field was added only recently, all Edgeport/4 units
// shipped before 11/98 will have 00 in this field. Therefore,
// both 00 and 01 values mean '654.
#define MANUF_UART_EXAR_654_EARLY 0 // Exar 16C654 in Edgeport/4s before 11/98
#define MANUF_UART_EXAR_654 1 // Exar 16C654
#define MANUF_UART_EXAR_2852 2 // Exar 16C2852
//
// Note: The CpuRev and BoardRev values do not conform to manufacturing
// revisions; they are to be incremented only when the CPU or hardware
// changes in a software-visible way, such that the 930 software or
// the host driver needs to handle the hardware differently.
//
// Values of bottom 5 bits of CpuRev & BoardRev for
// Implementation 0 (ie, 930-based)
#define MANUF_CPU_REV_AD4 1 // 930 AD4, with EP1 Rx bug (needs RXSPM)
#define MANUF_CPU_REV_AD5 2 // 930 AD5, with above bug (supposedly) fixed
#define MANUF_CPU_80251 0x20 // Intel 80251
#define MANUF_BOARD_REV_A 1 // Original version, == Manuf Rev A
#define MANUF_BOARD_REV_B 2 // Manuf Rev B, wakeup interrupt works
#define MANUF_BOARD_REV_C 3 // Manuf Rev C, 2/4 ports, rs232/rs422
#define MANUF_BOARD_REV_GENERATION_2 0x20 // Second generaiton edgeport
// Values of bottom 5 bits of CpuRev & BoardRev for
// Implementation 1 (ie, 251+Netchip-based)
#define MANUF_CPU_REV_1 1 // C251TB Rev 1 (Need actual Intel rev here)
#define MANUF_BOARD_REV_A 1 // First rev of 251+Netchip design
#define MANUF_SERNUM_LENGTH sizeof(((struct edge_manuf_descriptor *)0)->SerialNumber)
#define MANUF_ASSYNUM_LENGTH sizeof(((struct edge_manuf_descriptor *)0)->AssemblyNumber)
#define MANUF_OEMASSYNUM_LENGTH sizeof(((struct edge_manuf_descriptor *)0)->OemAssyNumber)
#define MANUF_MANUFDATE_LENGTH sizeof(((struct edge_manuf_descriptor *)0)->ManufDate)
#define MANUF_ION_CONFIG_DIAG_NO_LOOP 0x20 // As below but no ext loopback test
#define MANUF_ION_CONFIG_DIAG 0x40 // 930 based device: 1=Run h/w diags, 0=norm
// TIUMP Device : 1=IONSERIAL needs to run Final Test
#define MANUF_ION_CONFIG_MASTER 0x80 // 930 based device: 1=Master mode, 0=Normal
// TIUMP Device : 1=First device on a multi TIUMP Device
//
// This structure describes parameters for the boot code, and
// is programmed along with new boot code. These are values
// which are specific to a given build of the boot code. It
// is exactly 64 bytes long and is fixed at address FF:xFC0
// - FF:xFFF. Note that the 930-mandated UCONFIG bytes are
// included in this structure.
//
struct edge_boot_descriptor {
__u8 Length; // C0 Desc length, per USB (= 40h)
__u8 DescType; // C1 Desc type, per USB (= DEVICE type)
__u8 DescVer; // C2 Desc version/format
__u8 Reserved1; // C3 -- unused, set to 0 --
__le16 BootCodeLength; // C4 Boot code goes from FF:0000 to FF:(len-1)
// (LE format)
__u8 MajorVersion; // C6 Firmware version: xx.
__u8 MinorVersion; // C7 yy.
__le16 BuildNumber; // C8 zzzz (LE format)
__u16 EnumRootDescTable; // CA Root of ROM-based descriptor table
__u8 NumDescTypes; // CC Number of supported descriptor types
__u8 Reserved4; // CD Fix Compiler Packing
__le16 Capabilities; // CE-CF Capabilities flags (LE format)
__u8 Reserved2[0x28]; // D0 -- unused, set to 0 --
__u8 UConfig0; // F8 930-defined CPU configuration byte 0
__u8 UConfig1; // F9 930-defined CPU configuration byte 1
__u8 Reserved3[6]; // FA -- unused, set to 0 --
// FF end of structure, total len = 80
};
#define BOOT_DESC_VER_1 1 // Original definition of BOOT_PARAMS
#define BOOT_DESC_VER_2 2 // 2nd definition, descriptors not included in boot
// Capabilities flags
#define BOOT_CAP_RESET_CMD 0x0001 // If set, boot correctly supports ION_RESET_DEVICE
/************************************************************************
T I U M P D E F I N I T I O N S
***********************************************************************/
// Chip definitions in I2C
#define UMP5152 0x52
#define UMP3410 0x10
//************************************************************************
// TI I2C Format Definitions
//************************************************************************
#define I2C_DESC_TYPE_INFO_BASIC 0x01
#define I2C_DESC_TYPE_FIRMWARE_BASIC 0x02
#define I2C_DESC_TYPE_DEVICE 0x03
#define I2C_DESC_TYPE_CONFIG 0x04
#define I2C_DESC_TYPE_STRING 0x05
#define I2C_DESC_TYPE_FIRMWARE_AUTO 0x07 // for 3410 download
#define I2C_DESC_TYPE_CONFIG_KLUDGE 0x14 // for 3410
#define I2C_DESC_TYPE_WATCHPORT_VERSION 0x15 // firmware version number for watchport
#define I2C_DESC_TYPE_WATCHPORT_CALIBRATION_DATA 0x16 // Watchport Calibration Data
#define I2C_DESC_TYPE_FIRMWARE_BLANK 0xf2
// Special section defined by ION
#define I2C_DESC_TYPE_ION 0 // Not defined by TI
struct ti_i2c_desc {
__u8 Type; // Type of descriptor
__le16 Size; // Size of data only not including header
__u8 CheckSum; // Checksum (8 bit sum of data only)
__u8 Data[0]; // Data starts here
} __attribute__((packed));
// for 5152 devices only (type 2 record)
// for 3410 the version is stored in the WATCHPORT_FIRMWARE_VERSION descriptor
struct ti_i2c_firmware_rec {
__u8 Ver_Major; // Firmware Major version number
__u8 Ver_Minor; // Firmware Minor version number
__u8 Data[0]; // Download starts here
} __attribute__((packed));
struct watchport_firmware_version {
// Added 2 bytes for version number
__u8 Version_Major; // Download Version (for Watchport)
__u8 Version_Minor;
} __attribute__((packed));
// Structure of header of download image in fw_down.h
struct ti_i2c_image_header {
__le16 Length;
__u8 CheckSum;
} __attribute__((packed));
struct ti_basic_descriptor {
__u8 Power; // Self powered
// bit 7: 1 - power switching supported
// 0 - power switching not supported
//
// bit 0: 1 - self powered
// 0 - bus powered
//
//
__u16 HubVid; // VID HUB
__u16 HubPid; // PID HUB
__u16 DevPid; // PID Edgeport
__u8 HubTime; // Time for power on to power good
__u8 HubCurrent; // HUB Current = 100ma
} __attribute__((packed));
// CPU / Board Rev Definitions
#define TI_CPU_REV_5052 2 // 5052 based edgeports
#define TI_CPU_REV_3410 3 // 3410 based edgeports
#define TI_BOARD_REV_TI_EP 0 // Basic ti based edgeport
#define TI_BOARD_REV_COMPACT 1 // Compact board
#define TI_BOARD_REV_WATCHPORT 2 // Watchport
#define TI_GET_CPU_REVISION(x) (__u8)((((x)>>4)&0x0f))
#define TI_GET_BOARD_REVISION(x) (__u8)(((x)&0x0f))
#define TI_I2C_SIZE_MASK 0x1f // 5 bits
#define TI_GET_I2C_SIZE(x) ((((x) & TI_I2C_SIZE_MASK)+1)*256)
#define TI_MAX_I2C_SIZE (16 * 1024)
#define TI_MANUF_VERSION_0 0
// IonConig2 flags
#define TI_CONFIG2_RS232 0x01
#define TI_CONFIG2_RS422 0x02
#define TI_CONFIG2_RS485 0x04
#define TI_CONFIG2_SWITCHABLE 0x08
#define TI_CONFIG2_WATCHPORT 0x10
struct edge_ti_manuf_descriptor {
__u8 IonConfig; // Config byte for ION manufacturing use
__u8 IonConfig2; // Expansion
__u8 Version; // Version
__u8 CpuRev_BoardRev; // CPU revision level (0xF0) and Board Rev Level (0x0F)
__u8 NumPorts; // Number of ports for this UMP
__u8 NumVirtualPorts; // Number of Virtual ports
__u8 HubConfig1; // Used to configure the Hub
__u8 HubConfig2; // Used to configure the Hub
__u8 TotalPorts; // Total Number of Com Ports for the entire device (All UMPs)
__u8 Reserved; // Reserved
} __attribute__((packed));
#endif // if !defined(_USBVEND_H)