|
@@ -860,6 +860,7 @@ static int hub_post_reset(struct usb_interface *intf)
|
|
|
static int hub_configure(struct usb_hub *hub,
|
|
|
struct usb_endpoint_descriptor *endpoint)
|
|
|
{
|
|
|
+ struct usb_hcd *hcd;
|
|
|
struct usb_device *hdev = hub->hdev;
|
|
|
struct device *hub_dev = hub->intfdev;
|
|
|
u16 hubstatus, hubchange;
|
|
@@ -1061,6 +1062,19 @@ static int hub_configure(struct usb_hub *hub,
|
|
|
dev_dbg(hub_dev, "%umA bus power budget for each child\n",
|
|
|
hub->mA_per_port);
|
|
|
|
|
|
+ /* Update the HCD's internal representation of this hub before khubd
|
|
|
+ * starts getting port status changes for devices under the hub.
|
|
|
+ */
|
|
|
+ hcd = bus_to_hcd(hdev->bus);
|
|
|
+ if (hcd->driver->update_hub_device) {
|
|
|
+ ret = hcd->driver->update_hub_device(hcd, hdev,
|
|
|
+ &hub->tt, GFP_KERNEL);
|
|
|
+ if (ret < 0) {
|
|
|
+ message = "can't update HCD hub info";
|
|
|
+ goto fail;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
ret = hub_hub_status(hub, &hubstatus, &hubchange);
|
|
|
if (ret < 0) {
|
|
|
message = "can't get hub status";
|