revert android-tegra-2.6.36-honeycomb-mr1-9001adc to v2.6.36
[firefly-linux-kernel-4.4.55.git] / drivers / staging / usbip / vhci_hcd.c
index c2018029059c5ce35b17a1965b443f586c1ceec7..0574d848b9000045c48b6b618b80a5e34b888205 100644 (file)
@@ -17,6 +17,7 @@
  * USA.
  */
 
+#include <linux/slab.h>
 
 #include "usbip_common.h"
 #include "vhci.h"
@@ -56,7 +57,7 @@ static void vhci_stop(struct usb_hcd *hcd);
 static int vhci_get_frame_number(struct usb_hcd *hcd);
 
 static const char driver_name[] = "vhci_hcd";
-static const char driver_desc[] = "USB/IP Virtual Host Contoroller";
+static const char driver_desc[] = "USB/IP Virtual Host Controller";
 
 struct vhci_hcd *the_controller;
 
@@ -163,8 +164,6 @@ void rh_port_disconnect(int rhport)
         * spin_unlock(&vdev->ud.lock); */
 
        spin_unlock_irqrestore(&the_controller->lock, flags);
-
-       usb_hcd_poll_rh_status(vhci_to_hcd(the_controller));
 }
 
 
@@ -216,7 +215,7 @@ static int vhci_hub_status(struct usb_hcd *hcd, char *buf)
        vhci = hcd_to_vhci(hcd);
 
        spin_lock_irqsave(&vhci->lock, flags);
-       if (!test_bit(HCD_FLAG_HW_ACCESSIBLE, &hcd->flags)) {
+       if (!HCD_HW_ACCESSIBLE(hcd)) {
                usbip_dbg_vhci_rh("hw accessible flag in on?\n");
                goto done;
        }
@@ -270,7 +269,7 @@ static int vhci_hub_control(struct usb_hcd *hcd, u16 typeReq, u16 wValue,
 
        u32 prev_port_status[VHCI_NPORTS];
 
-       if (!test_bit(HCD_FLAG_HW_ACCESSIBLE, &hcd->flags))
+       if (!HCD_HW_ACCESSIBLE(hcd))
                return -ETIMEDOUT;
 
        /*
@@ -1042,7 +1041,7 @@ static int vhci_bus_resume(struct usb_hcd *hcd)
        dev_dbg(&hcd->self.root_hub->dev, "%s\n", __func__);
 
        spin_lock_irq(&vhci->lock);
-       if (!test_bit(HCD_FLAG_HW_ACCESSIBLE, &hcd->flags)) {
+       if (!HCD_HW_ACCESSIBLE(hcd)) {
                rc = -ESHUTDOWN;
        } else {
                /* vhci->rh_state = DUMMY_RH_RUNNING;
@@ -1073,7 +1072,7 @@ static struct hc_driver vhci_hc_driver = {
        .flags          = HCD_USB2,
 
        .start          = vhci_start,
-       .stop           = vhci_stop,
+       .stop           = vhci_stop,
 
        .urb_enqueue    = vhci_urb_enqueue,
        .urb_dequeue    = vhci_urb_dequeue,