// SPDX-License-Identifier: GPL-2.0 // // Copyright 2010 Ben Dooks <ben-linux@fluff.org> // // Support for wakeup mask interrupts on newer SoCs #include <linux/kernel.h> #include <linux/spinlock.h> #include <linux/device.h> #include <linux/types.h> #include <linux/irq.h> #include <linux/io.h> #include <plat/wakeup-mask.h> #include <plat/pm.h>
void samsung_sync_wakemask(void __iomem *reg, const struct samsung_wakeup_mask *mask, int nr_mask) { struct irq_data *data; u32 val; val = __raw_readl(reg); for (; nr_mask > 0; nr_mask--, mask++) { if (mask->irq == NO_WAKEUP_IRQ) { val |= mask->bit; continue; } data = irq_get_irq_data(mask->irq); /* bit of a liberty to read this directly from irq_data. */ if (irqd_is_wakeup_set(data)) val &= ~mask->bit; else val |= mask->bit; } printk(KERN_INFO "wakemask %08x => %08x\n", __raw_readl(reg), val); __raw_writel(val, reg); }Contributors
Person | Tokens | Prop | Commits | CommitProp |
Ben Dooks | 107 | 91.45% | 1 | 33.33% |
Thomas Gleixner | 9 | 7.69% | 1 | 33.33% |
Krzysztof Kozlowski | 1 | 0.85% | 1 | 33.33% |
Total | 117 | 100.00% | 3 | 100.00% |
Person | Tokens | Prop | Commits | CommitProp |
Ben Dooks | 130 | 89.04% | 1 | 20.00% |
Thomas Gleixner | 9 | 6.16% | 1 | 20.00% |
Krzysztof Kozlowski | 6 | 4.11% | 2 | 40.00% |
Kay Sievers | 1 | 0.68% | 1 | 20.00% |
Total | 146 | 100.00% | 5 | 100.00% |