From: wentongw <wentong.wu@intel.com>
To: qemu-devel@nongnu.org
Cc: qemu-trivial@nongnu.org, marex@denx.de, thuth@redhat.com,
crwulff@gmail.com, wentongw <wentong.wu@intel.com>
Subject: [PATCH] hw/nios2: Update interrupt request when CR_STATUS_PIE disabled
Date: Thu, 11 Jun 2020 04:13:19 -0400 [thread overview]
Message-ID: <20200611081319.1864-1-wentong.wu@intel.com> (raw)
Update interrupt request when external interupt pends for STATUS_PIE
disabled. Otherwise on icount enabled nios2 target there will be cpu
abort when guest code changes state register with wrctl instruction.
Signed-off-by: Wentong Wu <wentong.wu@intel.com>
---
hw/nios2/cpu_pic.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/hw/nios2/cpu_pic.c b/hw/nios2/cpu_pic.c
index 1c1989d5..2abc8fa8 100644
--- a/hw/nios2/cpu_pic.c
+++ b/hw/nios2/cpu_pic.c
@@ -42,6 +42,8 @@ static void nios2_pic_cpu_handler(void *opaque, int irq, int level)
} else if (!level) {
env->irq_pending = 0;
cpu_reset_interrupt(cs, type);
+ } else {
+ cs->interrupt_request |= type;
}
} else {
if (level) {
--
2.21.3
next reply other threads:[~2020-06-11 0:23 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-06-11 8:13 wentongw [this message]
2020-06-12 13:43 ` [PATCH] hw/nios2: Update interrupt request when CR_STATUS_PIE disabled Wu, Wentong
2020-06-12 15:31 ` Philippe Mathieu-Daudé
2020-06-16 15:05 ` Wu, Wentong
2020-06-16 15:39 ` Peter Maydell
2020-06-18 3:08 ` Wu, Wentong
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200611081319.1864-1-wentong.wu@intel.com \
--to=wentong.wu@intel.com \
--cc=crwulff@gmail.com \
--cc=marex@denx.de \
--cc=qemu-devel@nongnu.org \
--cc=qemu-trivial@nongnu.org \
--cc=thuth@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).