Lines Matching full:lane
109 int tegra_xusb_lane_parse_dt(struct tegra_xusb_lane *lane, in tegra_xusb_lane_parse_dt() argument
112 struct device *dev = &lane->pad->dev; in tegra_xusb_lane_parse_dt()
120 err = match_string(lane->soc->funcs, lane->soc->num_funcs, function); in tegra_xusb_lane_parse_dt()
122 dev_err(dev, "invalid function \"%s\" for lane \"%pOFn\"\n", in tegra_xusb_lane_parse_dt()
127 lane->function = err; in tegra_xusb_lane_parse_dt()
135 struct tegra_xusb_lane *lane = phy_get_drvdata(phy); in tegra_xusb_lane_destroy() local
137 lane->pad->ops->remove(lane); in tegra_xusb_lane_destroy()
185 struct phy *lane; in tegra_xusb_pad_register() local
193 pad->lanes = devm_kcalloc(&pad->dev, pad->soc->num_lanes, sizeof(lane), in tegra_xusb_pad_register()
202 struct tegra_xusb_lane *lane; in tegra_xusb_pad_register() local
217 lane = pad->ops->probe(pad, np, i); in tegra_xusb_pad_register()
218 if (IS_ERR(lane)) { in tegra_xusb_pad_register()
220 err = PTR_ERR(lane); in tegra_xusb_pad_register()
224 list_add_tail(&lane->list, &pad->padctl->lanes); in tegra_xusb_pad_register()
225 phy_set_drvdata(pad->lanes[i], lane); in tegra_xusb_pad_register()
314 static void tegra_xusb_lane_program(struct tegra_xusb_lane *lane) in tegra_xusb_lane_program() argument
316 struct tegra_xusb_padctl *padctl = lane->pad->padctl; in tegra_xusb_lane_program()
317 const struct tegra_xusb_lane_soc *soc = lane->soc; in tegra_xusb_lane_program()
327 value |= lane->function << soc->shift; in tegra_xusb_lane_program()
336 struct tegra_xusb_lane *lane; in tegra_xusb_pad_program() local
339 lane = phy_get_drvdata(pad->lanes[i]); in tegra_xusb_pad_program()
340 tegra_xusb_lane_program(lane); in tegra_xusb_pad_program()
379 static bool tegra_xusb_lane_check(struct tegra_xusb_lane *lane, in tegra_xusb_lane_check() argument
382 const char *func = lane->soc->funcs[lane->function]; in tegra_xusb_lane_check()
391 struct tegra_xusb_lane *lane, *hit = ERR_PTR(-ENODEV); in tegra_xusb_find_lane() local
398 list_for_each_entry(lane, &padctl->lanes, list) { in tegra_xusb_find_lane()
399 if (strcmp(lane->soc->name, name) == 0) { in tegra_xusb_find_lane()
400 hit = lane; in tegra_xusb_find_lane()
414 struct tegra_xusb_lane *lane, *match = ERR_PTR(-ENODEV); in tegra_xusb_port_find_lane() local
420 lane = tegra_xusb_find_lane(port->padctl, map->type, in tegra_xusb_port_find_lane()
422 if (IS_ERR(lane)) in tegra_xusb_port_find_lane()
425 if (!tegra_xusb_lane_check(lane, function)) in tegra_xusb_port_find_lane()
432 match = lane; in tegra_xusb_port_find_lane()
649 struct tegra_xusb_lane *lane; in tegra_xusb_setup_usb_role_switch() local
684 lane = tegra_xusb_find_lane(port->padctl, "usb2", port->index); in tegra_xusb_setup_usb_role_switch()
690 port->usb_phy.dev = &lane->pad->lanes[port->index]->dev; in tegra_xusb_setup_usb_role_switch()
775 usb2->base.lane = usb2->base.ops->map(&usb2->base); in tegra_xusb_add_usb2_port()
776 if (IS_ERR(usb2->base.lane)) { in tegra_xusb_add_usb2_port()
777 err = PTR_ERR(usb2->base.lane); in tegra_xusb_add_usb2_port()
841 ulpi->base.lane = ulpi->base.ops->map(&ulpi->base); in tegra_xusb_add_ulpi_port()
842 if (IS_ERR(ulpi->base.lane)) { in tegra_xusb_add_ulpi_port()
843 err = PTR_ERR(ulpi->base.lane); in tegra_xusb_add_ulpi_port()
896 hsic->base.lane = hsic->base.ops->map(&hsic->base); in tegra_xusb_add_hsic_port()
897 if (IS_ERR(hsic->base.lane)) { in tegra_xusb_add_hsic_port()
898 err = PTR_ERR(hsic->base.lane); in tegra_xusb_add_hsic_port()
982 usb3->base.lane = usb3->base.ops->map(&usb3->base); in tegra_xusb_add_usb3_port()
983 if (IS_ERR(usb3->base.lane)) { in tegra_xusb_add_usb3_port()
984 err = PTR_ERR(usb3->base.lane); in tegra_xusb_add_usb3_port()
1365 struct tegra_xusb_lane *lane = phy_get_drvdata(phy); in tegra_phy_xusb_utmi_port_reset() local
1366 struct tegra_xusb_padctl *padctl = lane->pad->padctl; in tegra_phy_xusb_utmi_port_reset()