linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Kalle Valo <kvalo@codeaurora.org>
To: Thomas Gleixner <tglx@linutronix.de>
Cc: Bjorn Helgaas <helgaas@kernel.org>,
	Govind Singh <govinds@codeaurora.org>,
	linux-pci@vger.kernel.org, linux-wireless@vger.kernel.org,
	Devin Bayer <dev@doubly.so>, Christoph Hellwig <hch@lst.de>,
	Thomas Krause <thomaskrause@posteo.de>,
	ath11k@lists.infradead.org, Stefani Seibold <stefani@seibold.net>
Subject: Re: pci_alloc_irq_vectors fails ENOSPC for XPS 13 9310
Date: Mon, 09 Nov 2020 20:44:22 +0200	[thread overview]
Message-ID: <871rh2fjzt.fsf@codeaurora.org> (raw)
In-Reply-To: <87wnz2ysd4.fsf@nanos.tec.linutronix.de> (Thomas Gleixner's message of "Tue, 03 Nov 2020 23:42:47 +0100")

Thomas Gleixner <tglx@linutronix.de> writes:

> On Tue, Nov 03 2020 at 22:08, Thomas Gleixner wrote:
>> On Tue, Nov 03 2020 at 10:08, Bjorn Helgaas wrote:
>>>> > But it seems a little greedy if the device can't operate at all unless
>>>> > it gets 32 vectors.  Are you sure that's a hard requirement?  Most
>>>> > devices can work with fewer vectors, even if it reduces performance.
>>
>> Right, even most high end network cards work with one interrupt.
>>
>>>> This was my first reaction as well when I saw the code for the first
>>>> time. And the reply I got is that the firmware needs all 32 vectors, it
>>>> won't work with less.
>>
>> Great design.
>
> Just to put more information to this:
>
> Enforcing 32 vectors with MSI is beyond silly. Due to the limitations of
> MSI all of these vectors will be affine to a single CPU unless irq
> remapping is available and enabled.
>
> So if irq remapping is not enabled, then what are the 32 vectors buying?
> Exactly nothing because they just compete to be handled on the very same
> CPU. If the design requires more than one vector, then this should be
> done with MSI-X (which allows individual affinities and individual
> masking).
>
> That's known for 20 years and MSI-X exists for exactly that reason. But
> hardware people still insist on implementing MSI (probably because it
> saves 0.002$ per chip).
>
> But there is also the firmware side. Enforcing the availability of 32
> vectors on MSI is silly to begin with as explained above, but it's also
> silly given the constraints of the x86 vector space. It takes just 6
> devices having the same 32 vector requirement to exhaust it. Oh well...

Thanks Thomas, this is great info. I'm pushing this internally and we
try to get ath11k working with just one MSI vector.

-- 
https://patchwork.kernel.org/project/linux-wireless/list/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches

  reply	other threads:[~2020-11-09 18:44 UTC|newest]

Thread overview: 40+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <2849fd39-a7a6-8366-7c78-fc9fec4dffa4@posteo.de>
     [not found] ` <87tuuqhc1i.fsf@codeaurora.org>
     [not found]   ` <1ce6f735-21ff-db7e-c8dc-d567761964aa@posteo.de>
2020-11-02 18:49     ` pci_alloc_irq_vectors fails ENOSPC for XPS 13 9310 Kalle Valo
2020-11-02 20:57       ` Bjorn Helgaas
2020-11-03  3:01         ` Carl Huang
2020-11-03  6:49         ` Kalle Valo
2020-11-03 16:08           ` Bjorn Helgaas
2020-11-03 21:08             ` Thomas Gleixner
2020-11-03 22:42               ` Thomas Gleixner
2020-11-09 18:44                 ` Kalle Valo [this message]
     [not found]               ` <fa26ac8b-ed48-7ea3-c21b-b133532716b8@posteo.de>
2020-11-04 15:26                 ` Thomas Gleixner
2020-11-05 13:23                   ` Kalle Valo
2020-11-10  8:33                     ` Kalle Valo
2020-11-11  8:53                       ` Thomas Krause
2020-11-11  9:22                         ` Kalle Valo
2020-11-11 19:10                           ` Kalle Valo
2020-11-11 19:24                             ` wi nk
2020-11-11 19:30                               ` wi nk
2020-11-11 19:45                                 ` Kalle Valo
2020-11-11 20:12                                   ` wi nk
2020-11-11 21:35                             ` Stefani Seibold
2020-11-11 22:02                             ` Stefani Seibold
2020-11-12  0:24                               ` wi nk
2020-11-12  1:10                                 ` wi nk
2020-11-12  1:11                                   ` wi nk
2020-11-12  2:31                                     ` wi nk
2020-11-12  6:29                                       ` Carl Huang
2020-11-12  7:05                                   ` Stefani Seibold
2020-11-12  7:15                                     ` Kalle Valo
2020-11-12  7:41                                       ` wi nk
2020-11-12  8:59                                         ` Kalle Valo
2020-11-12 15:44                                           ` wi nk
2020-11-13  9:52                                             ` wi nk
2020-11-15 13:30                                             ` Thomas Krause
2020-11-15 19:55                                               ` wi nk
2020-11-17 15:49                                                 ` wi nk
2020-11-17 20:59                                                   ` Thomas Gleixner
2020-11-18 10:22                                                     ` wi nk
2020-11-11  9:39                         ` Thomas Gleixner
2020-11-06 11:45               ` Devin Bayer
2020-11-09 18:48             ` Kalle Valo
2020-11-03 11:20         ` Devin Bayer

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=871rh2fjzt.fsf@codeaurora.org \
    --to=kvalo@codeaurora.org \
    --cc=ath11k@lists.infradead.org \
    --cc=dev@doubly.so \
    --cc=govinds@codeaurora.org \
    --cc=hch@lst.de \
    --cc=helgaas@kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=stefani@seibold.net \
    --cc=tglx@linutronix.de \
    --cc=thomaskrause@posteo.de \
    /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;
as well as URLs for NNTP newsgroup(s).