Commit ef98f746 authored by Felipe Balbi's avatar Felipe Balbi

usb: gadget: pch_udc: don't assign gadget.dev.release directly

udc-core provides a better way to handle release
methods, let's use it.
Signed-off-by: default avatarFelipe Balbi <balbi@ti.com>
parent 2fb29f21
...@@ -3191,13 +3191,13 @@ static int pch_udc_probe(struct pci_dev *pdev, ...@@ -3191,13 +3191,13 @@ static int pch_udc_probe(struct pci_dev *pdev,
if (retval) if (retval)
goto finished; goto finished;
dev->gadget.dev.release = gadget_release;
dev->gadget.name = KBUILD_MODNAME; dev->gadget.name = KBUILD_MODNAME;
dev->gadget.max_speed = USB_SPEED_HIGH; dev->gadget.max_speed = USB_SPEED_HIGH;
/* Put the device in disconnected state till a driver is bound */ /* Put the device in disconnected state till a driver is bound */
pch_udc_set_disconnect(dev); pch_udc_set_disconnect(dev);
retval = usb_add_gadget_udc(&pdev->dev, &dev->gadget); retval = usb_add_gadget_udc_release(&pdev->dev, &dev->gadget,
gadget_release);
if (retval) if (retval)
goto finished; goto finished;
return 0; return 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment