qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Question about edge-triggered interrupt


From: LIU Zhiwei
Subject: Question about edge-triggered interrupt
Date: Thu, 11 Mar 2021 10:57:46 +0800
User-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.8.0

Hi folks,

Currently, I am writing an interrupt controller (CLIC) for RISC-V.  I can't find a good way to process edge-triggered interrupt.

According to edge-triggered definition, if I select an edge-triggered  interrupt to serve , it will clean its pending status. However after serving the interrupt,  there is no chance to select other pending interrupts.

I have two methods.
  1. One is to add a timer for interrupt controller, so that every pending interrupt can be served at some point.
  2. The other is that  always pull a pending interrupt to serve at the interrupt return instruction.
But both are not so good. The first one we can not server the interrupts immediately. The second one we have to add some
code when executing the guest code.

I want to know if there is a better way to handle edge-triggered interrupt on QEMU.

Thanks very much for your reading and look forward to your  response.

Zhiwei



reply via email to

[Prev in Thread] Current Thread [Next in Thread]