Lines Matching refs:soc
234 const struct tegra_xusb_soc *soc; member
462 value = fpci_readl(tegra, tegra->soc->mbox.owner); in tegra_xusb_mbox_send()
468 fpci_writel(tegra, MBOX_OWNER_SW, tegra->soc->mbox.owner); in tegra_xusb_mbox_send()
470 value = fpci_readl(tegra, tegra->soc->mbox.owner); in tegra_xusb_mbox_send()
480 fpci_writel(tegra, value, tegra->soc->mbox.data_in); in tegra_xusb_mbox_send()
482 value = fpci_readl(tegra, tegra->soc->mbox.cmd); in tegra_xusb_mbox_send()
484 fpci_writel(tegra, value, tegra->soc->mbox.cmd); in tegra_xusb_mbox_send()
490 value = fpci_readl(tegra, tegra->soc->mbox.owner); in tegra_xusb_mbox_send()
498 value = fpci_readl(tegra, tegra->soc->mbox.owner); in tegra_xusb_mbox_send()
526 const struct tegra_xusb_soc *soc = tegra->soc; in tegra_xusb_mbox_handle() local
549 if (tegra->soc->scale_ss_clock) { in tegra_xusb_mbox_handle()
592 mask = extract_field(msg->data, 1 + soc->ports.hsic.offset, in tegra_xusb_mbox_handle()
593 soc->ports.hsic.count); in tegra_xusb_mbox_handle()
620 mask = extract_field(msg->data, 1 + soc->ports.usb3.offset, in tegra_xusb_mbox_handle()
621 soc->ports.usb3.count); in tegra_xusb_mbox_handle()
623 for_each_set_bit(port, &mask, soc->ports.usb3.count) { in tegra_xusb_mbox_handle()
675 value = fpci_readl(tegra, tegra->soc->mbox.data_out); in tegra_xusb_mbox_thread()
678 value = fpci_readl(tegra, tegra->soc->mbox.cmd); in tegra_xusb_mbox_thread()
680 fpci_writel(tegra, value, tegra->soc->mbox.cmd); in tegra_xusb_mbox_thread()
684 fpci_writel(tegra, MBOX_OWNER_NONE, tegra->soc->mbox.owner); in tegra_xusb_mbox_thread()
698 if (tegra->soc->has_ipfs) { in tegra_xusb_config()
719 if (tegra->soc->has_ipfs) { in tegra_xusb_config()
758 if (tegra->soc->scale_ss_clock) { in tegra_xusb_clk_enable()
832 const struct tegra_xusb_context_soc *soc = tegra->soc->context; in tegra_xusb_init_context() local
834 tegra->context.ipfs = devm_kcalloc(tegra->dev, soc->ipfs.num_offsets, in tegra_xusb_init_context()
839 tegra->context.fpci = devm_kcalloc(tegra->dev, soc->fpci.num_offsets, in tegra_xusb_init_context()
859 err = request_firmware(&fw, tegra->soc->firmware, tegra->dev); in tegra_xusb_request_firmware()
1195 for (i = 0; i < tegra->soc->num_types; i++) { in tegra_xusb_get_phy()
1196 if (!strncmp(tegra->soc->phy_types[i].name, name, in tegra_xusb_get_phy()
1200 phy_count += tegra->soc->phy_types[i].num; in tegra_xusb_get_phy()
1234 if (tegra->soc->otg_reset_sspi) { in tegra_xhci_id_work()
1294 if (strcmp(tegra->soc->phy_types[phy_type].name, "hsic") == 0) in is_host_mode_phy()
1297 if (strcmp(tegra->soc->phy_types[phy_type].name, "usb2") == 0) { in is_host_mode_phy()
1304 if (strcmp(tegra->soc->phy_types[phy_type].name, "usb3") == 0) { in is_host_mode_phy()
1418 tegra->soc = of_device_get_match_data(&pdev->dev); in tegra_xusb_probe()
1434 if (tegra->soc->has_ipfs) { in tegra_xusb_probe()
1557 tegra->supplies = devm_kcalloc(&pdev->dev, tegra->soc->num_supplies, in tegra_xusb_probe()
1565 tegra->soc->supply_names, in tegra_xusb_probe()
1566 tegra->soc->num_supplies); in tegra_xusb_probe()
1568 err = devm_regulator_bulk_get(&pdev->dev, tegra->soc->num_supplies, in tegra_xusb_probe()
1575 for (i = 0; i < tegra->soc->num_types; i++) { in tegra_xusb_probe()
1576 if (!strncmp(tegra->soc->phy_types[i].name, "usb2", 4)) in tegra_xusb_probe()
1577 tegra->num_usb_phys = tegra->soc->phy_types[i].num; in tegra_xusb_probe()
1578 tegra->num_phys += tegra->soc->phy_types[i].num; in tegra_xusb_probe()
1588 for (i = 0, k = 0; i < tegra->soc->num_types; i++) { in tegra_xusb_probe()
1591 for (j = 0; j < tegra->soc->phy_types[i].num; j++) { in tegra_xusb_probe()
1593 tegra->soc->phy_types[i].name, j); in tegra_xusb_probe()
1632 err = regulator_bulk_enable(tegra->soc->num_supplies, tegra->supplies); in tegra_xusb_probe()
1760 regulator_bulk_disable(tegra->soc->num_supplies, tegra->supplies); in tegra_xusb_probe()
1801 regulator_bulk_disable(tegra->soc->num_supplies, tegra->supplies); in tegra_xusb_remove()
1856 const struct tegra_xusb_context_soc *soc = tegra->soc->context; in tegra_xusb_save_context() local
1860 if (soc->ipfs.num_offsets > 0) { in tegra_xusb_save_context()
1861 for (i = 0; i < soc->ipfs.num_offsets; i++) in tegra_xusb_save_context()
1862 ctx->ipfs[i] = ipfs_readl(tegra, soc->ipfs.offsets[i]); in tegra_xusb_save_context()
1865 if (soc->fpci.num_offsets > 0) { in tegra_xusb_save_context()
1866 for (i = 0; i < soc->fpci.num_offsets; i++) in tegra_xusb_save_context()
1867 ctx->fpci[i] = fpci_readl(tegra, soc->fpci.offsets[i]); in tegra_xusb_save_context()
1873 const struct tegra_xusb_context_soc *soc = tegra->soc->context; in tegra_xusb_restore_context() local
1877 if (soc->fpci.num_offsets > 0) { in tegra_xusb_restore_context()
1878 for (i = 0; i < soc->fpci.num_offsets; i++) in tegra_xusb_restore_context()
1879 fpci_writel(tegra, ctx->fpci[i], soc->fpci.offsets[i]); in tegra_xusb_restore_context()
1882 if (soc->ipfs.num_offsets > 0) { in tegra_xusb_restore_context()
1883 for (i = 0; i < soc->ipfs.num_offsets; i++) in tegra_xusb_restore_context()
1884 ipfs_writel(tegra, ctx->ipfs[i], soc->ipfs.offsets[i]); in tegra_xusb_restore_context()
1916 for (i = 0, k = 0; i < tegra->soc->num_types; i++) { in tegra_xhci_enable_phy_sleepwalk_wake()
1917 if (strcmp(tegra->soc->phy_types[i].name, "usb3") == 0) in tegra_xhci_enable_phy_sleepwalk_wake()
1922 if (strcmp(tegra->soc->phy_types[i].name, "hsic") == 0) in tegra_xhci_enable_phy_sleepwalk_wake()
1923 offset = tegra->soc->ports.usb2.count; in tegra_xhci_enable_phy_sleepwalk_wake()
1927 for (j = 0; j < tegra->soc->phy_types[i].num; j++) { in tegra_xhci_enable_phy_sleepwalk_wake()
2431 if (tegra && tegra->soc->lpm_support) in tegra_xhci_quirks()