From: "Michael S. Tsirkin" <mst@redhat.com>
To: Jan Kiszka <jan.kiszka@siemens.com>
Cc: Avi Kivity <avi@redhat.com>,
Marcelo Tosatti <mtosatti@redhat.com>, kvm <kvm@vger.kernel.org>,
Michael Tokarev <mjt@tls.msk.ru>
Subject: Re: [PATCH stable-1.1] qemu-kvm: virtio: Do not register mask notifiers without in-kernel irqchip support
Date: Mon, 2 Jul 2012 12:12:17 +0300 [thread overview]
Message-ID: <20120702091217.GE8268@redhat.com> (raw)
In-Reply-To: <4FF15653.7020506@siemens.com>
On Mon, Jul 02, 2012 at 10:05:39AM +0200, Jan Kiszka wrote:
> We crash if we registers mask notifiers without backing in-kernel
> irqchip. This corresponds to the check in QEMU upstream after 1.1 now.
>
> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Acked-by: Michael S. Tsirkin <mst@redhat.com>
> ---
>
> Not needed for master as we have upstream logic there already.
>
> hw/virtio-pci.c | 4 ++--
> 1 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/hw/virtio-pci.c b/hw/virtio-pci.c
> index a0c2ca7..5b64356 100644
> --- a/hw/virtio-pci.c
> +++ b/hw/virtio-pci.c
> @@ -629,7 +629,7 @@ static int virtio_pci_set_guest_notifiers(void *opaque, bool assign)
>
> /* Must unset mask notifier while guest notifier
> * is still assigned */
> - if (!assign) {
> + if (kvm_irqchip_in_kernel() && !assign) {
> r = msix_unset_mask_notifier(&proxy->pci_dev);
> assert(r >= 0);
> }
> @@ -647,7 +647,7 @@ static int virtio_pci_set_guest_notifiers(void *opaque, bool assign)
>
> /* Must set mask notifier after guest notifier
> * has been assigned */
> - if (assign) {
> + if (kvm_irqchip_in_kernel() && assign) {
> r = msix_set_mask_notifier(&proxy->pci_dev,
> virtio_pci_mask_notifier);
> if (r < 0) {
> --
> 1.7.3.4
prev parent reply other threads:[~2012-07-02 9:12 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-07-02 8:05 [PATCH stable-1.1] qemu-kvm: virtio: Do not register mask notifiers without in-kernel irqchip support Jan Kiszka
2012-07-02 9:12 ` Michael S. Tsirkin [this message]
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=20120702091217.GE8268@redhat.com \
--to=mst@redhat.com \
--cc=avi@redhat.com \
--cc=jan.kiszka@siemens.com \
--cc=kvm@vger.kernel.org \
--cc=mjt@tls.msk.ru \
--cc=mtosatti@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.