All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jesse Barnes <jbarnes@virtuousgeek.org>
To: Sheng Yang <sheng@linux.intel.com>
Cc: Avi Kivity <avi@redhat.com>,
	Marcelo Tosatti <mtosatti@redhat.com>,
	"Michael S. Tsirkin" <mst@redhat.com>,
	kvm@vger.kernel.org, Matthew Wilcox <willy@linux.intel.com>,
	linux-pci@vger.kernel.org
Subject: Re: [PATCH 2/7] PCI: Add mask bit definition for MSI-X table
Date: Thu, 11 Nov 2010 09:29:29 -0800	[thread overview]
Message-ID: <20101111092929.7bed35aa@jbarnes-desktop> (raw)
In-Reply-To: <1289461620-7055-3-git-send-email-sheng@linux.intel.com>

On Thu, 11 Nov 2010 15:46:55 +0800
Sheng Yang <sheng@linux.intel.com> wrote:

> Then we can use it instead of magic number 1.
> 
> Reviewed-by: Hidetoshi Seto <seto.hidetoshi@jp.fujitsu.com>
> Cc: Matthew Wilcox <willy@linux.intel.com>
> Cc: Jesse Barnes <jbarnes@virtuousgeek.org>
> Cc: linux-pci@vger.kernel.org
> Signed-off-by: Sheng Yang <sheng@linux.intel.com>
> ---
>  drivers/pci/msi.c        |    5 +++--
>  include/linux/pci_regs.h |    1 +
>  2 files changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/pci/msi.c b/drivers/pci/msi.c
> index 69b7be3..095634e 100644
> --- a/drivers/pci/msi.c
> +++ b/drivers/pci/msi.c
> @@ -158,8 +158,9 @@ static u32 __msix_mask_irq(struct msi_desc *desc, u32 flag)
>  	u32 mask_bits = desc->masked;
>  	unsigned offset = desc->msi_attrib.entry_nr * PCI_MSIX_ENTRY_SIZE +
>  						PCI_MSIX_ENTRY_VECTOR_CTRL;
> -	mask_bits &= ~1;
> -	mask_bits |= flag;
> +	mask_bits &= ~PCI_MSIX_ENTRY_CTRL_MASKBIT;
> +	if (flag)
> +		mask_bits |= PCI_MSIX_ENTRY_CTRL_MASKBIT;
>  	writel(mask_bits, desc->mask_base + offset);
>  
>  	return mask_bits;
> diff --git a/include/linux/pci_regs.h b/include/linux/pci_regs.h
> index acfc224..ff51632 100644
> --- a/include/linux/pci_regs.h
> +++ b/include/linux/pci_regs.h
> @@ -313,6 +313,7 @@
>  #define  PCI_MSIX_ENTRY_UPPER_ADDR	4
>  #define  PCI_MSIX_ENTRY_DATA		8
>  #define  PCI_MSIX_ENTRY_VECTOR_CTRL	12
> +#define   PCI_MSIX_ENTRY_CTRL_MASKBIT	1
>  
>  /* CompactPCI Hotswap Register */
>  

Applied 1/7 and 2/7 to my linux-next tree, thanks.

If it's easier to push them both through the kvm tree let me know; you
can just add my acked-by in that case.

-- 
Jesse Barnes, Intel Open Source Technology Center

  reply	other threads:[~2010-11-11 17:29 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-11-11  7:46 [PATCH 0/7 v4] MSI-X mask support for assigned device Sheng Yang
2010-11-11  7:46 ` [PATCH 1/7] PCI: MSI: Move MSI-X entry definition to pci_regs.h Sheng Yang
2010-11-11  7:46 ` [PATCH 2/7] PCI: Add mask bit definition for MSI-X table Sheng Yang
2010-11-11 17:29   ` Jesse Barnes [this message]
2010-11-15  8:02     ` Sheng Yang
2010-11-11  7:46 ` [PATCH 3/7] KVM: Move struct kvm_io_device to kvm_host.h Sheng Yang
2010-11-11  7:46 ` [PATCH 4/7] KVM: Add kvm_get_irq_routing_entry() func Sheng Yang
2010-11-11  7:46 ` [PATCH 5/7] KVM: assigned dev: Clean up assigned_device's flag Sheng Yang
2010-11-11  7:46 ` [PATCH 6/7] KVM: assigned dev: MSI-X mask support Sheng Yang
2010-11-12  9:53   ` Michael S. Tsirkin
2010-11-12 10:13     ` Sheng Yang
2010-11-12 10:47       ` Michael S. Tsirkin
2010-11-12 10:54         ` Sheng Yang
2010-11-12 11:25           ` Michael S. Tsirkin
2010-11-15  7:37             ` Sheng Yang
2010-11-15  7:42               ` Michael S. Tsirkin
2010-11-15  7:48                 ` Sheng Yang
2010-11-15  8:03                   ` Michael S. Tsirkin
2010-11-15  8:22                     ` Sheng Yang
2010-11-11  7:47 ` [PATCH 7/7] KVM: assigned dev: Big endian support for MSI-X MMIO Sheng Yang
2010-11-11 16:12   ` Michael S. Tsirkin
2010-11-12  2:47     ` Sheng Yang

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=20101111092929.7bed35aa@jbarnes-desktop \
    --to=jbarnes@virtuousgeek.org \
    --cc=avi@redhat.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=mst@redhat.com \
    --cc=mtosatti@redhat.com \
    --cc=sheng@linux.intel.com \
    --cc=willy@linux.intel.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.