mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-22 09:17:58 +00:00
HV:Added implementation for PMI handler function
irq.c/.h: Added new variables(ctx_rflags, ctx_rip, ctx_cs) in irq_desc On each interrupt this information is populated Added api's to access the irq_desc members profiling.c: profiling_pmi_handler:On each PMI generates gets the context and other information that caused it Tracked-On: projectacrn#1409 Acked-by: Eddie Dong <eddie.dong@intel.com> Signed-off-by: Chinthapally, Manisha <manisha.chinthapally@intel.com>
This commit is contained in:
committed by
wenlingz
parent
a7cbee1802
commit
5985c1216e
@@ -12,7 +12,7 @@ static spinlock_t irq_alloc_spinlock = { .head = 0U, .tail = 0U, };
|
||||
|
||||
#define IRQ_ALLOC_BITMAP_SIZE INT_DIV_ROUNDUP(NR_IRQS, 64U)
|
||||
static uint64_t irq_alloc_bitmap[IRQ_ALLOC_BITMAP_SIZE];
|
||||
static struct irq_desc irq_desc_array[NR_IRQS];
|
||||
struct irq_desc irq_desc_array[NR_IRQS];
|
||||
static uint32_t vector_to_irq[NR_MAX_VECTOR + 1];
|
||||
|
||||
spurious_handler_t spurious_handler;
|
||||
@@ -350,7 +350,12 @@ void dispatch_interrupt(const struct intr_excp_ctx *ctx)
|
||||
/* mask irq if possible */
|
||||
goto ERR;
|
||||
}
|
||||
|
||||
#ifdef PROFILING_ON
|
||||
/* Saves ctx info into irq_desc */
|
||||
desc->ctx_rip = ctx->rip;
|
||||
desc->ctx_rflags = ctx->rflags;
|
||||
desc->ctx_cs = ctx->cs;
|
||||
#endif
|
||||
handle_irq(desc);
|
||||
return;
|
||||
ERR:
|
||||
|
Reference in New Issue
Block a user