From: "Michael S. Tsirkin" <mst@redhat.com>
To: Paul Brook <paul@codesourcery.com>, Avi Kivity <avi@redhat.com>,
qemu-devel@nongnu.org, Carsten Otte <cotte@de.ibm.com>,
kvm@vger.kernel.org, Rusty Russell <rusty@rustcorp.com.au>,
virtualization@lists.linux-foundation.org,
Christian Borntraeger <borntraeger@de.ibm.com>,
Blue Swirl <blauwirbel@gmail.com>,
Anthony Liguori <anthony@codemonkey.ws>,
Glauber Costa <glommer@redhat.com>
Subject: [Qemu-devel] [PATCHv2 RFC] qemu/msix: remove msix_supported safety flag
Date: Sun, 21 Jun 2009 20:04:22 +0300 [thread overview]
Message-ID: <20090621170422.GA10263@redhat.com> (raw)
Don't add an option for platforms to disable MSI-X in all devices.
Paul Brook will find and fix all platforms that have broken MSI-X
emulation.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
---
This patch on top of my msix series v6 is a bit tongue in cheek: it
shows what can be done and Paul seems to think it's a good idea. So even
though I don't necessarily agree, I'll let others decide on it.
Changes since v1:
rebased on top of MSIXv6.
hw/apic.c | 1 -
hw/msix.c | 7 -------
hw/msix.h | 2 --
3 files changed, 0 insertions(+), 10 deletions(-)
diff --git a/hw/apic.c b/hw/apic.c
index 3bcab46..2ac87d1 100644
--- a/hw/apic.c
+++ b/hw/apic.c
@@ -965,7 +965,6 @@ int apic_init(CPUState *env)
s->cpu_env = env;
apic_reset(s);
- msix_supported = 1;
/* XXX: mapping more APICs at the same memory location */
if (apic_io_memory == 0) {
diff --git a/hw/msix.c b/hw/msix.c
index 773581f..6eb51c3 100644
--- a/hw/msix.c
+++ b/hw/msix.c
@@ -59,9 +59,6 @@
#define DEBUG(fmt, ...) do { } while(0)
#endif
-/* Flag for interrupt controller to declare MSI-X support */
-int msix_supported;
-
/* Add MSI-X capability to the config space for the device. */
/* Given a bar and its size, add MSI-X table on top of it
* and fill MSI-X capability in the config space.
@@ -227,10 +224,6 @@ int msix_init(struct PCIDevice *dev, unsigned short nentries,
unsigned bar_nr, unsigned bar_size)
{
int ret;
- /* Nothing to do if MSI is not supported by interrupt controller */
- if (!msix_supported)
- return -ENOTSUP;
-
if (nentries > MSIX_MAX_ENTRIES)
return -EINVAL;
diff --git a/hw/msix.h b/hw/msix.h
index 3427778..27f2dad 100644
--- a/hw/msix.h
+++ b/hw/msix.h
@@ -29,6 +29,4 @@ void msix_notify(PCIDevice *dev, unsigned vector);
void msix_reset(PCIDevice *dev);
-extern int msix_supported;
-
#endif
--
1.6.2.2
reply other threads:[~2009-06-21 17:07 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20090621170422.GA10263@redhat.com \
--to=mst@redhat.com \
--cc=anthony@codemonkey.ws \
--cc=avi@redhat.com \
--cc=blauwirbel@gmail.com \
--cc=borntraeger@de.ibm.com \
--cc=cotte@de.ibm.com \
--cc=glommer@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=paul@codesourcery.com \
--cc=qemu-devel@nongnu.org \
--cc=rusty@rustcorp.com.au \
--cc=virtualization@lists.linux-foundation.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).