Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0ecb063a authored by Linus Torvalds's avatar Linus Torvalds
Browse files
* 'usb-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6:
  xHCI: Clear PLC in xhci_bus_resume()
  USB: fix regression in usbip by setting has_tt flag
  usb/isp1760: Report correct urb status after unlink
  omap:usb: add regulator support for EHCI
  mfd: Fix usbhs_enable error handling
  usb: musb: gadget: Fix out-of-sync runtime pm calls
  usb: musb: omap2430: Fix retention idle on musb peripheral only boards
parents bd355f8a 4f0871a6
Loading
Loading
Loading
Loading
+3 −6
Original line number Original line Diff line number Diff line
@@ -25,7 +25,6 @@
#include <linux/dma-mapping.h>
#include <linux/dma-mapping.h>
#include <linux/spinlock.h>
#include <linux/spinlock.h>
#include <linux/gpio.h>
#include <linux/gpio.h>
#include <linux/regulator/consumer.h>
#include <plat/usb.h>
#include <plat/usb.h>


#define USBHS_DRIVER_NAME	"usbhs-omap"
#define USBHS_DRIVER_NAME	"usbhs-omap"
@@ -700,8 +699,7 @@ static int usbhs_enable(struct device *dev)
	dev_dbg(dev, "starting TI HSUSB Controller\n");
	dev_dbg(dev, "starting TI HSUSB Controller\n");
	if (!pdata) {
	if (!pdata) {
		dev_dbg(dev, "missing platform_data\n");
		dev_dbg(dev, "missing platform_data\n");
		ret =  -ENODEV;
		return  -ENODEV;
		goto end_enable;
	}
	}


	spin_lock_irqsave(&omap->lock, flags);
	spin_lock_irqsave(&omap->lock, flags);
@@ -915,7 +913,8 @@ static int usbhs_enable(struct device *dev)


end_count:
end_count:
	omap->count++;
	omap->count++;
	goto end_enable;
	spin_unlock_irqrestore(&omap->lock, flags);
	return 0;


err_tll:
err_tll:
	if (pdata->ehci_data->phy_reset) {
	if (pdata->ehci_data->phy_reset) {
@@ -931,8 +930,6 @@ err_tll:
	clk_disable(omap->usbhost_fs_fck);
	clk_disable(omap->usbhost_fs_fck);
	clk_disable(omap->usbhost_hs_fck);
	clk_disable(omap->usbhost_hs_fck);
	clk_disable(omap->usbhost_ick);
	clk_disable(omap->usbhost_ick);

end_enable:
	spin_unlock_irqrestore(&omap->lock, flags);
	spin_unlock_irqrestore(&omap->lock, flags);
	return ret;
	return ret;
}
}
+1 −1
Original line number Original line Diff line number Diff line
@@ -1139,7 +1139,7 @@ static int vhci_hcd_probe(struct platform_device *pdev)
		usbip_uerr("create hcd failed\n");
		usbip_uerr("create hcd failed\n");
		return -ENOMEM;
		return -ENOMEM;
	}
	}

	hcd->has_tt = 1;


	/* this is private data for vhci_hcd */
	/* this is private data for vhci_hcd */
	the_controller = hcd_to_vhci(hcd);
	the_controller = hcd_to_vhci(hcd);
+20 −0
Original line number Original line Diff line number Diff line
@@ -40,6 +40,7 @@
#include <linux/slab.h>
#include <linux/slab.h>
#include <linux/usb/ulpi.h>
#include <linux/usb/ulpi.h>
#include <plat/usb.h>
#include <plat/usb.h>
#include <linux/regulator/consumer.h>


/* EHCI Register Set */
/* EHCI Register Set */
#define EHCI_INSNREG04					(0xA0)
#define EHCI_INSNREG04					(0xA0)
@@ -118,6 +119,8 @@ static int ehci_hcd_omap_probe(struct platform_device *pdev)
	struct ehci_hcd				*omap_ehci;
	struct ehci_hcd				*omap_ehci;
	int					ret = -ENODEV;
	int					ret = -ENODEV;
	int					irq;
	int					irq;
	int					i;
	char					supply[7];


	if (usb_disabled())
	if (usb_disabled())
		return -ENODEV;
		return -ENODEV;
