From: Sebastian Andrzej Siewior <sebastian@breakpoint.cc>
To: Alexander Gordeev <agordeev@redhat.com>
Cc: linux-kernel@vger.kernel.org, x86@kernel.org,
linux-pci@vger.kernel.org,
Suresh Siddha <suresh.b.siddha@intel.com>,
Yinghai Lu <yinghai@kernel.org>, Joerg Roedel <joro@8bytes.org>,
Jan Beulich <JBeulich@suse.com>, Ingo Molnar <mingo@redhat.com>,
Bjorn Helgaas <bhelgaas@google.com>
Subject: Re: [PATCH v3 -tip x86/apic 2/2] x86/MSI: Conserve interrupt resources when using multiple-MSIs
Date: Wed, 5 Jun 2013 22:08:07 +0200 [thread overview]
Message-ID: <20130605200807.GA5198@breakpoint.cc> (raw)
In-Reply-To: <924d05fe41fb93fdc2013680fb220d4b171de303.1368431413.git.agordeev@redhat.com>
On Mon, May 13, 2013 at 11:06:17AM +0200, Alexander Gordeev wrote:
> Current multiple-MSI implementation does not take into account
> actual number of requested MSIs and always rounds that number
> to a closest power-of-two value. Yet, a number of MSIs a PCI
> device could send (and therefore a number of messages a device
> driver could request) may be a lesser power-of-two. As result,
> resources allocated for extra MSIs just wasted.
>
> This update takes advantage of 'msi_desc::nvec' field introduced
> with generic MSI code to track number of requested and used MSIs.
> As result, resources associated with interrupts are conserved.
> Of those resources most noticeable are x86 interrupt vectors.
>
> The initial version of this fix also consumed on IRTEs, but Jan
> noticed that a malfunctioning PCI device might send a message
> number it did not claim and thus refer an IRTE it does not own.
> To avoid this security hole the old-way approach preserved and
> as many IRTEs are reserved as the device could possibly send.
>
> Signed-off-by: Alexander Gordeev <agordeev@redhat.com>
This does not look all that bad.
Sebastian
prev parent reply other threads:[~2013-06-05 20:09 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-05-13 9:05 [PATCH v3 -tip x86/apic 0/2] PCI/MSI: Allocate as many multiple-MSIs as requested Alexander Gordeev
2013-05-13 9:05 ` [PATCH v3 -tip x86/apic 1/2] " Alexander Gordeev
2013-05-28 9:50 ` Ingo Molnar
2013-06-05 20:56 ` Sebastian Andrzej Siewior
2013-06-05 21:09 ` Bjorn Helgaas
2013-06-05 21:28 ` Sebastian Andrzej Siewior
2013-06-06 8:30 ` Alexander Gordeev
2013-06-06 19:51 ` Sebastian Andrzej Siewior
2013-05-13 9:06 ` [PATCH v3 -tip x86/apic 2/2] x86/MSI: Conserve interrupt resources when using multiple-MSIs Alexander Gordeev
2013-06-05 20:08 ` Sebastian Andrzej Siewior [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=20130605200807.GA5198@breakpoint.cc \
--to=sebastian@breakpoint.cc \
--cc=JBeulich@suse.com \
--cc=agordeev@redhat.com \
--cc=bhelgaas@google.com \
--cc=joro@8bytes.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=suresh.b.siddha@intel.com \
--cc=x86@kernel.org \
--cc=yinghai@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 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.