diff options
| author | Dan Streetman <ddstreet@us.ibm.com> | 2002-04-07 20:51:56 -0700 |
|---|---|---|
| committer | Greg Kroah-Hartman <greg@kroah.com> | 2002-04-07 20:51:56 -0700 |
| commit | b46bff09512a21fd9e58c4cf4205b4a635d1f020 (patch) | |
| tree | d1e4412a618a53f66cc59ddea5579b1235065d0a /include/linux | |
| parent | a64c6e4b0a5b33bfa6c63fba12489d36a923f3f6 (diff) | |
[PATCH] usbfs disconnect
This was originally created by David many months ago and posted to the
list, but not put into the kernel.
I modified the original patch to:
-patch against the 2.5.7 kernel
-use the 'real' interface number, not position (to do this I added 2
methods in usb.c)
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/usb.h | 2 | ||||
| -rw-r--r-- | include/linux/usbdevice_fs.h | 2 |
2 files changed, 4 insertions, 0 deletions
diff --git a/include/linux/usb.h b/include/linux/usb.h index 3b5c1df0ba46..2b7b4d39b590 100644 --- a/include/linux/usb.h +++ b/include/linux/usb.h @@ -305,6 +305,7 @@ struct usb_qualifier_descriptor { } __attribute__ ((packed)); /* helpers for driver access to descriptors */ +extern int usb_ifnum_to_ifpos(struct usb_device *dev, unsigned ifnum); extern struct usb_interface * usb_ifnum_to_if(struct usb_device *dev, unsigned ifnum); extern struct usb_endpoint_descriptor * @@ -1052,6 +1053,7 @@ extern void usb_inc_dev_use(struct usb_device *); #define usb_dec_dev_use usb_free_dev /* used these for multi-interface device registration */ +extern int usb_find_interface_driver_for_ifnum(struct usb_device *dev, unsigned int ifnum); extern void usb_driver_claim_interface(struct usb_driver *driver, struct usb_interface *iface, void* priv); extern int usb_interface_claimed(struct usb_interface *iface); diff --git a/include/linux/usbdevice_fs.h b/include/linux/usbdevice_fs.h index 0bf98f1d598b..10a508f55a07 100644 --- a/include/linux/usbdevice_fs.h +++ b/include/linux/usbdevice_fs.h @@ -142,6 +142,8 @@ struct usbdevfs_hub_portinfo { #define USBDEVFS_HUB_PORTINFO _IOR('U', 19, struct usbdevfs_hub_portinfo) #define USBDEVFS_RESET _IO('U', 20) #define USBDEVFS_CLEAR_HALT _IOR('U', 21, unsigned int) +#define USBDEVFS_DISCONNECT _IO('U', 22) +#define USBDEVFS_CONNECT _IO('U', 23) /* --------------------------------------------------------------------- */ |
