diff options
author | Sebastian Andrzej Siewior <bigeasy@linutronix.de> | 2012-07-20 14:34:24 -0400 |
---|---|---|
committer | Felipe Balbi <balbi@ti.com> | 2012-09-06 12:52:29 -0400 |
commit | 8b7dda554cf61e87523dee412eaf598f8646bd79 (patch) | |
tree | 1535ac7e6b3256dd0d1ad27f45d8aa2d73e77092 /drivers/usb/gadget/at91_udc.c | |
parent | 066618bc350cc6035c3a0fc559a8ac02f55785a9 (diff) |
usb: gadget: at91udc: don't overwrite driver data
The driver was converted to the new start/stop interface in f3d8bf34c2
("usb: gadget: at91_udc: convert to new style start/stop interface").
I overlooked that the driver is overwritting the private data which is
used by the composite framework. The udc driver doesn't read it, it is
only written here.
Tested-by: Fabio Porcedda <fabio.porcedda@gmail.com>
Tested-by: Mario Isidoro <Mario.Isidoro@tecmic.pt>
Cc: <stable@kernel.org> # v3.5
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb/gadget/at91_udc.c')
-rw-r--r-- | drivers/usb/gadget/at91_udc.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/usb/gadget/at91_udc.c b/drivers/usb/gadget/at91_udc.c index c9e66dfb02e6..14df835991af 100644 --- a/drivers/usb/gadget/at91_udc.c +++ b/drivers/usb/gadget/at91_udc.c | |||
@@ -1635,7 +1635,6 @@ static int at91_start(struct usb_gadget *gadget, | |||
1635 | udc->driver = driver; | 1635 | udc->driver = driver; |
1636 | udc->gadget.dev.driver = &driver->driver; | 1636 | udc->gadget.dev.driver = &driver->driver; |
1637 | udc->gadget.dev.of_node = udc->pdev->dev.of_node; | 1637 | udc->gadget.dev.of_node = udc->pdev->dev.of_node; |
1638 | dev_set_drvdata(&udc->gadget.dev, &driver->driver); | ||
1639 | udc->enabled = 1; | 1638 | udc->enabled = 1; |
1640 | udc->selfpowered = 1; | 1639 | udc->selfpowered = 1; |
1641 | 1640 | ||
@@ -1656,7 +1655,6 @@ static int at91_stop(struct usb_gadget *gadget, | |||
1656 | spin_unlock_irqrestore(&udc->lock, flags); | 1655 | spin_unlock_irqrestore(&udc->lock, flags); |
1657 | 1656 | ||
1658 | udc->gadget.dev.driver = NULL; | 1657 | udc->gadget.dev.driver = NULL; |
1659 | dev_set_drvdata(&udc->gadget.dev, NULL); | ||
1660 | udc->driver = NULL; | 1658 | udc->driver = NULL; |
1661 | 1659 | ||
1662 | DBG("unbound from %s\n", driver->driver.name); | 1660 | DBG("unbound from %s\n", driver->driver.name); |