On Mon, Jul 02, 2012 at 11:22:00AM +0300, Felipe Balbi wrote: > Hi Greg, > > here are the patches I queued for transceiver drivers. Let me know if > you want me to change anything. this will conflict with your usb-next branch, here's the resolution patch: diff --cc drivers/usb/host/ehci-fsl.c index 3379945,32865a7..74914de --- a/drivers/usb/host/ehci-fsl.c +++ b/drivers/usb/host/ehci-fsl.c @@@ -142,15 -143,15 +143,15 @@@ static int usb_hcd_fsl_probe(const stru if (pdata->operating_mode == FSL_USB2_DR_OTG) { struct ehci_hcd *ehci = hcd_to_ehci(hcd); - hcd->phy = usb_get_transceiver(); - ehci->transceiver = usb_get_phy(USB_PHY_TYPE_USB2); - dev_dbg(&pdev->dev, "hcd=0x%p ehci=0x%p, transceiver=0x%p\n", - hcd, ehci, ehci->transceiver); ++ hcd->phy = usb_get_phy(USB_PHY_TYPE_USB2); + dev_dbg(&pdev->dev, "hcd=0x%p ehci=0x%p, phy=0x%p\n", + hcd, ehci, hcd->phy); - if (hcd->phy) { - if (!IS_ERR_OR_NULL(ehci->transceiver)) { - retval = otg_set_host(ehci->transceiver->otg, ++ if (!IS_ERR_OR_NULL(hcd->phy)) { + retval = otg_set_host(hcd->phy->otg, &ehci_to_hcd(ehci)->self); if (retval) { - usb_put_transceiver(hcd->phy); - usb_put_phy(ehci->transceiver); ++ usb_put_phy(hcd->phy); goto err4; } } else { @@@ -190,10 -191,11 +191,10 @@@ static void usb_hcd_fsl_remove(struct u struct platform_device *pdev) { struct fsl_usb2_platform_data *pdata = pdev->dev.platform_data; - struct ehci_hcd *ehci = hcd_to_ehci(hcd); - if (hcd->phy) { - if (!IS_ERR_OR_NULL(ehci->transceiver)) { - otg_set_host(ehci->transceiver->otg, NULL); - usb_put_phy(ehci->transceiver); ++ if (!IS_ERR_OR_NULL(hcd->phy)) { + otg_set_host(hcd->phy->otg, NULL); - usb_put_transceiver(hcd->phy); ++ usb_put_phy(hcd->phy); } usb_remove_hcd(hcd); diff --cc drivers/usb/host/ohci-omap.c index eccddb4,c7b06f5..076d201 --- a/drivers/usb/host/ohci-omap.c +++ b/drivers/usb/host/ohci-omap.c @@@ -212,14 -212,14 +213,14 @@@ static int ohci_omap_init(struct usb_hc #ifdef CONFIG_USB_OTG if (need_transceiver) { - hcd->phy = usb_get_transceiver(); - if (hcd->phy) { - ohci->transceiver = usb_get_phy(USB_PHY_TYPE_USB2); - if (!IS_ERR_OR_NULL(ohci->transceiver)) { - int status = otg_set_host(ohci->transceiver->otg, ++ hcd->phy = usb_get_phy(USB_PHY_TYPE_USB2); ++ if (!IS_ERR_OR_NULL(hcd->phy)) { + int status = otg_set_host(hcd->phy->otg, &ohci_to_hcd(ohci)->self); - dev_dbg(hcd->self.controller, "init %s transceiver, status %d\n", - ohci->transceiver->label, status); + dev_dbg(hcd->self.controller, "init %s phy, status %d\n", + hcd->phy->label, status); if (status) { - usb_put_transceiver(hcd->phy); - usb_put_phy(ohci->transceiver); ++ usb_put_phy(hcd->phy); return status; } } else { @@@ -404,9 -404,9 +405,9 @@@ usb_hcd_omap_remove (struct usb_hcd *hc struct ohci_hcd *ohci = hcd_to_ohci (hcd); usb_remove_hcd(hcd); - if (hcd->phy) { - if (!IS_ERR_OR_NULL(ohci->transceiver)) { - (void) otg_set_host(ohci->transceiver->otg, 0); - usb_put_phy(ohci->transceiver); ++ if (!IS_ERR_OR_NULL(hcd->phy)) { + (void) otg_set_host(hcd->phy->otg, 0); - usb_put_transceiver(hcd->phy); ++ usb_put_phy(hcd->phy); } if (machine_is_omap_osk()) gpio_free(9); -- balbi
Attachment:
signature.asc
Description: Digital signature