summaryrefslogtreecommitdiff
path: root/drivers/usb/gadget
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-08-27 14:15:30 (GMT)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-08-27 14:15:30 (GMT)
commita7bdf7fa33127bf08eb0810698bca607a9462df4 (patch)
tree2f4be686e49710d10cc4f5ebc2d5f06ae030b9bd /drivers/usb/gadget
parent7fda953ffed1b94aa68f80c6c3ab312328aedcb3 (diff)
parentfea7a08acb13524b47711625eebea40a0ede69a0 (diff)
downloadlinux-fsl-qoriq-a7bdf7fa33127bf08eb0810698bca607a9462df4.tar.xz
Merge v3.6-rc3 into usb-next
This picks up fixes that we need in this branch for testing. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/gadget')
-rw-r--r--drivers/usb/gadget/u_ether.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/usb/gadget/u_ether.c b/drivers/usb/gadget/u_ether.c
index 90e82e2..0e52309 100644
--- a/drivers/usb/gadget/u_ether.c
+++ b/drivers/usb/gadget/u_ether.c
@@ -669,6 +669,8 @@ static int eth_stop(struct net_device *net)
spin_lock_irqsave(&dev->lock, flags);
if (dev->port_usb) {
struct gether *link = dev->port_usb;
+ const struct usb_endpoint_descriptor *in;
+ const struct usb_endpoint_descriptor *out;
if (link->close)
link->close(link);
@@ -682,10 +684,14 @@ static int eth_stop(struct net_device *net)
* their own pace; the network stack can handle old packets.
* For the moment we leave this here, since it works.
*/
+ in = link->in_ep->desc;
+ out = link->out_ep->desc;
usb_ep_disable(link->in_ep);
usb_ep_disable(link->out_ep);
if (netif_carrier_ok(net)) {
DBG(dev, "host still using in/out endpoints\n");
+ link->in_ep->desc = in;
+ link->out_ep->desc = out;
usb_ep_enable(link->in_ep);
usb_ep_enable(link->out_ep);
}