From: Ben Hutchings <ben@decadent.org.uk>
To: Alexander Gordeev <agordeev@redhat.com>
Cc: linux-kernel@vger.kernel.org,
Himanshu Madhani <himanshu.madhani@qlogic.com>,
Rajesh Borundia <rajesh.borundia@qlogic.com>,
Shahed Shaikh <shahed.shaikh@qlogic.com>,
linux-driver@qlogic.com, netdev@vger.kernel.org,
linux-pci@vger.kernel.org
Subject: Re: [PATCH net-next 28/35] qlcnic: Use pci_enable_msix_range() instead of pci_enable_msix()
Date: Sat, 22 Feb 2014 00:48:47 +0000 [thread overview]
Message-ID: <1393030127.15717.72.camel@deadeye.wl.decadent.org.uk> (raw)
In-Reply-To: <1393029870.15717.71.camel@deadeye.wl.decadent.org.uk>
[-- Attachment #1: Type: text/plain, Size: 1650 bytes --]
On Sat, 2014-02-22 at 00:44 +0000, Ben Hutchings wrote:
> On Tue, 2014-02-18 at 11:11 +0100, Alexander Gordeev wrote:
> > As result of deprecation of MSI-X/MSI enablement functions
> > pci_enable_msix() and pci_enable_msi_block() all drivers
> > using these two interfaces need to be updated to use the
> > new pci_enable_msi_range() and pci_enable_msix_range()
> > interfaces.
[...]
> > --- a/drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c
> > +++ b/drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c
> > @@ -701,13 +701,17 @@ enable_msix:
> > for (vector = 0; vector < num_msix; vector++)
> > adapter->msix_entries[vector].entry = vector;
> >
> > - err = pci_enable_msix(pdev, adapter->msix_entries, num_msix);
> > - if (err == 0) {
> > + err = pci_enable_msix_range(pdev,
> > + adapter->msix_entries, 1, num_msix);
> > +
> > + if (err == num_msix) {
> > adapter->flags |= QLCNIC_MSIX_ENABLED;
> > adapter->ahw->num_msix = num_msix;
> > dev_info(&pdev->dev, "using msi-x interrupts\n");
> > return 0;
> > } else if (err > 0) {
> > + pci_disable_msix(pdev);
> > +
> > dev_info(&pdev->dev,
> > "Unable to allocate %d MSI-X vectors, Available vectors %d\n",
> > num_msix, err);
>
> Well this log message is nonsense - we have no idea how many vectors are
> available any more.
>
> You should remove this and the retry loop that is no longer needed.
Sorry, I'm confused and this does work. But I wonder whether it is
really an improvement over using the old API.
Ben.
--
Ben Hutchings
I haven't lost my mind; it's backed up on tape somewhere.
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 811 bytes --]
next prev parent reply other threads:[~2014-02-22 0:48 UTC|newest]
Thread overview: 50+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-18 10:07 [PATCH net-next 00/35] net: " Alexander Gordeev
2014-02-18 10:07 ` [PATCH net-next 01/35] bnx2: " Alexander Gordeev
2014-02-22 0:34 ` Ben Hutchings
2014-02-22 10:17 ` Alexander Gordeev
2014-02-18 10:07 ` [PATCH net-next 02/35] bnx2x: " Alexander Gordeev
2014-02-18 10:07 ` [PATCH net-next 03/35] tg3: " Alexander Gordeev
2014-02-18 10:07 ` [PATCH net-next 04/35] bna: " Alexander Gordeev
2014-02-18 10:07 ` [PATCH net-next 05/35] cxgb3: Remove superfluous call to pci_disable_msix() Alexander Gordeev
2014-02-18 10:07 ` [PATCH net-next 06/35] cxgb3: Use pci_enable_msix_range() instead of pci_enable_msix() Alexander Gordeev
2014-02-18 10:07 ` [PATCH net-next 07/35] cxgb4: " Alexander Gordeev
2014-02-18 10:08 ` [PATCH net-next 08/35] cxgb4vf: Remove superfluous call to pci_disable_msix() Alexander Gordeev
2014-02-18 10:08 ` [PATCH net-next 09/35] cxgb4vf: Use pci_enable_msix_range() instead of pci_enable_msix() Alexander Gordeev
2014-02-18 10:08 ` [PATCH net-next 10/35] enic: " Alexander Gordeev
2014-02-18 10:18 ` Govindarajulu Varadarajan
2014-02-18 10:11 ` [PATCH net-next 11/35] benet: " Alexander Gordeev
2014-02-18 10:11 ` [PATCH net-next 12/35] e1000e: " Alexander Gordeev
2014-02-18 10:11 ` [PATCH net-next 13/35] i40e: " Alexander Gordeev
2014-02-18 10:11 ` [PATCH net-next 14/35] igb: " Alexander Gordeev
2014-02-18 10:11 ` [PATCH net-next 15/35] igbvf: " Alexander Gordeev
2014-02-18 10:11 ` [PATCH net-next 16/35] ixgbe: " Alexander Gordeev
2014-02-18 10:11 ` [PATCH net-next 17/35] ixgbevf: " Alexander Gordeev
2014-02-18 12:01 ` Amir Vadai
2014-02-18 12:14 ` Amir Vadai
2014-02-18 20:56 ` David Miller
2014-02-18 10:11 ` [PATCH net-next 18/35] mlx4: " Alexander Gordeev
2014-02-18 10:11 ` [PATCH net-next 19/35] mlx5: " Alexander Gordeev
2014-02-18 10:11 ` [PATCH net-next 20/35] myri10ge: " Alexander Gordeev
2014-02-19 15:14 ` Sergei Shtylyov
2014-02-18 10:11 ` [PATCH net-next 21/35] s2io: " Alexander Gordeev
2014-02-18 10:11 ` [PATCH net-next 22/35] vxge: " Alexander Gordeev
2014-02-18 10:11 ` [PATCH net-next 23/35] forcedeth: Fix invalid errno reporting in nv_request_irq() Alexander Gordeev
2014-02-18 10:11 ` [PATCH net-next 24/35] forcedeth: Cleanup MSI-X to MSI to INTx fallback code Alexander Gordeev
2014-02-18 10:11 ` [PATCH net-next 25/35] forcedeth: Use pci_enable_msix_range() instead of pci_enable_msix() Alexander Gordeev
2014-02-18 10:11 ` [PATCH net-next 26/35] netxen: " Alexander Gordeev
2014-02-18 10:11 ` [PATCH net-next 27/35] qlcnic: Cleanup qlcnic_enable_msix() return values Alexander Gordeev
2014-02-18 10:11 ` [PATCH net-next 28/35] qlcnic: Use pci_enable_msix_range() instead of pci_enable_msix() Alexander Gordeev
2014-02-22 0:44 ` Ben Hutchings
2014-02-22 0:48 ` Ben Hutchings [this message]
2014-02-22 9:24 ` Alexander Gordeev
2014-02-22 16:18 ` Shahed Shaikh
2014-02-18 10:11 ` [PATCH net-next 29/35] qlge: Get rid of an redundant assignment Alexander Gordeev
2014-02-18 19:19 ` Jitendra Kalsaria
2014-02-18 10:11 ` [PATCH net-next 30/35] qlge: Use pci_enable_msix_range() instead of pci_enable_msix() Alexander Gordeev
2014-02-18 19:20 ` Jitendra Kalsaria
2014-02-18 10:12 ` [PATCH net-next 31/35] sfc: " Alexander Gordeev
2014-02-18 10:12 ` [PATCH net-next 32/35] niu: " Alexander Gordeev
2014-02-18 10:12 ` [PATCH net-next 33/35] vmxnet3: Fix MSI-X/MSI enablement code Alexander Gordeev
2014-02-18 10:12 ` [PATCH net-next 34/35] vmxnet3: Use pci_enable_msix_range() instead of pci_enable_msix() Alexander Gordeev
2014-02-18 10:12 ` [PATCH net-next 35/35] wil6210: Use pci_enable_msi_range() instead of pci_enable_msi_block() Alexander Gordeev
2014-02-18 20:34 ` [PATCH net-next 00/35] net: Use pci_enable_msix_range() instead of pci_enable_msix() David Miller
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=1393030127.15717.72.camel@deadeye.wl.decadent.org.uk \
--to=ben@decadent.org.uk \
--cc=agordeev@redhat.com \
--cc=himanshu.madhani@qlogic.com \
--cc=linux-driver@qlogic.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=rajesh.borundia@qlogic.com \
--cc=shahed.shaikh@qlogic.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®