blob: f1e9067bd5ac1090e271b6430ba271d64397fc84 [file] [log] [blame]
Greg Kroah-Hartmanb2441312017-11-01 15:07:57 +01001/* SPDX-License-Identifier: GPL-2.0 */
Anton Blanchard8c007bf2010-01-31 20:30:23 +00002#ifndef _ASM_POWERPC_HARDIRQ_H
3#define _ASM_POWERPC_HARDIRQ_H
4
5#include <linux/threads.h>
6#include <linux/irq.h>
7
8typedef struct {
9 unsigned int __softirq_pending;
fan.duc041cfa2013-01-23 16:06:11 +080010 unsigned int timer_irqs_event;
Nicholas Piggine360cd32018-05-05 03:19:35 +100011 unsigned int broadcast_irqs_event;
fan.duc041cfa2013-01-23 16:06:11 +080012 unsigned int timer_irqs_others;
Anton Blanchard89713ed2010-01-31 20:34:06 +000013 unsigned int pmu_irqs;
14 unsigned int mce_exceptions;
Anton Blanchard170811022010-01-31 20:34:36 +000015 unsigned int spurious_irqs;
Mahesh Salgaonkar0869b6f2014-07-29 18:40:01 +053016 unsigned int hmi_exceptions;
Nicholas Pigginca41ad42017-08-01 22:00:53 +100017 unsigned int sreset_irqs;
Nicholas Piggin04019bf2017-08-01 22:00:54 +100018#ifdef CONFIG_PPC_WATCHDOG
19 unsigned int soft_nmi_irqs;
20#endif
Ian Munsiea6a058e2013-03-21 19:22:52 +000021#ifdef CONFIG_PPC_DOORBELL
22 unsigned int doorbell_irqs;
23#endif
Anton Blanchard8c007bf2010-01-31 20:30:23 +000024} ____cacheline_aligned irq_cpustat_t;
25
26DECLARE_PER_CPU_SHARED_ALIGNED(irq_cpustat_t, irq_stat);
27
28#define __ARCH_IRQ_STAT
Nicholas Pigginc16bee42017-11-17 02:00:49 +100029#define __ARCH_IRQ_EXIT_IRQS_DISABLED
Christoph Lameter69111ba2014-10-21 15:23:25 -050030
Anton Blanchard8c007bf2010-01-31 20:30:23 +000031static inline void ack_bad_irq(unsigned int irq)
32{
33 printk(KERN_CRIT "unexpected IRQ trap at vector %02x\n", irq);
34}
35
Anton Blanchard89713ed2010-01-31 20:34:06 +000036extern u64 arch_irq_stat_cpu(unsigned int cpu);
37#define arch_irq_stat_cpu arch_irq_stat_cpu
38
Anton Blanchard8c007bf2010-01-31 20:30:23 +000039#endif /* _ASM_POWERPC_HARDIRQ_H */