• Home
  • Raw
  • Download

Lines Matching full:vic

2  *  linux/arch/arm/common/vic.c
36 #include <linux/irqchip/arm-vic.h>
52 #define VIC_ITCR 0x300 /* VIC test control register */
59 * struct vic_device - VIC PM device
60 * @parent_irq: The parent IRQ number of the VIC if cascaded, or 0.
61 * @irq: The IRQ number for the base of the VIC.
62 * @base: The register base for the VIC.
70 * @domain: The IRQ domain for the VIC.
94 * @base: Base of the VIC.
112 static void resume_one_vic(struct vic_device *vic) in resume_one_vic() argument
114 void __iomem *base = vic->base; in resume_one_vic()
116 printk(KERN_DEBUG "%s: resuming vic at %p\n", __func__, base); in resume_one_vic()
121 writel(vic->int_select, base + VIC_INT_SELECT); in resume_one_vic()
122 writel(vic->protect, base + VIC_PROTECT); in resume_one_vic()
125 writel(vic->int_enable, base + VIC_INT_ENABLE); in resume_one_vic()
126 writel(~vic->int_enable, base + VIC_INT_ENABLE_CLEAR); in resume_one_vic()
130 writel(vic->soft_int, base + VIC_INT_SOFT); in resume_one_vic()
131 writel(~vic->soft_int, base + VIC_INT_SOFT_CLEAR); in resume_one_vic()
142 static void suspend_one_vic(struct vic_device *vic) in suspend_one_vic() argument
144 void __iomem *base = vic->base; in suspend_one_vic()
146 printk(KERN_DEBUG "%s: suspending vic at %p\n", __func__, base); in suspend_one_vic()
148 vic->int_select = readl(base + VIC_INT_SELECT); in suspend_one_vic()
149 vic->int_enable = readl(base + VIC_INT_ENABLE); in suspend_one_vic()
150 vic->soft_int = readl(base + VIC_INT_SOFT); in suspend_one_vic()
151 vic->protect = readl(base + VIC_PROTECT); in suspend_one_vic()
156 writel(vic->resume_irqs, base + VIC_INT_ENABLE); in suspend_one_vic()
157 writel(~vic->resume_irqs, base + VIC_INT_ENABLE_CLEAR); in suspend_one_vic()
176 * vic_pm_init - initicall to register VIC pm
180 * nature of the VIC's registration.
209 * Handle each interrupt in a single VIC. Returns non-zero if we've
214 static int handle_one_vic(struct vic_device *vic, struct pt_regs *regs) in handle_one_vic() argument
219 while ((stat = readl_relaxed(vic->base + VIC_IRQ_STATUS))) { in handle_one_vic()
221 handle_domain_irq(vic->domain, irq, regs); in handle_one_vic()
232 struct vic_device *vic = irq_desc_get_handler_data(desc); in vic_handle_irq_cascaded() local
236 while ((stat = readl_relaxed(vic->base + VIC_IRQ_STATUS))) { in vic_handle_irq_cascaded()
238 generic_handle_irq(irq_find_mapping(vic->domain, hwirq)); in vic_handle_irq_cascaded()
245 * Keep iterating over all registered VIC's until there are no pending
264 * vic_register() - Register a VIC.
265 * @base: The base address of the VIC.
267 * @irq: The base IRQ for the VIC.
270 * @node: The device tree node associated with the VIC.
272 * Register the VIC with the system device tree so that it can be notified
276 * This also configures the IRQ domain for the VIC.
378 .name = "VIC",
452 /* Identify which VIC cell this one is, by reading the ID */ in __vic_init()
459 printk(KERN_INFO "VIC @%p: id 0x%08x, vendor 0x%02x\n", in __vic_init()
467 printk(KERN_WARNING "VIC: unknown vendor, continuing anyways\n"); in __vic_init()
543 IRQCHIP_DECLARE(arm_pl190_vic, "arm,pl190-vic", vic_of_init);
544 IRQCHIP_DECLARE(arm_pl192_vic, "arm,pl192-vic", vic_of_init);
545 IRQCHIP_DECLARE(arm_versatile_vic, "arm,versatile-vic", vic_of_init);