Commit a9746e40 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull USB/PHY fixes from Greg KH:
 "Here are a number of small USB and PHY driver fixes for 4.15-rc6.

  Nothing major, but there are a number of regression fixes in here that
  resolve issues that have been reported a bunch. There are also the
  usual xhci fixes as well as a number of new usb serial device ids.

  All of these have been in linux-next for a while with no reported
  issues"

* tag 'usb-4.15-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb:
  usb: xhci: Add XHCI_TRUST_TX_LENGTH for Renesas uPD720201
  xhci: Fix use-after-free in xhci debugfs
  xhci: Fix xhci debugfs NULL pointer dereference in resume from hibernate
  USB: serial: ftdi_sio: add id for Airbus DS P8GR
  usb: Add device quirk for Logitech HD Pro Webcam C925e
  usb: add RESET_RESUME for ELSA MicroLink 56K
  usbip: fix usbip bind writing random string after command in match_busid
  usbip: stub_rx: fix static checker warning on unnecessary checks
  usbip: prevent leaking socket pointer address in messages
  usbip: stub: stop printing kernel pointer addresses in messages
  usbip: vhci: stop printing kernel pointer addresses in messages
  USB: Fix off by one in type-specific length check of BOS SSP capability
  USB: serial: option: adding support for YUGA CLM920-NC5
  phy: rcar-gen3-usb2: select USB_COMMON
  phy: rockchip-typec: add pm_runtime_disable in err case
  phy: cpcap-usb: Fix platform_get_irq_byname's error checking.
  phy: tegra: fix device-tree node lookups
  USB: serial: qcserial: add Sierra Wireless EM7565
  USB: serial: option: add support for Telit ME910 PID 0x1101
  USB: chipidea: msm: fix ulpi-node lookup
