Lines Matching defs:wake
373 * These describe events that can wake the system from sleep (i.e.
393 * @wake: pointer to I/O remapped region for WAKE registers
421 * @wake_type_dual_edge_map: Bitmap indicating if a wake is dual-edge or not
423 * @wake_cntrl_level_map: Bitmap to hold wake levels to be programmed in
424 * cntrl register associated with each wake during system suspend.
429 void __iomem *wake;
2276 /* IRQ and simple wake events */
2307 /* GPIO wake events */
2325 /* If there is no wake-up event, there is no PMC mapping */
2346 /* clear wake status */
2353 /* enable PMC wake */
2416 value = readl(pmc->wake + WAKE_AOWAKE_CNTRL(SW_WAKE_ID));
2418 writel(value, pmc->wake + WAKE_AOWAKE_CNTRL(SW_WAKE_ID));
2431 /* clear wake status */
2432 writel(0x1, pmc->wake + WAKE_AOWAKE_STATUS_W(data->hwirq));
2434 /* route wake to tier 2 */
2435 value = readl(pmc->wake + WAKE_AOWAKE_TIER2_ROUTING(offset));
2442 writel(value, pmc->wake + WAKE_AOWAKE_TIER2_ROUTING(offset));
2445 writel(!!on, pmc->wake + WAKE_AOWAKE_MASK_W(data->hwirq));
2455 value = readl(pmc->wake + WAKE_AOWAKE_CNTRL(data->hwirq));
2482 writel(value, pmc->wake + WAKE_AOWAKE_CNTRL(data->hwirq));
2920 res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "wake");
2922 pmc->wake = devm_ioremap_resource(&pdev->dev, res);
2923 if (IS_ERR(pmc->wake))
2924 return PTR_ERR(pmc->wake);
2926 pmc->wake = base;
3066 writel(value, pmc->wake + offset);
3070 static void wke_write_wake_level(struct tegra_pmc *pmc, int wake, int level)
3072 unsigned int offset = WAKE_AOWAKE_CNTRL(wake);
3075 value = readl(pmc->wake + offset);
3081 writel(value, pmc->wake + offset);
3100 unsigned int wake, i;
3111 * obtain the current status of the input wake signals, change
3112 * the polarity of the wake level from 0->1 while latching to force
3120 * and let enough time lapse, so that the wake signals have time to
3130 status = readl(pmc->wake + WAKE_AOWAKE_SW_STATUS(i));
3132 for_each_set_bit(wake, &status, 32)
3133 set_bit(wake + (i * 32), pmc->wake_sw_status_map);
3140 unsigned int i, wake;
3144 mask = readl(pmc->wake + WAKE_AOWAKE_TIER2_ROUTING(i));
3145 status = readl(pmc->wake + WAKE_AOWAKE_STATUS_R(i)) & mask;
3147 for_each_set_bit(wake, &status, 32)
3148 wke_32kwritel(pmc, 0x1, WAKE_AOWAKE_STATUS_W((i * 32) + wake));
3152 /* translate sc7 wake sources back into IRQs to catch edge triggered wakeups */
3156 unsigned int wake;
3160 for_each_set_bit(wake, &status, 32) {
3161 irq_hw_number_t hwirq = wake + 32 * index;
3184 mask = readl(pmc->wake + WAKE_AOWAKE_TIER2_ROUTING(i));
3185 status = readl(pmc->wake + WAKE_AOWAKE_STATUS_R(i)) & mask;
3866 void __iomem *wake;
3870 index = of_property_match_string(np, "reg-names", "wake");
3872 dev_err(pmc->dev, "failed to find PMC wake registers\n");
3878 wake = ioremap(regs.start, resource_size(®s));
3879 if (!wake) {
3880 dev_err(pmc->dev, "failed to map PMC wake registers\n");
3884 value = readl(wake + WAKE_AOWAKE_CTRL);
3891 writel(value, wake + WAKE_AOWAKE_CTRL);
3893 iounmap(wake);
4235 TEGRA_WAKE_IRQ("sw-wake", SW_WAKE_ID, 179),