From: Kevin Wolf <kwolf@redhat.com>
To: qemu-devel@nongnu.org
Cc: kwolf@redhat.com, stefanha@redhat.com
Subject: [Qemu-devel] [PATCH 1/5] ide: Reset BMIDEA bit when the bus master is stopped
Date: Wed, 8 May 2013 11:43:22 +0200 [thread overview]
Message-ID: <1368006206-2602-2-git-send-email-kwolf@redhat.com> (raw)
In-Reply-To: <1368006206-2602-1-git-send-email-kwolf@redhat.com>
The device is supposed to reset the Bus Master IDE Active bit in the
status register when 0 is written to the Start/Stop Bus Master bit in
the command register.
In the common cases this happens automatically because bdrv_drain_all()
flushes the requests, but with a large PRDT it could remain set.
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
---
hw/ide/pci.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/hw/ide/pci.c b/hw/ide/pci.c
index a310975..635a364 100644
--- a/hw/ide/pci.c
+++ b/hw/ide/pci.c
@@ -312,6 +312,7 @@ void bmdma_cmd_writeb(BMDMAState *bm, uint32_t val)
bdrv_drain_all();
assert(bm->bus->dma->aiocb == NULL);
}
+ bm->status &= ~BM_STATUS_DMAING;
} else {
bm->cur_addr = bm->addr;
if (!(bm->status & BM_STATUS_DMAING)) {
--
1.8.1.4
next prev parent reply other threads:[~2013-05-08 9:43 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-05-08 9:43 [Qemu-devel] [PATCH 1.5 0/5] ide: Test cases and a corner case fix Kevin Wolf
2013-05-08 9:43 ` Kevin Wolf [this message]
2013-05-08 14:35 ` [Qemu-devel] [PATCH 1/5] ide: Reset BMIDEA bit when the bus master is stopped Stefan Hajnoczi
2013-05-08 9:43 ` [Qemu-devel] [PATCH 2/5] libqos/pci: Enable bus mastering Kevin Wolf
2013-05-08 9:43 ` [Qemu-devel] [PATCH 3/5] qtest: Add IDE test case Kevin Wolf
2013-05-08 9:43 ` [Qemu-devel] [PATCH 4/5] qtest/ide-test: Add simple DMA read/write " Kevin Wolf
2013-05-08 16:28 ` Paolo Bonzini
2013-05-08 9:43 ` [Qemu-devel] [PATCH 5/5] qtest/ide-test: Test short and long PRDTs Kevin Wolf
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=1368006206-2602-2-git-send-email-kwolf@redhat.com \
--to=kwolf@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.