parents c0b23903 da997066
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -310,7 +310,7 @@ static int cpcap_usb_init_irq(struct platform_device *pdev,
	int irq, error;

	irq = platform_get_irq_byname(pdev, name);
	if (!irq)
	if (irq < 0)
		return -ENODEV;

	error = devm_request_threaded_irq(ddata->dev, irq, NULL,
+2 −0
Original line number Diff line number Diff line
@@ -12,7 +12,9 @@ config PHY_RCAR_GEN3_USB2
	tristate "Renesas R-Car generation 3 USB 2.0 PHY driver"
	depends on ARCH_RENESAS
	depends on EXTCON
	depends on USB_SUPPORT
	select GENERIC_PHY
	select USB_COMMON
	help
	  Support for USB 2.0 PHY found on Renesas R-Car generation 3 SoCs.

+2 −0
Original line number Diff line number Diff line
@@ -1137,6 +1137,7 @@ static int rockchip_typec_phy_probe(struct platform_device *pdev)
		if (IS_ERR(phy)) {
			dev_err(dev, "failed to create phy: %s\n",
				child_np->name);
			pm_runtime_disable(dev);
			return PTR_ERR(phy);
		}

@@ -1146,6 +1147,7 @@ static int rockchip_typec_phy_probe(struct platform_device *pdev)
	phy_provider = devm_of_phy_provider_register(dev, of_phy_simple_xlate);
	if (IS_ERR(phy_provider)) {
		dev_err(dev, "Failed to register phy provider\n");
		pm_runtime_disable(dev);
		return PTR_ERR(phy_provider);
	}

+29 −29
Original line number Diff line number Diff line
@@ -75,14 +75,14 @@ MODULE_DEVICE_TABLE(of, tegra_xusb_padctl_of_match);
static struct device_node *
tegra_xusb_find_pad_node(struct tegra_xusb_padctl *padctl, const char *name)
{
	/*
	 * of_find_node_by_name() drops a reference, so make sure to grab one.
	 */
	struct device_node *np = of_node_get(padctl->dev->of_node);
	struct device_node *pads, *np;

	np = of_find_node_by_name(np, "pads");
	if (np)
		np = of_find_node_by_name(np, name);
	pads = of_get_child_by_name(padctl->dev->of_node, "pads");
	if (!pads)
		return NULL;

	np = of_get_child_by_name(pads, name);
	of_node_put(pads);

	return np;
}
@@ -90,16 +90,16 @@ tegra_xusb_find_pad_node(struct tegra_xusb_padctl *padctl, const char *name)
static struct device_node *
tegra_xusb_pad_find_phy_node(struct tegra_xusb_pad *pad, unsigned int index)
{
	/*
	 * of_find_node_by_name() drops a reference, so make sure to grab one.
	 */
	struct device_node *np = of_node_get(pad->dev.of_node);
	struct device_node *np, *lanes;

	np = of_find_node_by_name(np, "lanes");
	if (!np)
	lanes = of_get_child_by_name(pad->dev.of_node, "lanes");
	if (!lanes)
		return NULL;

	return of_find_node_by_name(np, pad->soc->lanes[index].name);
	np = of_get_child_by_name(lanes, pad->soc->lanes[index].name);
	of_node_put(lanes);

	return np;
}

static int
@@ -195,7 +195,7 @@ int tegra_xusb_pad_register(struct tegra_xusb_pad *pad,
	unsigned int i;
	int err;

	children = of_find_node_by_name(pad->dev.of_node, "lanes");
	children = of_get_child_by_name(pad->dev.of_node, "lanes");
	if (!children)
		return -ENODEV;

@@ -444,21 +444,21 @@ static struct device_node *
tegra_xusb_find_port_node(struct tegra_xusb_padctl *padctl, const char *type,
			  unsigned int index)
{
	/*
	 * of_find_node_by_name() drops a reference, so make sure to grab one.
	 */
	struct device_node *np = of_node_get(padctl->dev->of_node);

	np = of_find_node_by_name(np, "ports");
	if (np) {
	struct device_node *ports, *np;
	char *name;

	ports = of_get_child_by_name(padctl->dev->of_node, "ports");
	if (!ports)
		return NULL;

	name = kasprintf(GFP_KERNEL, "%s-%u", type, index);
		if (!name)
	if (!name) {
		of_node_put(ports);
		return ERR_PTR(-ENOMEM);
		np = of_find_node_by_name(np, name);
		kfree(name);
	}
	np = of_get_child_by_name(ports, name);
	kfree(name);
	of_node_put(ports);

	return np;
}
@@ -847,7 +847,7 @@ static void tegra_xusb_remove_ports(struct tegra_xusb_padctl *padctl)

static int tegra_xusb_padctl_probe(struct platform_device *pdev)
{
	struct device_node *np = of_node_get(pdev->dev.of_node);
	struct device_node *np = pdev->dev.of_node;
	const struct tegra_xusb_padctl_soc *soc;
	struct tegra_xusb_padctl *padctl;
	const struct of_device_id *match;
@@ -855,7 +855,7 @@ static int tegra_xusb_padctl_probe(struct platform_device *pdev)
	int err;

	/* for backwards compatibility with old device trees */
	np = of_find_node_by_name(np, "pads");
	np = of_get_child_by_name(np, "pads");
	if (!np) {
		dev_warn(&pdev->dev, "deprecated DT, using legacy driver\n");
		return tegra_xusb_padctl_legacy_probe(pdev);
+1 −1
Original line number Diff line number Diff line
@@ -247,7 +247,7 @@ static int ci_hdrc_msm_probe(struct platform_device *pdev)
	if (ret)
		goto err_mux;

	ulpi_node = of_find_node_by_name(of_node_get(pdev->dev.of_node), "ulpi");
	ulpi_node = of_get_child_by_name(pdev->dev.of_node, "ulpi");
	if (ulpi_node) {
		phy_node = of_get_next_available_child(ulpi_node, NULL);
		ci->hsic = of_device_is_compatible(phy_node, "qcom,usb-hsic-phy");
Loading