From: "Michael S. Tsirkin" <mst@redhat.com>
To: qemu-devel@nongnu.org, aliguori@us.ibm.com, yvugenfi@redhat.com
Subject: [Qemu-devel] [PATCH] virtio-pci: thinko fix
Date: Mon, 11 Jan 2010 17:57:41 +0200 [thread overview]
Message-ID: <20100111155739.GA8588@redhat.com> (raw)
Since patch ed757e140c0ada220f213036e4497315d24ca8bct, virtio will
sometimes clear all status registers on bus master disable, which loses
information such as VIRTIO_CONFIG_S_FAILED bit. This is a result of
a patch being misapplied: code uses ! instead of ~ for bit
operations as in Yan's original patch. This obviously does not make
sense.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
---
hw/virtio-pci.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/hw/virtio-pci.c b/hw/virtio-pci.c
index d222ce0..f4f1bc1 100644
--- a/hw/virtio-pci.c
+++ b/hw/virtio-pci.c
@@ -374,7 +374,7 @@ static void virtio_write_config(PCIDevice *pci_dev, uint32_t address,
if (PCI_COMMAND == address) {
if (!(val & PCI_COMMAND_MASTER)) {
- proxy->vdev->status &= !VIRTIO_CONFIG_S_DRIVER_OK;
+ proxy->vdev->status &= ~VIRTIO_CONFIG_S_DRIVER_OK;
}
}
--
1.6.6.rc1.43.gf55cc
next reply other threads:[~2010-01-11 16:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-11 15:57 Michael S. Tsirkin [this message]
2010-01-11 19:47 ` [Qemu-devel] [PATCH] virtio-pci: thinko fix 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=20100111155739.GA8588@redhat.com \
--to=mst@redhat.com \
--cc=aliguori@us.ibm.com \
--cc=qemu-devel@nongnu.org \
--cc=yvugenfi@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).