Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6: (220 commits) USB: backlight, appledisplay: fix incomplete registration failure handling USB: pl2303: remove unnecessary reset of usb_device in urbs USB: ftdi_sio: remove obsolete check in unthrottle USB: ftdi_sio: remove unused tx_bytes counter USB: qcaux: driver for auxiliary serial ports on Qualcomm devices USB: pl2303: initial TIOCGSERIAL support USB: option: add Longcheer/Longsung vendor ID USB: fix I2C API usage in ohci-pnx4008. USB: usbmon: mask seconds properly in text API USB: sisusbvga: no unnecessary GFP_ATOMIC USB: storage: onetouch: unnecessary GFP_ATOMIC USB: serial: ftdi: add CONTEC vendor and product id USB: remove references to port->port.count from the serial drivers USB: tty: Prune uses of tty_request_room in the USB layer USB: tty: Add a function to insert a string of characters with the same flag USB: don't read past config->interface[] if usb_control_msg() fails in usb_reset_configuration() USB: tty: kill request_room for USB ACM class USB: tty: sort out the request_room handling for whiteheat USB: storage: fix misplaced parenthesis USB: vstusb.c: removal of driver for Vernier Software & Technology, Inc., devices and spectrometers ...
This commit is contained in:
@@ -5,4 +5,3 @@ header-y += gadgetfs.h
|
||||
header-y += midi.h
|
||||
header-y += g_printer.h
|
||||
header-y += tmc.h
|
||||
header-y += vstusb.h
|
||||
|
@@ -15,6 +15,7 @@ struct usba_ep_data {
|
||||
|
||||
struct usba_platform_data {
|
||||
int vbus_pin;
|
||||
int vbus_pin_inverted;
|
||||
int num_ep;
|
||||
struct usba_ep_data ep[0];
|
||||
};
|
||||
|
@@ -775,7 +775,7 @@ enum usb_device_speed {
|
||||
USB_SPEED_UNKNOWN = 0, /* enumerating */
|
||||
USB_SPEED_LOW, USB_SPEED_FULL, /* usb 1.1 */
|
||||
USB_SPEED_HIGH, /* usb 2.0 */
|
||||
USB_SPEED_VARIABLE, /* wireless (usb 2.5) */
|
||||
USB_SPEED_WIRELESS, /* wireless (usb 2.5) */
|
||||
USB_SPEED_SUPER, /* usb 3.0 */
|
||||
};
|
||||
|
||||
|
@@ -30,26 +30,26 @@ struct musb_hdrc_eps_bits {
|
||||
struct musb_hdrc_config {
|
||||
/* MUSB configuration-specific details */
|
||||
unsigned multipoint:1; /* multipoint device */
|
||||
unsigned dyn_fifo:1; /* supports dynamic fifo sizing */
|
||||
unsigned soft_con:1; /* soft connect required */
|
||||
unsigned utm_16:1; /* utm data witdh is 16 bits */
|
||||
unsigned dyn_fifo:1 __deprecated; /* supports dynamic fifo sizing */
|
||||
unsigned soft_con:1 __deprecated; /* soft connect required */
|
||||
unsigned utm_16:1 __deprecated; /* utm data witdh is 16 bits */
|
||||
unsigned big_endian:1; /* true if CPU uses big-endian */
|
||||
unsigned mult_bulk_tx:1; /* Tx ep required for multbulk pkts */
|
||||
unsigned mult_bulk_rx:1; /* Rx ep required for multbulk pkts */
|
||||
unsigned high_iso_tx:1; /* Tx ep required for HB iso */
|
||||
unsigned high_iso_rx:1; /* Rx ep required for HD iso */
|
||||
unsigned dma:1; /* supports DMA */
|
||||
unsigned vendor_req:1; /* vendor registers required */
|
||||
unsigned dma:1 __deprecated; /* supports DMA */
|
||||
unsigned vendor_req:1 __deprecated; /* vendor registers required */
|
||||
|
||||
u8 num_eps; /* number of endpoints _with_ ep0 */
|
||||
u8 dma_channels; /* number of dma channels */
|
||||
u8 dma_channels __deprecated; /* number of dma channels */
|
||||
u8 dyn_fifo_size; /* dynamic size in bytes */
|
||||
u8 vendor_ctrl; /* vendor control reg width */
|
||||
u8 vendor_stat; /* vendor status reg witdh */
|
||||
u8 dma_req_chan; /* bitmask for required dma channels */
|
||||
u8 vendor_ctrl __deprecated; /* vendor control reg width */
|
||||
u8 vendor_stat __deprecated; /* vendor status reg witdh */
|
||||
u8 dma_req_chan __deprecated; /* bitmask for required dma channels */
|
||||
u8 ram_bits; /* ram address size */
|
||||
|
||||
struct musb_hdrc_eps_bits *eps_bits;
|
||||
struct musb_hdrc_eps_bits *eps_bits __deprecated;
|
||||
#ifdef CONFIG_BLACKFIN
|
||||
/* A GPIO controlling VRSEL in Blackfin */
|
||||
unsigned int gpio_vrsel;
|
||||
@@ -76,6 +76,9 @@ struct musb_hdrc_platform_data {
|
||||
/* (HOST or OTG) msec/2 after VBUS on till power good */
|
||||
u8 potpgt;
|
||||
|
||||
/* (HOST or OTG) program PHY for external Vbus */
|
||||
unsigned extvbus:1;
|
||||
|
||||
/* Power the device on or off */
|
||||
int (*set_power)(int state);
|
||||
|
||||
|
@@ -9,6 +9,8 @@
|
||||
#ifndef __LINUX_USB_OTG_H
|
||||
#define __LINUX_USB_OTG_H
|
||||
|
||||
#include <linux/notifier.h>
|
||||
|
||||
/* OTG defines lots of enumeration states before device reset */
|
||||
enum usb_otg_state {
|
||||
OTG_STATE_UNDEFINED = 0,
|
||||
@@ -33,6 +35,14 @@ enum usb_otg_state {
|
||||
OTG_STATE_A_VBUS_ERR,
|
||||
};
|
||||
|
||||
enum usb_xceiv_events {
|
||||
USB_EVENT_NONE, /* no events or cable disconnected */
|
||||
USB_EVENT_VBUS, /* vbus valid event */
|
||||
USB_EVENT_ID, /* id was grounded */
|
||||
USB_EVENT_CHARGER, /* usb dedicated charger */
|
||||
USB_EVENT_ENUMERATED, /* gadget driver enumerated */
|
||||
};
|
||||
|
||||
#define USB_OTG_PULLUP_ID (1 << 0)
|
||||
#define USB_OTG_PULLDOWN_DP (1 << 1)
|
||||
#define USB_OTG_PULLDOWN_DM (1 << 2)
|
||||
@@ -70,6 +80,9 @@ struct otg_transceiver {
|
||||
struct otg_io_access_ops *io_ops;
|
||||
void __iomem *io_priv;
|
||||
|
||||
/* for notification of usb_xceiv_events */
|
||||
struct blocking_notifier_head notifier;
|
||||
|
||||
/* to pass extra port status to the root hub */
|
||||
u16 port_status;
|
||||
u16 port_change;
|
||||
@@ -213,6 +226,18 @@ otg_start_srp(struct otg_transceiver *otg)
|
||||
return otg->start_srp(otg);
|
||||
}
|
||||
|
||||
/* notifiers */
|
||||
static inline int
|
||||
otg_register_notifier(struct otg_transceiver *otg, struct notifier_block *nb)
|
||||
{
|
||||
return blocking_notifier_chain_register(&otg->notifier, nb);
|
||||
}
|
||||
|
||||
static inline void
|
||||
otg_unregister_notifier(struct otg_transceiver *otg, struct notifier_block *nb)
|
||||
{
|
||||
blocking_notifier_chain_unregister(&otg->notifier, nb);
|
||||
}
|
||||
|
||||
/* for OTG controller drivers (and maybe other stuff) */
|
||||
extern int usb_bus_start_enum(struct usb_bus *bus, unsigned port_num);
|
||||
|
@@ -19,4 +19,7 @@
|
||||
/* device can't handle its Configuration or Interface strings */
|
||||
#define USB_QUIRK_CONFIG_INTF_STRINGS 0x00000008
|
||||
|
||||
/*device will morph if reset, don't use reset for handling errors */
|
||||
#define USB_QUIRK_RESET_MORPHS 0x00000010
|
||||
|
||||
#endif /* __LINUX_USB_QUIRKS_H */
|
||||
|
@@ -351,14 +351,11 @@ static inline void usb_serial_debug_data(int debug,
|
||||
|
||||
/* Use our own dbg macro */
|
||||
#undef dbg
|
||||
#define dbg(format, arg...) \
|
||||
do { \
|
||||
if (debug) \
|
||||
printk(KERN_DEBUG "%s: " format "\n" , __FILE__ , \
|
||||
## arg); \
|
||||
} while (0)
|
||||
|
||||
|
||||
#define dbg(format, arg...) \
|
||||
do { \
|
||||
if (debug) \
|
||||
printk(KERN_DEBUG "%s: " format "\n", __FILE__, ##arg); \
|
||||
} while (0)
|
||||
|
||||
#endif /* __LINUX_USB_SERIAL_H */
|
||||
|
||||
|
@@ -1,71 +0,0 @@
|
||||
/*****************************************************************************
|
||||
* File: drivers/usb/misc/vstusb.h
|
||||
*
|
||||
* Purpose: Support for the bulk USB Vernier Spectrophotometers
|
||||
*
|
||||
* Author: EQware Engineering, Inc.
|
||||
* Oregon City, OR, USA 97045
|
||||
*
|
||||
* Copyright: 2007, 2008
|
||||
* Vernier Software & Technology
|
||||
* Beaverton, OR, USA 97005
|
||||
*
|
||||
* Web: www.vernier.com
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License version 2 as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
*****************************************************************************/
|
||||
/*****************************************************************************
|
||||
*
|
||||
* The vstusb module is a standard usb 'client' driver running on top of the
|
||||
* standard usb host controller stack.
|
||||
*
|
||||
* In general, vstusb supports standard bulk usb pipes. It supports multiple
|
||||
* devices and multiple pipes per device.
|
||||
*
|
||||
* The vstusb driver supports two interfaces:
|
||||
* 1 - ioctl SEND_PIPE/RECV_PIPE - a general bulk write/read msg
|
||||
* interface to any pipe with timeout support;
|
||||
* 2 - standard read/write with ioctl config - offers standard read/write
|
||||
* interface with ioctl configured pipes and timeouts.
|
||||
*
|
||||
* Both interfaces can be signal from other process and will abort its i/o
|
||||
* operation.
|
||||
*
|
||||
* A timeout of 0 means NO timeout. The user can still terminate the read via
|
||||
* signal.
|
||||
*
|
||||
* If using multiple threads with this driver, the user should ensure that
|
||||
* any reads, writes, or ioctls are complete before closing the device.
|
||||
* Changing read/write timeouts or pipes takes effect on next read/write.
|
||||
*
|
||||
*****************************************************************************/
|
||||
|
||||
struct vstusb_args {
|
||||
union {
|
||||
/* this struct is used for IOCTL_VSTUSB_SEND_PIPE, *
|
||||
* IOCTL_VSTUSB_RECV_PIPE, and read()/write() fops */
|
||||
struct {
|
||||
void __user *buffer;
|
||||
size_t count;
|
||||
unsigned int timeout_ms;
|
||||
int pipe;
|
||||
};
|
||||
|
||||
/* this one is used for IOCTL_VSTUSB_CONFIG_RW */
|
||||
struct {
|
||||
int rd_pipe;
|
||||
int rd_timeout_ms;
|
||||
int wr_pipe;
|
||||
int wr_timeout_ms;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
#define VST_IOC_MAGIC 'L'
|
||||
#define VST_IOC_FIRST 0x20
|
||||
#define IOCTL_VSTUSB_SEND_PIPE _IO(VST_IOC_MAGIC, VST_IOC_FIRST)
|
||||
#define IOCTL_VSTUSB_RECV_PIPE _IO(VST_IOC_MAGIC, VST_IOC_FIRST + 1)
|
||||
#define IOCTL_VSTUSB_CONFIG_RW _IO(VST_IOC_MAGIC, VST_IOC_FIRST + 2)
|
Reference in New Issue
Block a user