All of lore.kernel.org
 help / color / mirror / Atom feed
From: Matthew Wilcox <matthew@wil.cx>
To: Hidetoshi Seto <seto.hidetoshi@jp.fujitsu.com>
Cc: Jesse Barnes <jbarnes@virtuousgeek.org>,
	"David S. Miller" <davem@davemloft.net>,
	linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] PCI MSI: Yet another fix for MSI-X with NIU cards, v2
Date: Wed, 13 May 2009 12:43:49 -0600	[thread overview]
Message-ID: <20090513184349.GJ15360@parisc-linux.org> (raw)
In-Reply-To: <4A0A5556.9050209@jp.fujitsu.com>

On Wed, May 13, 2009 at 02:06:30PM +0900, Hidetoshi Seto wrote:
>  		entry->mask_base = base;
> -		entry->masked = readl(base + j * PCI_MSIX_ENTRY_SIZE +
> -					PCI_MSIX_ENTRY_VECTOR_CTRL_OFFSET);
> -		msix_mask_irq(entry, 1);
> +		entry->masked = 1;
>  

Why do you add the setting of entry->masked here?

>  
> +	/*
> +	 * The states of Reserved bits[31:01] of Vector Control for MSI-X
> +	 * Table Entries must be 0.  However, for potential future use,
> +	 * software must preserve the value of these reserved bits.
> +	 * Refer PCI spec 3.0, 6.8.2.9.
> +	 *
> +	 * Note that there are some device that refuses access to MSI-X
> +	 * Table Entries before MSI-X is enabled.  Therefore we do it here. 
> +	 */

I think you need to refer to PCIe 2.1 (or an ECN incorporated into it).
Some of these bits are now used.

> +	list_for_each_entry(entry, &dev->msi_list, list) {
> +		int vector = entry->msi_attrib.entry_nr;
> +		entry->masked = readl(base + vector * PCI_MSIX_ENTRY_SIZE +
> +					PCI_MSIX_ENTRY_VECTOR_CTRL_OFFSET);
> +		/* Make sure it is masked */
> +		msix_mask_irq(entry, 1);
> +	}
> +
>  	return 0;

This looks to be the same as the replacement patch I sent earlier.

-- 
Matthew Wilcox				Intel Open Source Technology Centre
"Bill, look, we understand that you're interested in selling us this
operating system, but compare it to ours.  We can't possibly take such
a retrograde step."

  parent reply	other threads:[~2009-05-13 18:44 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-05-08 13:13 [PATCH] Fix MSI-X with NIU cards Matthew Wilcox
2009-05-11  1:21 ` Michael Ellerman
2009-05-11  5:36   ` David Miller
2009-05-11 14:30     ` Michael Ellerman
2009-05-11 23:40       ` David Miller
2009-05-11 23:59         ` Jesse Barnes
2009-05-12  2:21         ` Michael Ellerman
2009-05-13 10:07           ` Matthew Wilcox
2009-05-13  4:06   ` Hidetoshi Seto
2009-05-13  4:40     ` Hidetoshi Seto
2009-05-13  4:49       ` Michael Ellerman
2009-05-13  4:10 ` [PATCH] PCI MSI: Yet another fix for " Hidetoshi Seto
2009-05-13  5:13   ` David Miller
2009-05-13  4:54 ` [PATCH] PCI MSI: Yet another fix for MSI-X with NIU cards, v2 Hidetoshi Seto
2009-05-13  5:06   ` Hidetoshi Seto
2009-05-13  6:31     ` Michael Ellerman
2009-05-13 18:43     ` Matthew Wilcox [this message]
2009-05-14  6:22       ` Hidetoshi Seto

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=20090513184349.GJ15360@parisc-linux.org \
    --to=matthew@wil.cx \
    --cc=davem@davemloft.net \
    --cc=jbarnes@virtuousgeek.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=seto.hidetoshi@jp.fujitsu.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.