public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Alex Williamson <alex.williamson@redhat.com>
To: Alexey Kardashevskiy <aik@ozlabs.ru>
Cc: linux-kernel@vger.kernel.org, kvm@vger.kernel.org
Subject: Re: [PATCH kernel] vfio-pci: Add missing break to enable VFIO_PCI_ERR_IRQ_INDEX
Date: Thu, 12 Mar 2015 10:36:22 -0600	[thread overview]
Message-ID: <1426178182.3643.21.camel@redhat.com> (raw)
In-Reply-To: <1426131792-637-1-git-send-email-aik@ozlabs.ru>

On Thu, 2015-03-12 at 14:43 +1100, Alexey Kardashevskiy wrote:
> This adds a missing break statement to VFIO_DEVICE_SET_IRQS handler
> without which vfio_pci_set_err_trigger() would never be called.
> 
> While we are here, add another "break" to VFIO_PCI_REQ_IRQ_INDEX case
> so if we add more indexes later, we won't miss it.
> 
> Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>
> ---
>  drivers/vfio/pci/vfio_pci_intrs.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/drivers/vfio/pci/vfio_pci_intrs.c b/drivers/vfio/pci/vfio_pci_intrs.c
> index f88bfdf..2027a27 100644
> --- a/drivers/vfio/pci/vfio_pci_intrs.c
> +++ b/drivers/vfio/pci/vfio_pci_intrs.c
> @@ -868,12 +868,14 @@ int vfio_pci_set_irqs_ioctl(struct vfio_pci_device *vdev, uint32_t flags,
>  				func = vfio_pci_set_err_trigger;
>  			break;
>  		}
> +		break;
>  	case VFIO_PCI_REQ_IRQ_INDEX:
>  		switch (flags & VFIO_IRQ_SET_ACTION_TYPE_MASK) {
>  		case VFIO_IRQ_SET_ACTION_TRIGGER:
>  			func = vfio_pci_set_req_trigger;
>  			break;
>  		}
> +		break;
>  	}
>  
>  	if (!func)

Whoops, that's no good.  Added to my for-linus branch for v4.0.  Thanks
for the fix!

Alex


      reply	other threads:[~2015-03-12 16:36 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-12  3:43 [PATCH kernel] vfio-pci: Add missing break to enable VFIO_PCI_ERR_IRQ_INDEX Alexey Kardashevskiy
2015-03-12 16:36 ` Alex Williamson [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=1426178182.3643.21.camel@redhat.com \
    --to=alex.williamson@redhat.com \
    --cc=aik@ozlabs.ru \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.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