Lines Matching refs:padctl
6 #define pr_fmt(fmt) "tegra-xusb-padctl: " fmt
13 #include "../xusb-padctl-common.h"
108 static int tegra_xusb_padctl_enable(struct tegra_xusb_padctl *padctl)
112 if (padctl->enable++ > 0)
115 value = padctl_readl(padctl, XUSB_PADCTL_ELPG_PROGRAM);
117 padctl_writel(padctl, value, XUSB_PADCTL_ELPG_PROGRAM);
121 value = padctl_readl(padctl, XUSB_PADCTL_ELPG_PROGRAM);
123 padctl_writel(padctl, value, XUSB_PADCTL_ELPG_PROGRAM);
127 value = padctl_readl(padctl, XUSB_PADCTL_ELPG_PROGRAM);
129 padctl_writel(padctl, value, XUSB_PADCTL_ELPG_PROGRAM);
134 static int tegra_xusb_padctl_disable(struct tegra_xusb_padctl *padctl)
138 if (padctl->enable == 0) {
143 if (--padctl->enable > 0)
146 value = padctl_readl(padctl, XUSB_PADCTL_ELPG_PROGRAM);
148 padctl_writel(padctl, value, XUSB_PADCTL_ELPG_PROGRAM);
152 value = padctl_readl(padctl, XUSB_PADCTL_ELPG_PROGRAM);
154 padctl_writel(padctl, value, XUSB_PADCTL_ELPG_PROGRAM);
158 value = padctl_readl(padctl, XUSB_PADCTL_ELPG_PROGRAM);
160 padctl_writel(padctl, value, XUSB_PADCTL_ELPG_PROGRAM);
167 return tegra_xusb_padctl_enable(phy->padctl);
172 return tegra_xusb_padctl_disable(phy->padctl);
177 struct tegra_xusb_padctl *padctl = phy->padctl;
182 value = padctl_readl(padctl, XUSB_PADCTL_IOPHY_PLL_P0_CTL1);
184 padctl_writel(padctl, value, XUSB_PADCTL_IOPHY_PLL_P0_CTL1);
186 value = padctl_readl(padctl, XUSB_PADCTL_IOPHY_PLL_P0_CTL2);
190 padctl_writel(padctl, value, XUSB_PADCTL_IOPHY_PLL_P0_CTL2);
192 value = padctl_readl(padctl, XUSB_PADCTL_IOPHY_PLL_P0_CTL1);
194 padctl_writel(padctl, value, XUSB_PADCTL_IOPHY_PLL_P0_CTL1);
199 value = padctl_readl(padctl, XUSB_PADCTL_IOPHY_PLL_P0_CTL1);
211 struct tegra_xusb_padctl *padctl = phy->padctl;
214 value = padctl_readl(padctl, XUSB_PADCTL_IOPHY_PLL_P0_CTL1);
216 padctl_writel(padctl, value, XUSB_PADCTL_IOPHY_PLL_P0_CTL1);
223 struct tegra_xusb_padctl *padctl = phy->padctl;
228 value = padctl_readl(padctl, XUSB_PADCTL_IOPHY_MISC_PAD_S0_CTL1);
231 padctl_writel(padctl, value, XUSB_PADCTL_IOPHY_MISC_PAD_S0_CTL1);
233 value = padctl_readl(padctl, XUSB_PADCTL_IOPHY_PLL_S0_CTL1);
236 padctl_writel(padctl, value, XUSB_PADCTL_IOPHY_PLL_S0_CTL1);
238 value = padctl_readl(padctl, XUSB_PADCTL_IOPHY_PLL_S0_CTL1);
240 padctl_writel(padctl, value, XUSB_PADCTL_IOPHY_PLL_S0_CTL1);
242 value = padctl_readl(padctl, XUSB_PADCTL_IOPHY_PLL_S0_CTL1);
244 padctl_writel(padctl, value, XUSB_PADCTL_IOPHY_PLL_S0_CTL1);
249 value = padctl_readl(padctl, XUSB_PADCTL_IOPHY_PLL_S0_CTL1);
261 struct tegra_xusb_padctl *padctl = phy->padctl;
264 value = padctl_readl(padctl, XUSB_PADCTL_IOPHY_PLL_S0_CTL1);
266 padctl_writel(padctl, value, XUSB_PADCTL_IOPHY_PLL_S0_CTL1);
268 value = padctl_readl(padctl, XUSB_PADCTL_IOPHY_PLL_S0_CTL1);
270 padctl_writel(padctl, value, XUSB_PADCTL_IOPHY_PLL_S0_CTL1);
272 value = padctl_readl(padctl, XUSB_PADCTL_IOPHY_PLL_S0_CTL1);
275 padctl_writel(padctl, value, XUSB_PADCTL_IOPHY_PLL_S0_CTL1);
277 value = padctl_readl(padctl, XUSB_PADCTL_IOPHY_MISC_PAD_S0_CTL1);
280 padctl_writel(padctl, value, XUSB_PADCTL_IOPHY_MISC_PAD_S0_CTL1);
303 .padctl = &padctl,
308 .padctl = &padctl,
330 "nvidia,tegra124-xusb-padctl");
341 count = fdtdec_find_aliases_for_id(gd->fdt_blob, "padctl",