irqchip: gic-v3: Add support to get pending irqs
Add APIs to show pending interrupts in GIC. Change-Id: Ifb7e515a06d6eb1fda82e0287e6c8084f4707c99 Signed-off-by: Swetha Chikkaboraiah <schikk@codeaurora.org>
This commit is contained in:
parent
464112e0b7
commit
a95fbbfa70
2 changed files with 24 additions and 0 deletions
|
@ -344,6 +344,29 @@ static int gic_suspend(void)
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* gic_show_pending_irq - Shows the pending interrupts
|
||||||
|
* Note: Interrupts should be disabled on the cpu from which
|
||||||
|
* this is called to get accurate list of pending interrupts.
|
||||||
|
*/
|
||||||
|
void gic_show_pending_irqs(void)
|
||||||
|
{
|
||||||
|
void __iomem *base;
|
||||||
|
u32 pending, enabled;
|
||||||
|
unsigned int j;
|
||||||
|
|
||||||
|
base = gic_data.dist_base;
|
||||||
|
for (j = 0; j * 32 < gic_data.irq_nr; j++) {
|
||||||
|
enabled = readl_relaxed(base +
|
||||||
|
GICD_ISENABLER + j * 4);
|
||||||
|
pending = readl_relaxed(base +
|
||||||
|
GICD_ISPENDR + j * 4);
|
||||||
|
pr_err("Pending and enabled irqs[%d] %x %x\n", j,
|
||||||
|
pending, enabled);
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
static void gic_show_resume_irq(struct gic_chip_data *gic)
|
static void gic_show_resume_irq(struct gic_chip_data *gic)
|
||||||
{
|
{
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
|
|
@ -594,6 +594,7 @@ struct rdists {
|
||||||
};
|
};
|
||||||
|
|
||||||
struct irq_domain;
|
struct irq_domain;
|
||||||
|
void gic_show_pending_irqs(void);
|
||||||
struct fwnode_handle;
|
struct fwnode_handle;
|
||||||
int its_cpu_init(void);
|
int its_cpu_init(void);
|
||||||
int its_init(struct fwnode_handle *handle, struct rdists *rdists,
|
int its_init(struct fwnode_handle *handle, struct rdists *rdists,
|
||||||
|
|
Loading…
Add table
Reference in a new issue