From: Greg Kroah-Hartman Date: Mon, 7 May 2012 16:03:39 +0000 (-0700) Subject: Merge 3.4-rc6 into usb-next X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=61906313bd41cde2f9aaa14e461e6108d3e71aaa;p=GitHub%2FLineageOS%2FG12%2Fandroid_kernel_amlogic_linux-4.9.git Merge 3.4-rc6 into usb-next This resolves the conflict with: drivers/usb/host/ehci-tegra.c Signed-off-by: Greg Kroah-Hartman --- 61906313bd41cde2f9aaa14e461e6108d3e71aaa diff --cc drivers/usb/class/cdc-wdm.c index cd017a914c5d,0bb2b3248dad..5d151653ae43 --- a/drivers/usb/class/cdc-wdm.c +++ b/drivers/usb/class/cdc-wdm.c @@@ -412,9 -412,9 +414,10 @@@ static ssize_t wdm_writ rv = usb_submit_urb(desc->command, GFP_KERNEL); if (rv < 0) { kfree(buf); + desc->outbuf = NULL; clear_bit(WDM_IN_USE, &desc->flags); dev_err(&desc->intf->dev, "Tx URB error: %d\n", rv); + rv = usb_translate_errors(rv); } else { dev_dbg(&desc->intf->dev, "Tx URB has been submitted index=%d", req->wIndex); diff --cc drivers/usb/host/ehci-tegra.c index 4c1eb61bc2fc,f214a80cdee2..e57aba52b31c --- a/drivers/usb/host/ehci-tegra.c +++ b/drivers/usb/host/ehci-tegra.c @@@ -423,37 -319,7 +308,7 @@@ static int tegra_ehci_setup(struct usb_ return retval; } - #ifdef CONFIG_PM - static int tegra_ehci_bus_suspend(struct usb_hcd *hcd) - { - struct tegra_ehci_hcd *tegra = dev_get_drvdata(hcd->self.controller); - int error_status = 0; - - error_status = ehci_bus_suspend(hcd); - if (!error_status && tegra->power_down_on_bus_suspend) { - tegra_usb_suspend(hcd); - tegra->bus_suspended = 1; - } - - return error_status; - } - - static int tegra_ehci_bus_resume(struct usb_hcd *hcd) - { - struct tegra_ehci_hcd *tegra = dev_get_drvdata(hcd->self.controller); - - if (tegra->bus_suspended && tegra->power_down_on_bus_suspend) { - tegra_usb_resume(hcd); - tegra->bus_suspended = 0; - } - - tegra_usb_phy_preresume(tegra->phy); - tegra->port_resuming = 1; - return ehci_bus_resume(hcd); - } - #endif - -struct temp_buffer { +struct dma_aligned_buffer { void *kmalloc_ptr; void *old_xfer_buffer; u8 data[0]; @@@ -548,20 -426,14 +403,20 @@@ static const struct hc_driver tegra_ehc .endpoint_reset = ehci_endpoint_reset, .get_frame_number = ehci_get_frame, .hub_status_data = ehci_hub_status_data, - .hub_control = tegra_ehci_hub_control, .clear_tt_buffer_complete = ehci_clear_tt_buffer_complete, + .relinquish_port = ehci_relinquish_port, + .port_handed_over = ehci_port_handed_over, + + /* modified ehci functions for tegra */ + .reset = tegra_ehci_setup, + .shutdown = tegra_ehci_shutdown, + .map_urb_for_dma = tegra_ehci_map_urb_for_dma, + .unmap_urb_for_dma = tegra_ehci_unmap_urb_for_dma, + .hub_control = tegra_ehci_hub_control, #ifdef CONFIG_PM - .bus_suspend = tegra_ehci_bus_suspend, - .bus_resume = tegra_ehci_bus_resume, + .bus_suspend = ehci_bus_suspend, + .bus_resume = ehci_bus_resume, #endif - .relinquish_port = ehci_relinquish_port, - .port_handed_over = ehci_port_handed_over, }; static int setup_vbus_gpio(struct platform_device *pdev)