summaryrefslogtreecommitdiff
path: root/drivers/usb/core/usb.c
diff options
context:
space:
mode:
authorMing Lei <tom.leiming@gmail.com>2010-05-17 22:20:50 +0800
committerGreg Kroah-Hartman <gregkh@suse.de>2010-05-20 13:21:47 -0700
commitc024b7260c8f879a2ef3a3e6a853b579a46479f8 (patch)
tree339346367d1558d61956c965c51d0733dbe10616 /drivers/usb/core/usb.c
parent0858a3a52f659dabf2860f350e5a6a61f069e851 (diff)
USB: remove match_device
usb_find_device was the only one user of match_device, now it is removed, so remove match_device to fix the compile warning below reported by Stephen Rothwell: drivers/usb/core/usb.c:596: warning: 'match_device' defined but not used Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Ming Lei <tom.leiming@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/core/usb.c')
-rw-r--r--drivers/usb/core/usb.c33
1 files changed, 0 insertions, 33 deletions
diff --git a/drivers/usb/core/usb.c b/drivers/usb/core/usb.c
index 902f821d8d14..397b678f1c47 100644
--- a/drivers/usb/core/usb.c
+++ b/drivers/usb/core/usb.c
@@ -593,39 +593,6 @@ int usb_lock_device_for_reset(struct usb_device *udev,
}
EXPORT_SYMBOL_GPL(usb_lock_device_for_reset);
-static struct usb_device *match_device(struct usb_device *dev,
- u16 vendor_id, u16 product_id)
-{
- struct usb_device *ret_dev = NULL;
- int child;
-
- dev_dbg(&dev->dev, "check for vendor %04x, product %04x ...\n",
- le16_to_cpu(dev->descriptor.idVendor),
- le16_to_cpu(dev->descriptor.idProduct));
-
- /* see if this device matches */
- if ((vendor_id == le16_to_cpu(dev->descriptor.idVendor)) &&
- (product_id == le16_to_cpu(dev->descriptor.idProduct))) {
- dev_dbg(&dev->dev, "matched this device!\n");
- ret_dev = usb_get_dev(dev);
- goto exit;
- }
-
- /* look through all of the children of this device */
- for (child = 0; child < dev->maxchild; ++child) {
- if (dev->children[child]) {
- usb_lock_device(dev->children[child]);
- ret_dev = match_device(dev->children[child],
- vendor_id, product_id);
- usb_unlock_device(dev->children[child]);
- if (ret_dev)
- goto exit;
- }
- }
-exit:
- return ret_dev;
-}
-
/**
* usb_get_current_frame_number - return current bus frame number
* @dev: the device whose bus is being queried