FreeBSD kernel usb device Code
|
#include <sys/cdefs.h>
#include <sys/param.h>
#include <sys/eventhandler.h>
#include <sys/sockio.h>
#include <sys/mbuf.h>
#include <sys/malloc.h>
#include <sys/kernel.h>
#include <sys/module.h>
#include <sys/socket.h>
#include <sys/tty.h>
#include <sys/sysctl.h>
#include <sys/condvar.h>
#include <sys/sx.h>
#include <sys/proc.h>
#include <sys/conf.h>
#include <sys/bus.h>
#include <sys/systm.h>
#include <sys/limits.h>
#include <machine/bus.h>
#include <net/if.h>
#include <net/if_var.h>
#include <net/if_types.h>
#include <net/netisr.h>
#include <net/bpf.h>
#include <netinet/in.h>
#include <netinet/ip.h>
#include <netinet/ip6.h>
#include <dev/usb/usb.h>
#include <dev/usb/usbdi.h>
#include <dev/usb/usbdi_util.h>
#include <dev/usb/usb_cdc.h>
#include "usbdevs.h"
#include <dev/usb/usb_debug.h>
#include <dev/usb/usb_process.h>
#include <dev/usb/usb_busdma.h>
#include <dev/usb/usb_msctest.h>
#include <dev/usb/serial/usb_serial.h>
Go to the source code of this file.
Data Structures | |
struct | uhso_tty |
struct | uhso_softc |
Macros | |
#define | USB_DEBUG_VAR uhso_debug |
#define | UHSO_MAX_MTU 2048 |
#define | UHSO_IFACE_SPEC(usb_type, port, port_type) (((usb_type) << 24) | ((port) << 16) | (port_type)) |
#define | UHSO_IFACE_USB_TYPE(x) ((x >> 24) & 0xff) |
#define | UHSO_IFACE_PORT(x) ((x >> 16) & 0xff) |
#define | UHSO_IFACE_PORT_TYPE(x) (x & 0xff) |
#define | UHSO_IF_NET 0x01 /* Network packet interface */ |
#define | UHSO_IF_MUX 0x02 /* Multiplexed serial port */ |
#define | UHSO_IF_BULK 0x04 /* Bulk interface */ |
#define | UHSO_PORT_UNKNOWN 0x00 |
#define | UHSO_PORT_SERIAL 0x01 /* Serial port */ |
#define | UHSO_PORT_NETWORK 0x02 /* Network packet interface */ |
#define | UHSO_MPORT_TYPE_CTL 0x00 /* Control port */ |
#define | UHSO_MPORT_TYPE_APP 0x01 /* Application */ |
#define | UHSO_MPORT_TYPE_PCSC 0x02 |
#define | UHSO_MPORT_TYPE_GPS 0x03 |
#define | UHSO_MPORT_TYPE_APP2 0x04 /* Secondary application */ |
#define | UHSO_MPORT_TYPE_MAX UHSO_MPORT_TYPE_APP2 |
#define | UHSO_MPORT_TYPE_NOMAX 8 /* Max number of mux ports */ |
#define | UHSO_PORT_TYPE_UNKNOWN 0x00 |
#define | UHSO_PORT_TYPE_CTL 0x01 |
#define | UHSO_PORT_TYPE_APP 0x02 |
#define | UHSO_PORT_TYPE_APP2 0x03 |
#define | UHSO_PORT_TYPE_MODEM 0x04 |
#define | UHSO_PORT_TYPE_NETWORK 0x05 |
#define | UHSO_PORT_TYPE_DIAG 0x06 |
#define | UHSO_PORT_TYPE_DIAG2 0x07 |
#define | UHSO_PORT_TYPE_GPS 0x08 |
#define | UHSO_PORT_TYPE_GPSCTL 0x09 |
#define | UHSO_PORT_TYPE_PCSC 0x0a |
#define | UHSO_PORT_TYPE_MSD 0x0b |
#define | UHSO_PORT_TYPE_VOICE 0x0c |
#define | UHSO_PORT_TYPE_MAX 0x0c |
#define | UHSO_STATIC_IFACE 0x01 |
#define | UHSO_AUTO_IFACE 0x02 |
#define | UHSO_DEV(v, p, i) { USB_VPI(USB_VENDOR_##v, USB_PRODUCT_##v##_##p, i) } |
#define | UHSO_DPRINTF(n, x, ...) |
#define | UHSO_HEXDUMP(_buf, _len) |
Enumerations | |
enum | { UHSO_MUX_ENDPT_INTR = 0 , UHSO_MUX_ENDPT_MAX } |
enum | { UHSO_CTRL_READ = 0 , UHSO_CTRL_WRITE , UHSO_CTRL_MAX } |
enum | { UHSO_IFNET_READ = 0 , UHSO_IFNET_WRITE , UHSO_IFNET_MAX } |
enum | { UHSO_BULK_ENDPT_READ = 0 , UHSO_BULK_ENDPT_WRITE , UHSO_BULK_ENDPT_INTR , UHSO_BULK_ENDPT_MAX } |
Functions | |
__FBSDID ("$FreeBSD$") | |
static | SYSCTL_NODE (_hw_usb, OID_AUTO, uhso, CTLFLAG_RW|CTLFLAG_MPSAFE, 0, "USB uhso") |
SYSCTL_INT (_hw_usb_uhso, OID_AUTO, auto_switch, CTLFLAG_RWTUN, &uhso_autoswitch, 0, "Automatically switch to modem mode") | |
static int | uhso_probe_iface (struct uhso_softc *, int, int(*probe)(struct usb_device *, int)) |
static int | uhso_probe_iface_auto (struct usb_device *, int) |
static int | uhso_probe_iface_static (struct usb_device *, int) |
static int | uhso_attach_muxserial (struct uhso_softc *, struct usb_interface *, int type) |
static int | uhso_attach_bulkserial (struct uhso_softc *, struct usb_interface *, int type) |
static int | uhso_attach_ifnet (struct uhso_softc *, struct usb_interface *, int type) |
static void | uhso_test_autoinst (void *, struct usb_device *, struct usb_attach_arg *) |
static int | uhso_driver_loaded (struct module *, int, void *) |
static int | uhso_radio_sysctl (SYSCTL_HANDLER_ARGS) |
static int | uhso_radio_ctrl (struct uhso_softc *, int) |
static void | uhso_free (struct ucom_softc *) |
static void | uhso_ucom_start_read (struct ucom_softc *) |
static void | uhso_ucom_stop_read (struct ucom_softc *) |
static void | uhso_ucom_start_write (struct ucom_softc *) |
static void | uhso_ucom_stop_write (struct ucom_softc *) |
static void | uhso_ucom_cfg_get_status (struct ucom_softc *, uint8_t *, uint8_t *) |
static void | uhso_ucom_cfg_set_dtr (struct ucom_softc *, uint8_t) |
static void | uhso_ucom_cfg_set_rts (struct ucom_softc *, uint8_t) |
static void | uhso_if_init (void *) |
static void | uhso_if_start (struct ifnet *) |
static void | uhso_if_stop (struct uhso_softc *) |
static int | uhso_if_ioctl (struct ifnet *, u_long, caddr_t) |
static int | uhso_if_output (struct ifnet *, struct mbuf *, const struct sockaddr *, struct route *) |
static void | uhso_if_rxflush (void *) |
static void | uhso_free_softc (struct uhso_softc *) |
DRIVER_MODULE (uhso, uhub, uhso_driver, uhso_devclass, uhso_driver_loaded, 0) | |
MODULE_DEPEND (uhso, ucom, 1, 1, 1) | |
MODULE_DEPEND (uhso, usb, 1, 1, 1) | |
MODULE_VERSION (uhso, 1) | |
USB_PNP_HOST_INFO (uhso_devs) | |
static int | uhso_probe (device_t self) |
static int | uhso_attach (device_t self) |
static int | uhso_detach (device_t self) |
UCOM_UNLOAD_DRAIN (uhso) | |
static int | uhso_alloc_tty (struct uhso_softc *sc) |
static void | uhso_mux_intr_callback (struct usb_xfer *xfer, usb_error_t error) |
static void | uhso_mux_read_callback (struct usb_xfer *xfer, usb_error_t error) |
static void | uhso_mux_write_callback (struct usb_xfer *xfer, usb_error_t error) |
static void | uhso_bs_read_callback (struct usb_xfer *xfer, usb_error_t error) |
static void | uhso_bs_write_callback (struct usb_xfer *xfer, usb_error_t error) |
static void | uhso_bs_cfg (struct uhso_softc *sc) |
static void | uhso_bs_intr_callback (struct usb_xfer *xfer, usb_error_t error) |
static void | uhso_ifnet_read_callback (struct usb_xfer *xfer, usb_error_t error) |
static void | uhso_ifnet_write_callback (struct usb_xfer *xfer, usb_error_t error) |
#define UHSO_DEV | ( | v, | |
p, | |||
i | |||
) | { USB_VPI(USB_VENDOR_##v, USB_PRODUCT_##v##_##p, i) } |
#define UHSO_IFACE_SPEC | ( | usb_type, | |
port, | |||
port_type | |||
) | (((usb_type) << 24) | ((port) << 16) | (port_type)) |
#define UHSO_MPORT_TYPE_APP2 0x04 /* Secondary application */ |
#define UHSO_MPORT_TYPE_MAX UHSO_MPORT_TYPE_APP2 |
#define UHSO_MPORT_TYPE_NOMAX 8 /* Max number of mux ports */ |
#define UHSO_PORT_NETWORK 0x02 /* Network packet interface */ |
anonymous enum |
anonymous enum |
anonymous enum |
anonymous enum |
__FBSDID | ( | "$FreeBSD$" | ) |
DRIVER_MODULE | ( | uhso | , |
uhub | , | ||
uhso_driver | , | ||
uhso_devclass | , | ||
uhso_driver_loaded | , | ||
0 | |||
) |
MODULE_DEPEND | ( | uhso | , |
ucom | , | ||
1 | , | ||
1 | , | ||
1 | |||
) |
MODULE_DEPEND | ( | uhso | , |
usb | , | ||
1 | , | ||
1 | , | ||
1 | |||
) |
MODULE_VERSION | ( | uhso | , |
1 | |||
) |
SYSCTL_INT | ( | _hw_usb_uhso | , |
OID_AUTO | , | ||
auto_switch | , | ||
CTLFLAG_RWTUN | , | ||
& | uhso_autoswitch, | ||
0 | , | ||
"Automatically switch to modem mode" | |||
) |
|
static |
UCOM_UNLOAD_DRAIN | ( | uhso | ) |
|
static |
Definition at line 1012 of file uhso.c.
References uhso_tty::ht_sc, uhso_softc::sc_tty, uhso_softc::sc_ttys, uhso_softc::sc_ucom, and UHSO_DPRINTF.
Referenced by uhso_attach_bulkserial(), and uhso_attach_muxserial().
|
static |
Definition at line 546 of file uhso.c.
References usbd_lookup_info::bIfaceIndex, usbd_lookup_info::bIfaceNum, desc, usb_attach_arg::device, error, uhso_tty::ht_muxport, uhso_tty::ht_name, id, usb_attach_arg::iface, usb_attach_arg::info, uhso_softc::sc_ctrl_iface_no, uhso_softc::sc_ctrl_xfer, uhso_softc::sc_dev, uhso_softc::sc_iface_index, uhso_softc::sc_iface_no, uhso_softc::sc_mtx, uhso_softc::sc_radio, uhso_softc::sc_rxq, ucom_softc::sc_subunit, ucom_softc::sc_super, uhso_softc::sc_super_ucom, uhso_softc::sc_tty, uhso_softc::sc_ttys, uhso_softc::sc_type, uhso_softc::sc_ucom, uhso_softc::sc_udev, ucom_super_softc::sc_unit, ucom_ref(), UHSO_AUTO_IFACE, uhso_ctrl_config, UHSO_CTRL_MAX, uhso_detach, UHSO_IF_MUX, UHSO_IFACE_PORT, UHSO_IFACE_PORT_TYPE, UHSO_IFACE_USB_TYPE, uhso_mux_port_map, uhso_port, uhso_port_type, uhso_port_type_sysctl, uhso_probe_iface(), uhso_probe_iface_auto(), uhso_probe_iface_static(), uhso_radio_sysctl(), UHSO_STATIC_IFACE, USB_GET_DRIVER_INFO, usb_get_manufacturer(), usb_get_product(), usbd_errstr(), usbd_get_interface_descriptor(), and usbd_transfer_setup().
|
static |
Definition at line 1268 of file uhso.c.
References usb_interface_descriptor::bInterfaceNumber, uhso_tty::ht_muxport, usb_interface::idesc, uhso_softc::sc_mtx, uhso_softc::sc_tty, uhso_softc::sc_udev, uhso_softc::sc_xfer, uhso_alloc_tty(), uhso_bs_config, UHSO_BULK_ENDPT_MAX, UHSO_DPRINTF, usbd_transfer_setup(), and usbd_transfer_unsetup().
Referenced by uhso_probe_iface().
|
static |
Definition at line 1554 of file uhso.c.
References usb_interface_descriptor::bInterfaceNumber, usb_interface::idesc, uhso_softc::sc_c, uhso_softc::sc_dev, uhso_softc::sc_if_xfer, uhso_softc::sc_ifp, uhso_softc::sc_mtx, uhso_softc::sc_udev, UHSO_DPRINTF, uhso_if_init(), uhso_if_ioctl(), uhso_if_output(), uhso_if_rxflush(), uhso_if_start(), uhso_ifnet_config, UHSO_IFNET_MAX, uhso_ifnet_unit, UHSO_MAX_MTU, usbd_errstr(), and usbd_transfer_setup().
Referenced by uhso_probe_iface().
|
static |
Definition at line 1038 of file uhso.c.
References usb_interface_descriptor::bInterfaceNumber, desc, uhso_tty::ht_muxport, uhso_tty::ht_xfer, usb_interface::idesc, uhso_softc::sc_dev, uhso_softc::sc_iface_index, uhso_softc::sc_mtx, uhso_softc::sc_tty, uhso_softc::sc_udev, uhso_softc::sc_xfer, UDESC_CS_INTERFACE, uhso_alloc_tty(), uhso_ctrl_config, UHSO_CTRL_MAX, UHSO_DPRINTF, uhso_mux_config, usbd_errstr(), usbd_find_descriptor(), and usbd_transfer_setup().
Referenced by uhso_probe_iface().
|
static |
Definition at line 1361 of file uhso.c.
References req, uhso_softc::sc_dev, uhso_softc::sc_iface_no, uhso_softc::sc_line, uhso_softc::sc_type, uhso_softc::sc_ucom, uhso_softc::sc_udev, UCDC_SET_CONTROL_LINE_STATE, ucom_cfg_do_request, UHSO_IF_BULK, UHSO_IFACE_USB_TYPE, usbd_errstr(), USETW, and UT_WRITE_CLASS_INTERFACE.
Referenced by uhso_ucom_cfg_set_dtr(), and uhso_ucom_cfg_set_rts().
|
static |
Definition at line 1383 of file uhso.c.
References usb_cdc_notification::bmRequestType, usb_cdc_notification::bNotification, usb_cdc_notification::data, error, uhso_softc::sc_iface_no, uhso_softc::sc_lsr, uhso_softc::sc_msr, uhso_softc::sc_ucom, UCDC_N_SERIAL_DCD, UCDC_N_SERIAL_DSR, UCDC_N_SERIAL_RI, UCDC_N_SERIAL_STATE, UCDC_NOTIFICATION, UCDC_NOTIFICATION_LENGTH, ucom_status_change(), UGETW, UHSO_DPRINTF, USB_ERR_CANCELLED, USB_GET_STATE, USB_ST_SETUP, USB_ST_TRANSFERRED, usbd_copy_out(), usbd_xfer_get_frame(), usbd_xfer_set_stall(), usbd_xfer_softc(), usbd_xfer_status(), and usb_cdc_notification::wIndex.
|
static |
Definition at line 1300 of file uhso.c.
References error, uhso_softc::sc_ucom, ucom_put_data(), UHSO_DPRINTF, USB_ERR_CANCELLED, USB_GET_STATE, USB_ST_SETUP, USB_ST_TRANSFERRED, usbd_errstr(), usbd_transfer_submit(), usbd_xfer_get_frame(), usbd_xfer_max_len(), usbd_xfer_set_frame_len(), usbd_xfer_set_stall(), usbd_xfer_softc(), and usbd_xfer_status().
|
static |
Definition at line 1330 of file uhso.c.
References error, uhso_softc::sc_ucom, ucom_get_data(), UHSO_DPRINTF, USB_ERR_CANCELLED, USB_GET_STATE, USB_ST_SETUP, USB_ST_TRANSFERRED, usbd_errstr(), usbd_transfer_submit(), usbd_xfer_get_frame(), usbd_xfer_set_frame_len(), usbd_xfer_set_stall(), usbd_xfer_softc(), and usbd_xfer_status().
|
static |
Definition at line 671 of file uhso.c.
References uhso_tty::ht_muxport, uhso_tty::ht_xfer, uhso_softc::sc_c, uhso_softc::sc_ctrl_xfer, uhso_softc::sc_if_xfer, uhso_softc::sc_ifp, uhso_softc::sc_mtx, uhso_softc::sc_super_ucom, uhso_softc::sc_tty, uhso_softc::sc_ttys, uhso_softc::sc_ucom, uhso_softc::sc_xfer, ucom_detach(), UHSO_CTRL_MAX, uhso_free_softc(), uhso_if_stop(), UHSO_IFNET_MAX, uhso_ifnet_unit, and usbd_transfer_unsetup().
|
static |
Definition at line 753 of file uhso.c.
References uhso_etag, uhso_ifnet_unit, and uhso_test_autoinst().
|
static |
Definition at line 722 of file uhso.c.
References ucom_softc::sc_parent, and uhso_free_softc().
|
static |
Definition at line 711 of file uhso.c.
References uhso_softc::sc_mtx, uhso_softc::sc_super_ucom, uhso_softc::sc_tty, uhso_softc::sc_ucom, and ucom_unref().
Referenced by uhso_detach(), and uhso_free().
|
static |
Definition at line 1873 of file uhso.c.
References uhso_softc::sc_ifp, uhso_softc::sc_mtx, UHSO_DPRINTF, and uhso_if_stop().
Referenced by uhso_attach_ifnet(), and uhso_if_ioctl().
|
static |
Definition at line 1841 of file uhso.c.
References uhso_softc::sc_mtx, uhso_if_init(), and uhso_if_stop().
Referenced by uhso_attach_ifnet().
|
static |
Definition at line 1889 of file uhso.c.
References error.
Referenced by uhso_attach_ifnet().
|
static |
Definition at line 1664 of file uhso.c.
References uhso_softc::sc_ifp, uhso_softc::sc_mtx, uhso_softc::sc_mwait, uhso_softc::sc_rxq, UHSO_DPRINTF, and UHSO_HEXDUMP.
Referenced by uhso_attach_ifnet().
|
static |
Definition at line 1913 of file uhso.c.
References uhso_softc::sc_if_xfer, uhso_softc::sc_mtx, UHSO_DPRINTF, UHSO_IFNET_READ, UHSO_IFNET_WRITE, and usbd_transfer_start().
Referenced by uhso_attach_ifnet().
|
static |
Definition at line 1930 of file uhso.c.
References uhso_softc::sc_if_xfer, uhso_softc::sc_ifp, UHSO_IFNET_READ, UHSO_IFNET_WRITE, and usbd_transfer_stop().
Referenced by uhso_detach(), uhso_if_init(), and uhso_if_ioctl().
|
static |
Definition at line 1614 of file uhso.c.
References error, uhso_softc::sc_c, uhso_softc::sc_ifp, uhso_softc::sc_rxq, UHSO_DPRINTF, USB_ERR_CANCELLED, USB_GET_STATE, USB_ST_SETUP, USB_ST_TRANSFERRED, usbd_copy_out(), usbd_errstr(), usbd_transfer_submit(), usbd_xfer_get_frame(), usbd_xfer_max_len(), usbd_xfer_set_frame_len(), usbd_xfer_set_stall(), usbd_xfer_softc(), and usbd_xfer_status().
|
static |
Definition at line 1796 of file uhso.c.
References error, uhso_softc::sc_ifp, UHSO_DPRINTF, USB_ERR_CANCELLED, USB_GET_STATE, USB_ST_SETUP, USB_ST_TRANSFERRED, usbd_errstr(), usbd_m_copy_in(), usbd_transfer_submit(), usbd_xfer_get_frame(), usbd_xfer_set_frame_len(), usbd_xfer_set_stall(), usbd_xfer_softc(), and usbd_xfer_status().
|
static |
Definition at line 1100 of file uhso.c.
References usb_page_search::buffer, error, uhso_tty::ht_xfer, uhso_softc::sc_tty, UHSO_CTRL_READ, UHSO_DPRINTF, UHSO_MPORT_TYPE_NOMAX, USB_ERR_CANCELLED, USB_GET_STATE, USB_ST_SETUP, USB_ST_TRANSFERRED, usbd_errstr(), usbd_get_page(), usbd_transfer_start(), usbd_transfer_submit(), usbd_xfer_get_frame(), usbd_xfer_max_len(), usbd_xfer_set_frame_len(), usbd_xfer_set_priv(), usbd_xfer_set_stall(), and usbd_xfer_softc().
|
static |
Definition at line 1151 of file uhso.c.
References error, uhso_tty::ht_muxport, uhso_tty::ht_open, len, req, uhso_softc::sc_ucom, uhso_softc::sc_xfer, UCDC_GET_ENCAPSULATED_RESPONSE, ucom_put_data(), UHSO_DPRINTF, UHSO_MUX_ENDPT_INTR, USB_ERR_CANCELLED, USB_GET_STATE, USB_ST_SETUP, USB_ST_TRANSFERRED, usbd_copy_in(), usbd_errstr(), usbd_transfer_start(), usbd_transfer_submit(), usbd_xfer_frame_len(), usbd_xfer_get_frame(), usbd_xfer_get_priv(), usbd_xfer_set_frame_len(), usbd_xfer_set_frames(), usbd_xfer_set_stall(), usbd_xfer_softc(), usbd_xfer_status(), USETW, and UT_READ_CLASS_INTERFACE.
|
static |
Definition at line 1210 of file uhso.c.
References error, uhso_tty::ht_muxport, req, uhso_softc::sc_ucom, UCDC_SEND_ENCAPSULATED_COMMAND, ucom_get_data(), UHSO_DPRINTF, USB_ERR_CANCELLED, USB_GET_STATE, USB_ST_SETUP, USB_ST_TRANSFERRED, usbd_copy_in(), usbd_errstr(), usbd_get_page(), usbd_transfer_submit(), usbd_xfer_get_frame(), usbd_xfer_get_priv(), usbd_xfer_set_frame_len(), usbd_xfer_set_frames(), usbd_xfer_set_stall(), usbd_xfer_softc(), usbd_xfer_status(), USETW, and UT_WRITE_CLASS_INTERFACE.
|
static |
Definition at line 517 of file uhso.c.
References usbd_lookup_info::bConfigIndex, usbd_lookup_info::bDeviceClass, usbd_lookup_info::bIfaceNum, usb_attach_arg::device, error, usb_attach_arg::info, UHSO_AUTO_IFACE, uhso_devs, uhso_probe_iface_auto(), USB_GET_DRIVER_INFO, usb_attach_arg::usb_mode, USB_MODE_HOST, and usbd_lookup_id_by_uaa().
|
static |
Definition at line 892 of file uhso.c.
References usb_interface_descriptor::bNumEndpoints, error, usb_interface::idesc, index, uhso_softc::sc_dev, uhso_softc::sc_mtx, uhso_softc::sc_super_ucom, uhso_softc::sc_ttys, uhso_softc::sc_type, uhso_softc::sc_ucom, uhso_softc::sc_udev, uhso_softc::sc_xfer, type, ucom_attach(), ucom_set_pnpinfo_usb(), uhso_attach_bulkserial(), uhso_attach_ifnet(), uhso_attach_muxserial(), UHSO_DPRINTF, UHSO_IF_BULK, UHSO_IF_MUX, UHSO_IFACE_PORT, UHSO_IFACE_PORT_TYPE, UHSO_IFACE_SPEC, UHSO_IFACE_USB_TYPE, UHSO_MUX_ENDPT_INTR, UHSO_PORT_SERIAL, UHSO_PORT_TYPE_NETWORK, uhso_ucom_callback, usbd_get_iface(), and usbd_transfer_start().
Referenced by uhso_attach().
|
static |
Definition at line 779 of file uhso.c.
References index, req, UHSO_DPRINTF, UHSO_HEXDUMP, UHSO_IF_BULK, UHSO_IF_MUX, UHSO_IF_NET, UHSO_IFACE_SPEC, uhso_port_map, uhso_port_map_max, UHSO_PORT_NETWORK, UHSO_PORT_SERIAL, uhso_port_type, UHSO_PORT_TYPE_APP, UHSO_PORT_TYPE_APP2, UHSO_PORT_TYPE_CTL, UHSO_PORT_TYPE_DIAG, UHSO_PORT_TYPE_DIAG2, UHSO_PORT_TYPE_GPS, UHSO_PORT_TYPE_GPSCTL, UHSO_PORT_TYPE_MODEM, UHSO_PORT_TYPE_MSD, UHSO_PORT_TYPE_NETWORK, UHSO_PORT_TYPE_UNKNOWN, USB_MS_HZ, usbd_do_request_flags(), usbd_errstr(), USETW, and UT_READ_VENDOR_DEVICE.
Referenced by uhso_attach(), and uhso_probe().
|
static |
Definition at line 847 of file uhso.c.
References usb_config_descriptor::bNumInterface, index, UHSO_IF_BULK, UHSO_IF_MUX, UHSO_IF_NET, UHSO_IFACE_SPEC, UHSO_PORT_NETWORK, UHSO_PORT_SERIAL, UHSO_PORT_TYPE_DIAG, UHSO_PORT_TYPE_DIAG2, UHSO_PORT_TYPE_MODEM, UHSO_PORT_TYPE_NETWORK, and usbd_get_config_descriptor().
Referenced by uhso_attach().
|
static |
Definition at line 966 of file uhso.c.
References req, uhso_softc::sc_dev, uhso_softc::sc_udev, usbd_do_request, usbd_errstr(), USETW, and UT_VENDOR.
Referenced by uhso_radio_sysctl().
|
static |
Definition at line 987 of file uhso.c.
References error, req, uhso_softc::sc_radio, and uhso_radio_ctrl().
Referenced by uhso_attach().
|
static |
Definition at line 728 of file uhso.c.
References usb_attach_arg::dev_state, id, usb_interface::idesc, MSC_EJECT_REZERO, UAA_DEV_EJECTING, UAA_DEV_READY, uhso_autoswitch, uhso_devs, UICLASS_MASS, usb_msc_eject(), usbd_get_iface(), and usbd_lookup_id_by_uaa().
Referenced by uhso_driver_loaded().
|
static |
Definition at line 1439 of file uhso.c.
References uhso_softc::sc_lsr, uhso_softc::sc_msr, and ucom_softc::sc_parent.
|
static |
Definition at line 1448 of file uhso.c.
References uhso_softc::sc_line, ucom_softc::sc_parent, uhso_softc::sc_type, UCDC_LINE_DTR, uhso_bs_cfg(), UHSO_IF_BULK, and UHSO_IFACE_USB_TYPE.
|
static |
Definition at line 1464 of file uhso.c.
References uhso_softc::sc_line, ucom_softc::sc_parent, uhso_softc::sc_type, UCDC_LINE_RTS, uhso_bs_cfg(), UHSO_IF_BULK, and UHSO_IFACE_USB_TYPE.
|
static |
Definition at line 1480 of file uhso.c.
References uhso_tty::ht_open, ucom_softc::sc_parent, ucom_softc::sc_subunit, ucom_softc::sc_super, uhso_softc::sc_tty, uhso_softc::sc_type, ucom_super_softc::sc_unit, uhso_softc::sc_xfer, UHSO_BULK_ENDPT_INTR, UHSO_BULK_ENDPT_READ, UHSO_DPRINTF, UHSO_IF_BULK, UHSO_IF_MUX, UHSO_IFACE_USB_TYPE, UHSO_MUX_ENDPT_INTR, and usbd_transfer_start().
|
static |
Definition at line 1519 of file uhso.c.
References uhso_tty::ht_xfer, ucom_softc::sc_parent, ucom_softc::sc_subunit, uhso_softc::sc_tty, uhso_softc::sc_type, uhso_softc::sc_xfer, UHSO_BULK_ENDPT_WRITE, UHSO_CTRL_WRITE, UHSO_DPRINTF, UHSO_IF_BULK, UHSO_IF_MUX, UHSO_IFACE_USB_TYPE, UHSO_MUX_ENDPT_INTR, usbd_transfer_start(), and usbd_xfer_set_priv().
|
static |
Definition at line 1500 of file uhso.c.
References uhso_tty::ht_open, uhso_tty::ht_xfer, ucom_softc::sc_parent, ucom_softc::sc_subunit, uhso_softc::sc_tty, uhso_softc::sc_type, uhso_softc::sc_xfer, UHSO_BULK_ENDPT_INTR, UHSO_BULK_ENDPT_READ, UHSO_CTRL_READ, UHSO_IF_BULK, UHSO_IF_MUX, UHSO_IFACE_USB_TYPE, usbd_transfer_start(), and usbd_transfer_stop().
|
static |
Definition at line 1540 of file uhso.c.
References uhso_tty::ht_xfer, ucom_softc::sc_parent, ucom_softc::sc_subunit, uhso_softc::sc_tty, uhso_softc::sc_type, uhso_softc::sc_xfer, UHSO_BULK_ENDPT_WRITE, UHSO_CTRL_WRITE, UHSO_IF_BULK, UHSO_IF_MUX, UHSO_IFACE_USB_TYPE, and usbd_transfer_stop().
USB_PNP_HOST_INFO | ( | uhso_devs | ) |
|
static |
Definition at line 293 of file uhso.c.
Referenced by uhso_test_autoinst().
|
static |
Definition at line 419 of file uhso.c.
Referenced by uhso_attach_bulkserial().
|
static |
|
static |
|
static |
|
static |
Definition at line 364 of file uhso.c.
Referenced by uhso_attach(), and uhso_attach_muxserial().
|
static |
Definition at line 482 of file uhso.c.
Referenced by uhso_attach().
|
static |
Definition at line 253 of file uhso.c.
Referenced by uhso_probe(), and uhso_test_autoinst().
|
static |
|
static |
Definition at line 176 of file uhso.c.
Referenced by uhso_driver_loaded().
|
static |
Definition at line 398 of file uhso.c.
Referenced by uhso_attach_ifnet().
|
static |
|
static |
Definition at line 251 of file uhso.c.
Referenced by uhso_attach_ifnet(), uhso_detach(), and uhso_driver_loaded().
|
static |
|
static |
|
static |
Definition at line 386 of file uhso.c.
Referenced by uhso_attach_muxserial().
|
static |
|
static |
|
static |
|
static |
|
static |
Definition at line 179 of file uhso.c.
Referenced by uhso_attach().
|
static |
|
static |
Definition at line 205 of file uhso.c.
Referenced by uhso_probe_iface_auto().
|
static |
Definition at line 215 of file uhso.c.
Referenced by uhso_attach(), and uhso_probe_iface_auto().
|
static |
Definition at line 231 of file uhso.c.
Referenced by uhso_attach().
|
static |
Definition at line 505 of file uhso.c.
Referenced by uhso_probe_iface().