@@ -158,6 +161,23 @@ static int ehci_hcd_omap_probe(struct platform_device *pdev)
	hcd->rsrc_len = resource_size(res);
	hcd->rsrc_len = resource_size(res);
	hcd->regs = regs;
	hcd->regs = regs;


	/* get ehci regulator and enable */
	for (i = 0 ; i < OMAP3_HS_USB_PORTS ; i++) {
		if (pdata->port_mode[i] != OMAP_EHCI_PORT_MODE_PHY) {
			pdata->regulator[i] = NULL;
			continue;
		}
		snprintf(supply, sizeof(supply), "hsusb%d", i);
		pdata->regulator[i] = regulator_get(dev, supply);
		if (IS_ERR(pdata->regulator[i])) {
			pdata->regulator[i] = NULL;
			dev_dbg(dev,
			"failed to get ehci port%d regulator\n", i);
		} else {
			regulator_enable(pdata->regulator[i]);
		}
	}

	ret = omap_usbhs_enable(dev);
	ret = omap_usbhs_enable(dev);
	if (ret) {
	if (ret) {
		dev_err(dev, "failed to start usbhs with err %d\n", ret);
		dev_err(dev, "failed to start usbhs with err %d\n", ret);
+1 −0
Original line number Original line Diff line number Diff line
@@ -1633,6 +1633,7 @@ static int isp1760_urb_dequeue(struct usb_hcd *hcd, struct urb *urb, int status)
			ints[i].qh = NULL;
			ints[i].qh = NULL;
			ints[i].qtd = NULL;
			ints[i].qtd = NULL;


			urb->status = status;
			isp1760_urb_done(hcd, urb);
			isp1760_urb_done(hcd, urb);
			if (qtd)
			if (qtd)
				pe(hcd, qh, qtd);
				pe(hcd, qh, qtd);
+17 −2
Original line number Original line Diff line number Diff line
@@ -777,7 +777,7 @@ int xhci_bus_suspend(struct usb_hcd *hcd)
		if (t1 != t2)
		if (t1 != t2)
			xhci_writel(xhci, t2, port_array[port_index]);
			xhci_writel(xhci, t2, port_array[port_index]);


		if (DEV_HIGHSPEED(t1)) {
		if (hcd->speed != HCD_USB3) {
			/* enable remote wake up for USB 2.0 */
			/* enable remote wake up for USB 2.0 */
			u32 __iomem *addr;
			u32 __iomem *addr;
			u32 tmp;
			u32 tmp;
@@ -866,6 +866,21 @@ int xhci_bus_resume(struct usb_hcd *hcd)
				temp |= PORT_LINK_STROBE | XDEV_U0;
				temp |= PORT_LINK_STROBE | XDEV_U0;
				xhci_writel(xhci, temp, port_array[port_index]);
				xhci_writel(xhci, temp, port_array[port_index]);
			}
			}
			/* wait for the port to enter U0 and report port link
			 * state change.
			 */
			spin_unlock_irqrestore(&xhci->lock, flags);
			msleep(20);
			spin_lock_irqsave(&xhci->lock, flags);

			/* Clear PLC */
			temp = xhci_readl(xhci, port_array[port_index]);
			if (temp & PORT_PLC) {
				temp = xhci_port_state_to_neutral(temp);
				temp |= PORT_PLC;
				xhci_writel(xhci, temp, port_array[port_index]);
			}

			slot_id = xhci_find_slot_id_by_port(hcd,
			slot_id = xhci_find_slot_id_by_port(hcd,
					xhci, port_index + 1);
					xhci, port_index + 1);
			if (slot_id)
			if (slot_id)
@@ -873,7 +888,7 @@ int xhci_bus_resume(struct usb_hcd *hcd)
		} else
		} else
			xhci_writel(xhci, temp, port_array[port_index]);
			xhci_writel(xhci, temp, port_array[port_index]);


		if (DEV_HIGHSPEED(temp)) {
		if (hcd->speed != HCD_USB3) {
			/* disable remote wake up for USB 2.0 */
			/* disable remote wake up for USB 2.0 */
			u32 __iomem *addr;
			u32 __iomem *addr;
			u32 tmp;
			u32 tmp;
Loading