The structure member prefixes added in sys/dev/usb/usb.h 1.62 were
missing from the man page.
This commit is contained in:
parent
57fa6bb861
commit
c43379aa3e
|
@ -1,4 +1,4 @@
|
|||
.\" $NetBSD: ugen.4,v 1.15 2002/02/13 08:17:50 ross Exp $
|
||||
.\" $NetBSD: ugen.4,v 1.16 2003/12/14 21:12:26 gson Exp $
|
||||
.\"
|
||||
.\" Copyright (c) 1999 The NetBSD Foundation, Inc.
|
||||
.\" All rights reserved.
|
||||
|
@ -134,23 +134,23 @@ The
|
|||
is ignored in this call.
|
||||
.Bd -literal
|
||||
struct usb_alt_interface {
|
||||
int config_index;
|
||||
int interface_index;
|
||||
int alt_no;
|
||||
int uai_config_index;
|
||||
int aui_interface_index;
|
||||
int uai_alt_no;
|
||||
};
|
||||
.Ed
|
||||
.It Dv USB_SET_ALTINTERFACE (struct usb_alt_interface)
|
||||
Set the alternative setting to the given number in the interface with the
|
||||
given index.
|
||||
The
|
||||
.Dv config_index
|
||||
.Dv uai_config_index
|
||||
is ignored in this call.
|
||||
.br
|
||||
This operation can only be performed when no endpoints for the interface
|
||||
are open.
|
||||
.It Dv USB_GET_NO_ALT (struct usb_alt_interface)
|
||||
Return the number of different alternate settings in the
|
||||
.Dv alt_no
|
||||
.Dv aui_alt_no
|
||||
field.
|
||||
.It Dv USB_GET_DEVICE_DESC (usb_device_descriptor_t)
|
||||
Return the device descriptor.
|
||||
|
@ -160,8 +160,8 @@ For convenience the current configuration can be specified by
|
|||
.Dv USB_CURRENT_CONFIG_INDEX .
|
||||
.Bd -literal
|
||||
struct usb_config_desc {
|
||||
int config_index;
|
||||
usb_config_descriptor_t desc;
|
||||
int ucd_config_index;
|
||||
usb_config_descriptor_t ucd_desc;
|
||||
};
|
||||
.Ed
|
||||
.It Dv USB_GET_INTERFACE_DESC (struct usb_interface_desc)
|
||||
|
@ -171,10 +171,10 @@ For convenience the current alternative can be specified by
|
|||
.Dv USB_CURRENT_ALT_INDEX .
|
||||
.Bd -literal
|
||||
struct usb_interface_desc {
|
||||
int config_index;
|
||||
int interface_index;
|
||||
int alt_index;
|
||||
usb_interface_descriptor_t desc;
|
||||
int uid_config_index;
|
||||
int uid_interface_index;
|
||||
int uid_alt_index;
|
||||
usb_interface_descriptor_t uid_desc;
|
||||
};
|
||||
.Ed
|
||||
.It Dv USB_GET_ENDPOINT_DESC (struct usb_endpoint_desc)
|
||||
|
@ -183,26 +183,26 @@ configuration index, interface index, alternative index, and
|
|||
endpoint index.
|
||||
.Bd -literal
|
||||
struct usb_endpoint_desc {
|
||||
int config_index;
|
||||
int interface_index;
|
||||
int alt_index;
|
||||
int endpoint_index;
|
||||
usb_endpoint_descriptor_t desc;
|
||||
int ued_config_index;
|
||||
int ued_interface_index;
|
||||
int ued_alt_index;
|
||||
int ued_endpoint_index;
|
||||
usb_endpoint_descriptor_t ued_desc;
|
||||
};
|
||||
.Ed
|
||||
.It Dv USB_GET_FULL_DESC (struct usb_full_desc)
|
||||
Return all the descriptors for the given configuration.
|
||||
.Bd -literal
|
||||
struct usb_full_desc {
|
||||
int config_index;
|
||||
u_int size;
|
||||
u_char *data;
|
||||
int ufd_config_index;
|
||||
u_int ufd_size;
|
||||
u_char *ufd_data;
|
||||
};
|
||||
.Ed
|
||||
The
|
||||
.Dv data
|
||||
.Dv ufd_data
|
||||
field should point to a memory area of of the size given in the
|
||||
.Dv size
|
||||
.Dv ufd_size
|
||||
field. The proper size can be determined by first issuing a
|
||||
.Dv USB_GET_CONFIG_DESC
|
||||
and inspecting the
|
||||
|
@ -213,9 +213,9 @@ Get a string descriptor for the given language id and
|
|||
string index.
|
||||
.Bd -literal
|
||||
struct usb_string_desc {
|
||||
int string_index;
|
||||
int language_id;
|
||||
usb_string_descriptor_t desc;
|
||||
int usd_string_index;
|
||||
int usd_language_id;
|
||||
usb_string_descriptor_t usd_desc;
|
||||
};
|
||||
.Ed
|
||||
.It Dv USB_DO_REQUEST
|
||||
|
@ -225,22 +225,22 @@ Any data sent to/from the device is located at
|
|||
The size of the transferred data is determined from the
|
||||
.Dv request .
|
||||
The
|
||||
.Dv addr
|
||||
.Dv ucr_addr
|
||||
field is ignored in this call.
|
||||
The
|
||||
.Dv flags
|
||||
.Dv ucr_flags
|
||||
field can be used to flag that the request is allowed to
|
||||
be shorter than the requested size, and the
|
||||
.Dv actlen
|
||||
will contain the actual size on completion.
|
||||
.Dv ucr_actlen
|
||||
field will contain the actual size on completion.
|
||||
.Bd -literal
|
||||
struct usb_ctl_request {
|
||||
int addr;
|
||||
usb_device_request_t request;
|
||||
void *data;
|
||||
int flags;
|
||||
int ucr_addr;
|
||||
usb_device_request_t ucr_request;
|
||||
void *ucr_data;
|
||||
int ucr_flags;
|
||||
#define USBD_SHORT_XFER_OK 0x04 /* allow short reads */
|
||||
int actlen; /* actual length transferred */
|
||||
int ucr_actlen; /* actual length transferred */
|
||||
};
|
||||
.Ed
|
||||
This is a dangerous operation in that it can perform arbitrary operations
|
||||
|
|
Loading…
Reference in New Issue