xref: /rk3399_rockchip-uboot/arch/arm/include/asm/arch-tegra/xusb-padctl.h (revision be7890927a0f9fd40e697ed857cba8c2de1d178e)
179c7a90fSThierry Reding #ifndef _TEGRA_XUSB_PADCTL_H_
279c7a90fSThierry Reding #define _TEGRA_XUSB_PADCTL_H_
379c7a90fSThierry Reding 
479c7a90fSThierry Reding struct tegra_xusb_phy;
579c7a90fSThierry Reding 
679c7a90fSThierry Reding /**
779c7a90fSThierry Reding  * tegra_xusb_phy_get() - obtain a reference to a specified padctl PHY
879c7a90fSThierry Reding  * @type: the type of PHY to obtain
979c7a90fSThierry Reding  *
1079c7a90fSThierry Reding  * The type of PHY varies between SoC generations. Typically there are XUSB,
1179c7a90fSThierry Reding  * PCIe and SATA PHYs, though not all generations support all of them. The
1279c7a90fSThierry Reding  * value of type can usually be directly parsed from a device tree.
1379c7a90fSThierry Reding  *
1479c7a90fSThierry Reding  * Return: a pointer to the PHY or NULL if no such PHY exists
1579c7a90fSThierry Reding  */
1679c7a90fSThierry Reding struct tegra_xusb_phy *tegra_xusb_phy_get(unsigned int type);
1779c7a90fSThierry Reding 
18*be789092SSimon Glass void tegra_xusb_padctl_init(void);
1979c7a90fSThierry Reding int tegra_xusb_phy_prepare(struct tegra_xusb_phy *phy);
2079c7a90fSThierry Reding int tegra_xusb_phy_enable(struct tegra_xusb_phy *phy);
2179c7a90fSThierry Reding int tegra_xusb_phy_disable(struct tegra_xusb_phy *phy);
2279c7a90fSThierry Reding int tegra_xusb_phy_unprepare(struct tegra_xusb_phy *phy);
2379c7a90fSThierry Reding 
2479c7a90fSThierry Reding #endif
25