Lines Matching refs:handler

100 static void plic_toggle(struct plic_handler *handler, int hwirq, int enable)  in plic_toggle()  argument
102 raw_spin_lock(&handler->enable_lock); in plic_toggle()
103 __plic_toggle(handler->enable_base, hwirq, enable); in plic_toggle()
104 raw_spin_unlock(&handler->enable_lock); in plic_toggle()
113 struct plic_handler *handler = per_cpu_ptr(&plic_handlers, cpu); in plic_irq_toggle() local
115 plic_toggle(handler, d->hwirq, enable); in plic_irq_toggle()
145 struct plic_handler *handler = this_cpu_ptr(&plic_handlers); in plic_irq_eoi() local
147 writel(d->hwirq, handler->hart_base + CONTEXT_CLAIM); in plic_irq_eoi()
290 struct plic_handler *handler = this_cpu_ptr(&plic_handlers); in plic_handle_irq() local
292 void __iomem *claim = handler->hart_base + CONTEXT_CLAIM; in plic_handle_irq()
295 WARN_ON_ONCE(!handler->present); in plic_handle_irq()
300 int err = generic_handle_domain_irq(handler->priv->irqdomain, in plic_handle_irq()
310 static void plic_set_threshold(struct plic_handler *handler, u32 threshold) in plic_set_threshold() argument
313 writel(threshold, handler->hart_base + CONTEXT_THRESHOLD); in plic_set_threshold()
326 struct plic_handler *handler = this_cpu_ptr(&plic_handlers); in plic_starting_cpu() local
333 plic_set_threshold(handler, PLIC_ENABLE_THRESHOLD); in plic_starting_cpu()
345 struct plic_handler *handler; in __plic_init() local
427 handler = per_cpu_ptr(&plic_handlers, cpu); in __plic_init()
428 if (handler->present) { in __plic_init()
430 plic_set_threshold(handler, PLIC_DISABLE_THRESHOLD); in __plic_init()
435 handler->present = true; in __plic_init()
436 handler->hart_base = priv->regs + CONTEXT_BASE + in __plic_init()
438 raw_spin_lock_init(&handler->enable_lock); in __plic_init()
439 handler->enable_base = priv->regs + CONTEXT_ENABLE_BASE + in __plic_init()
441 handler->priv = priv; in __plic_init()
444 plic_toggle(handler, hwirq, 0); in __plic_init()
455 handler = this_cpu_ptr(&plic_handlers); in __plic_init()
456 if (handler->present && !plic_cpuhp_setup_done) { in __plic_init()