qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Kevin Wolf <kwolf@redhat.com>
To: anthony@codemonkey.ws
Cc: kwolf@redhat.com, qemu-devel@nongnu.org
Subject: [Qemu-devel] [PATCH 15/15] AHCI: Masking of IRQs actually masks them
Date: Fri, 10 Feb 2012 13:47:44 +0100	[thread overview]
Message-ID: <1328878064-4907-16-git-send-email-kwolf@redhat.com> (raw)
In-Reply-To: <1328878064-4907-1-git-send-email-kwolf@redhat.com>

From: Alexander Graf <agraf@suse.de>

When masking IRQ lines, we should actually mask them out and not declare
them active anymore. Once we mask them in again, they are allowed to trigger
again.

Signed-off-by: Alexander Graf <agraf@suse.de>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
---
 hw/ide/ahci.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/hw/ide/ahci.c b/hw/ide/ahci.c
index caff7bc..f7ef114 100644
--- a/hw/ide/ahci.c
+++ b/hw/ide/ahci.c
@@ -146,6 +146,7 @@ static void ahci_check_irq(AHCIState *s)
 
     DPRINTF(-1, "check irq %#x\n", s->control_regs.irqstatus);
 
+    s->control_regs.irqstatus = 0;
     for (i = 0; i < s->ports; i++) {
         AHCIPortRegs *pr = &s->dev[i].port_regs;
         if (pr->irq_stat & pr->irq_mask) {
@@ -216,6 +217,7 @@ static void  ahci_port_write(AHCIState *s, int port, int offset, uint32_t val)
             break;
         case PORT_IRQ_STAT:
             pr->irq_stat &= ~val;
+            ahci_check_irq(s);
             break;
         case PORT_IRQ_MASK:
             pr->irq_mask = val & 0xfdc000ff;
-- 
1.7.6.5

  parent reply	other threads:[~2012-02-10 12:46 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-10 12:47 [Qemu-devel] [PULL 00/15] Block patches Kevin Wolf
2012-02-10 12:47 ` [Qemu-devel] [PATCH 01/15] cutils: extract buffer_is_zero() from qemu-img.c Kevin Wolf
2012-02-10 12:47 ` [Qemu-devel] [PATCH 02/15] block: add .bdrv_co_write_zeroes() interface Kevin Wolf
2012-02-10 12:47 ` [Qemu-devel] [PATCH 03/15] block: perform zero-detection during copy-on-read Kevin Wolf
2012-02-10 12:47 ` [Qemu-devel] [PATCH 04/15] qed: replace is_write with flags field Kevin Wolf
2012-02-10 12:47 ` [Qemu-devel] [PATCH 05/15] qed: add .bdrv_co_write_zeroes() support Kevin Wolf
2012-02-10 12:47 ` [Qemu-devel] [PATCH 06/15] qemu-io: add write -z option for bdrv_co_write_zeroes Kevin Wolf
2012-02-10 12:47 ` [Qemu-devel] [PATCH 07/15] iSCSI: add configuration variables for iSCSI Kevin Wolf
2012-02-10 12:47 ` [Qemu-devel] [PATCH 08/15] vpc: Add support for Fixed Disk type Kevin Wolf
2012-02-10 12:47 ` [Qemu-devel] [PATCH 09/15] vpc: Round up image size during fixed image creation Kevin Wolf
2012-02-10 12:47 ` [Qemu-devel] [PATCH 10/15] qcow2: Update whole header at once Kevin Wolf
2012-02-10 12:47 ` [Qemu-devel] [PATCH 11/15] qcow2: Keep unknown header extension when rewriting header Kevin Wolf
2012-02-10 12:47 ` [Qemu-devel] [PATCH 12/15] rewrite QEMU_BUILD_BUG_ON Kevin Wolf
2012-02-10 12:47 ` [Qemu-devel] [PATCH 13/15] AHCI: Fix port reset race Kevin Wolf
2012-02-10 12:47 ` [Qemu-devel] [PATCH 14/15] sheepdog: fix co_recv coroutine context Kevin Wolf
2012-02-10 12:47 ` Kevin Wolf [this message]
2012-02-15 10:14 ` [Qemu-devel] [PULL 00/15] Block patches Kevin Wolf
2012-02-16  0:31 ` Anthony Liguori

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=1328878064-4907-16-git-send-email-kwolf@redhat.com \
    --to=kwolf@redhat.com \
    --cc=anthony@codemonkey.ws \
    --cc=qemu-devel@nongnu.org \
    /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).