diff options
| author | 2005-11-23 12:09:52 -0500 | |
|---|---|---|
| committer | 2006-01-04 13:48:35 -0800 | |
| commit | 12c3da346eb81b6a281031f62eda3bca993dff5a (patch) | |
| tree | 428ac85a5ebf1564aa4254dcf625174ef36452d9 /drivers/usb/core/usb.c | |
| parent | [PATCH] USB: Consider power budget when choosing configuration (diff) | |
| download | linux-dev-12c3da346eb81b6a281031f62eda3bca993dff5a.tar.xz linux-dev-12c3da346eb81b6a281031f62eda3bca993dff5a.zip | |
[PATCH] USB: Store port number in usb_device
This patch (as610) adds a field to struct usb_device to store the device's
port number. This allows us to remove several loops in the hub driver
(searching for a particular device among all the entries in the parent's
array of children).
Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/core/usb.c')
| -rw-r--r-- | drivers/usb/core/usb.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/usb/core/usb.c b/drivers/usb/core/usb.c index fcfda21be499..39e6b61b898a 100644 --- a/drivers/usb/core/usb.c +++ b/drivers/usb/core/usb.c @@ -439,6 +439,7 @@ usb_alloc_dev(struct usb_device *parent, struct usb_bus *bus, unsigned port1) /* hub driver sets up TT records */ } + dev->portnum = port1; dev->bus = bus; dev->parent = parent; INIT_LIST_HEAD(&dev->filelist); |
