From: "Michael S. Tsirkin" <mst@redhat.com>
To: Alex Williamson <alex.williamson@redhat.com>
Cc: kvm@vger.kernel.org, qemu-devel@nongnu.org
Subject: Re: [PATCH 2/2] msix: Pull in config.h for CONFIG_KVM
Date: Sat, 23 Oct 2010 22:38:02 +0200 [thread overview]
Message-ID: <20101023203802.GA14723@redhat.com> (raw)
In-Reply-To: <1287859364.5129.12.camel@x201>
On Sat, Oct 23, 2010 at 12:42:44PM -0600, Alex Williamson wrote:
> On Sat, 2010-10-23 at 19:29 +0200, Michael S. Tsirkin wrote:
> > On Sat, Oct 23, 2010 at 10:52:43AM -0600, Alex Williamson wrote:
> > > On Sat, 2010-10-23 at 18:16 +0200, Michael S. Tsirkin wrote:
> > > > On Fri, Oct 22, 2010 at 02:40:39PM -0600, Alex Williamson wrote:
> > > > > We need to pull in config.h or else kvm.h doesn't pull in
> > > > > linux/config.h, which we need if we ever want KVM_CAP_IRQCHIP
> > > > > defined. This requires moving the object over to Makefile.target
> > > > > or else we can't find config-target.h
> > > > >
> > > > > Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
> > > >
> > > > Why? We just moved it from .target to .objs, see
> > > > 889e30cc18e21f2091b77267dca8096d7dd34f8b.
> > >
> > > Maybe that's why it used to work. When building in the qemu-kvm.git
> > > tree, I'm not getting CONFIG_KVM defined, which means I'm not getting
> > > KVM_CAP_IRQCHIP defined, which results in msix_irq_entries not being
> > > allocated. Then when I call msix_vector_use, I get a seg fault.
> > > Something is broken there. Thanks,
> > >
> > > Alex
> >
> > This is hopefully fixed in the latest bits.
> > bd8b215bce453706c3951460cc7e6627ccb90314
>
> Nope, my tree includes that. It's not kvm_set_irq, it's kvm_msix_add,
> which dereferences msix_irq_entries, which is only allocated in
> msix_init if KVM_CAP_IRQCHIP is defined, which it's not. Maybe you also
> meant to remove the ifdef from msix_init? I also note there's another
> in msix_notify. Thanks,
>
> Alex
Not sure what's wrong:
$git grep KVM_CAP_IRQCHIP origin/master -- hw/msix.c
$
http://git.kernel.org/?p=virt/kvm/qemu-kvm.git;a=blob;f=hw/msix.c;hb=HEAD
also does not show any ifdefs.
--
MST
WARNING: multiple messages have this Message-ID (diff)
From: "Michael S. Tsirkin" <mst@redhat.com>
To: Alex Williamson <alex.williamson@redhat.com>
Cc: qemu-devel@nongnu.org, kvm@vger.kernel.org
Subject: [Qemu-devel] Re: [PATCH 2/2] msix: Pull in config.h for CONFIG_KVM
Date: Sat, 23 Oct 2010 22:38:02 +0200 [thread overview]
Message-ID: <20101023203802.GA14723@redhat.com> (raw)
In-Reply-To: <1287859364.5129.12.camel@x201>
On Sat, Oct 23, 2010 at 12:42:44PM -0600, Alex Williamson wrote:
> On Sat, 2010-10-23 at 19:29 +0200, Michael S. Tsirkin wrote:
> > On Sat, Oct 23, 2010 at 10:52:43AM -0600, Alex Williamson wrote:
> > > On Sat, 2010-10-23 at 18:16 +0200, Michael S. Tsirkin wrote:
> > > > On Fri, Oct 22, 2010 at 02:40:39PM -0600, Alex Williamson wrote:
> > > > > We need to pull in config.h or else kvm.h doesn't pull in
> > > > > linux/config.h, which we need if we ever want KVM_CAP_IRQCHIP
> > > > > defined. This requires moving the object over to Makefile.target
> > > > > or else we can't find config-target.h
> > > > >
> > > > > Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
> > > >
> > > > Why? We just moved it from .target to .objs, see
> > > > 889e30cc18e21f2091b77267dca8096d7dd34f8b.
> > >
> > > Maybe that's why it used to work. When building in the qemu-kvm.git
> > > tree, I'm not getting CONFIG_KVM defined, which means I'm not getting
> > > KVM_CAP_IRQCHIP defined, which results in msix_irq_entries not being
> > > allocated. Then when I call msix_vector_use, I get a seg fault.
> > > Something is broken there. Thanks,
> > >
> > > Alex
> >
> > This is hopefully fixed in the latest bits.
> > bd8b215bce453706c3951460cc7e6627ccb90314
>
> Nope, my tree includes that. It's not kvm_set_irq, it's kvm_msix_add,
> which dereferences msix_irq_entries, which is only allocated in
> msix_init if KVM_CAP_IRQCHIP is defined, which it's not. Maybe you also
> meant to remove the ifdef from msix_init? I also note there's another
> in msix_notify. Thanks,
>
> Alex
Not sure what's wrong:
$git grep KVM_CAP_IRQCHIP origin/master -- hw/msix.c
$
http://git.kernel.org/?p=virt/kvm/qemu-kvm.git;a=blob;f=hw/msix.c;hb=HEAD
also does not show any ifdefs.
--
MST
next prev parent reply other threads:[~2010-10-23 20:44 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-10-22 20:31 [PATCH 0/2] msix: couple fixes Alex Williamson
2010-10-22 20:31 ` [Qemu-devel] " Alex Williamson
2010-10-22 20:40 ` [PATCH 1/2] msix: Allow msix_init on a device with existing MSI-X capability Alex Williamson
2010-10-22 20:40 ` [Qemu-devel] " Alex Williamson
2010-10-23 16:18 ` Michael S. Tsirkin
2010-10-23 16:18 ` [Qemu-devel] " Michael S. Tsirkin
2010-10-23 16:55 ` Alex Williamson
2010-10-23 16:55 ` [Qemu-devel] " Alex Williamson
2010-10-28 15:00 ` Avi Kivity
2010-10-28 15:00 ` [Qemu-devel] " Avi Kivity
2010-11-01 15:56 ` Alex Williamson
2010-11-01 15:56 ` [Qemu-devel] " Alex Williamson
2010-10-22 20:40 ` [PATCH 2/2] msix: Pull in config.h for CONFIG_KVM Alex Williamson
2010-10-22 20:40 ` [Qemu-devel] " Alex Williamson
2010-10-23 1:50 ` Alex Williamson
2010-10-23 1:50 ` [Qemu-devel] " Alex Williamson
2010-10-23 7:41 ` Paolo Bonzini
2010-10-23 7:41 ` [Qemu-devel] " Paolo Bonzini
2010-10-23 16:16 ` Michael S. Tsirkin
2010-10-23 16:16 ` [Qemu-devel] " Michael S. Tsirkin
2010-10-23 16:52 ` Alex Williamson
2010-10-23 16:52 ` [Qemu-devel] " Alex Williamson
2010-10-23 17:29 ` Michael S. Tsirkin
2010-10-23 17:29 ` [Qemu-devel] " Michael S. Tsirkin
2010-10-23 18:42 ` Alex Williamson
2010-10-23 18:42 ` [Qemu-devel] " Alex Williamson
2010-10-23 20:38 ` Michael S. Tsirkin [this message]
2010-10-23 20:38 ` Michael S. Tsirkin
2010-10-23 21:01 ` Alex Williamson
2010-10-23 21:01 ` [Qemu-devel] " Alex Williamson
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=20101023203802.GA14723@redhat.com \
--to=mst@redhat.com \
--cc=alex.williamson@redhat.com \
--cc=kvm@vger.kernel.org \
--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 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.