* [PATCH] kvm: Use pci_enable_msix_range() instead of pci_enable_msix()
@ 2014-02-19 10:15 Alexander Gordeev
2014-02-19 13:24 ` Paolo Bonzini
0 siblings, 1 reply; 12+ messages in thread
From: Alexander Gordeev @ 2014-02-19 10:15 UTC (permalink / raw)
To: linux-kernel
Cc: Alexander Gordeev, Gleb Natapov, Paolo Bonzini, kvm, linux-pci
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.
Signed-off-by: Alexander Gordeev <agordeev@redhat.com>
Cc: Gleb Natapov <gleb@kernel.org>
Cc: Paolo Bonzini <pbonzini@redhat.com>
Cc: kvm@vger.kernel.org
Cc: linux-pci@vger.kernel.org
---
virt/kvm/assigned-dev.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/virt/kvm/assigned-dev.c b/virt/kvm/assigned-dev.c
index 8db4370..92e25e9 100644
--- a/virt/kvm/assigned-dev.c
+++ b/virt/kvm/assigned-dev.c
@@ -395,8 +395,9 @@ static int assigned_device_enable_host_msix(struct kvm *kvm,
if (dev->entries_nr == 0)
return r;
- r = pci_enable_msix(dev->dev, dev->host_msix_entries, dev->entries_nr);
- if (r)
+ r = pci_enable_msix_range(dev->dev, dev->host_msix_entries,
+ dev->entries_nr, dev->entries_nr);
+ if (r < 0)
return r;
for (i = 0; i < dev->entries_nr; i++) {
--
1.7.7.6
^ permalink raw reply related [flat|nested] 12+ messages in thread
* Re: [PATCH] kvm: Use pci_enable_msix_range() instead of pci_enable_msix()
2014-02-19 10:15 [PATCH] kvm: Use pci_enable_msix_range() instead of pci_enable_msix() Alexander Gordeev
@ 2014-02-19 13:24 ` Paolo Bonzini
2014-02-21 17:04 ` Alexander Gordeev
0 siblings, 1 reply; 12+ messages in thread
From: Paolo Bonzini @ 2014-02-19 13:24 UTC (permalink / raw)
To: Alexander Gordeev, linux-kernel; +Cc: Gleb Natapov, kvm, linux-pci
Il 19/02/2014 11:15, Alexander Gordeev ha scritto:
> 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.
>
> Signed-off-by: Alexander Gordeev <agordeev@redhat.com>
> Cc: Gleb Natapov <gleb@kernel.org>
> Cc: Paolo Bonzini <pbonzini@redhat.com>
> Cc: kvm@vger.kernel.org
> Cc: linux-pci@vger.kernel.org
> ---
> virt/kvm/assigned-dev.c | 5 +++--
> 1 files changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/virt/kvm/assigned-dev.c b/virt/kvm/assigned-dev.c
> index 8db4370..92e25e9 100644
> --- a/virt/kvm/assigned-dev.c
> +++ b/virt/kvm/assigned-dev.c
> @@ -395,8 +395,9 @@ static int assigned_device_enable_host_msix(struct kvm *kvm,
> if (dev->entries_nr == 0)
> return r;
>
> - r = pci_enable_msix(dev->dev, dev->host_msix_entries, dev->entries_nr);
> - if (r)
> + r = pci_enable_msix_range(dev->dev, dev->host_msix_entries,
> + dev->entries_nr, dev->entries_nr);
> + if (r < 0)
> return r;
>
> for (i = 0; i < dev->entries_nr; i++) {
>
Acked-by: Paolo Bonzini <pbonzini@redhat.com>
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH] kvm: Use pci_enable_msix_range() instead of pci_enable_msix()
2014-02-19 13:24 ` Paolo Bonzini
@ 2014-02-21 17:04 ` Alexander Gordeev
2014-02-21 17:05 ` [PATCH v2] kvm: Use pci_enable_msix_exact() " Alexander Gordeev
0 siblings, 1 reply; 12+ messages in thread
From: Alexander Gordeev @ 2014-02-21 17:04 UTC (permalink / raw)
To: Paolo Bonzini; +Cc: linux-kernel, Gleb Natapov, kvm, linux-pci
Hi Paolo et al,
Based on recently accepted to the mainline pci_enable_msix_exact() function,
I am sending a updated version of the patch. Please, let me know if it does
not work for you and you need and incremental update from the previous version.
Thanks!
--
Regards,
Alexander Gordeev
agordeev@redhat.com
^ permalink raw reply [flat|nested] 12+ messages in thread
* [PATCH v2] kvm: Use pci_enable_msix_exact() instead of pci_enable_msix()
2014-02-21 17:04 ` Alexander Gordeev
@ 2014-02-21 17:05 ` Alexander Gordeev
2014-02-21 17:11 ` Paolo Bonzini
2014-04-28 9:13 ` Paolo Bonzini
0 siblings, 2 replies; 12+ messages in thread
From: Alexander Gordeev @ 2014-02-21 17:05 UTC (permalink / raw)
To: Paolo Bonzini; +Cc: linux-kernel, Gleb Natapov, kvm, linux-pci
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() or pci_enable_msi_exact()
and pci_enable_msix_range() or pci_enable_msix_exact()
interfaces.
Signed-off-by: Alexander Gordeev <agordeev@redhat.com>
Cc: Gleb Natapov <gleb@kernel.org>
Cc: Paolo Bonzini <pbonzini@redhat.com>
Cc: kvm@vger.kernel.org
Cc: linux-pci@vger.kernel.org
---
virt/kvm/assigned-dev.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/virt/kvm/assigned-dev.c b/virt/kvm/assigned-dev.c
index 8db4370..bf06577 100644
--- a/virt/kvm/assigned-dev.c
+++ b/virt/kvm/assigned-dev.c
@@ -395,7 +395,8 @@ static int assigned_device_enable_host_msix(struct kvm *kvm,
if (dev->entries_nr == 0)
return r;
- r = pci_enable_msix(dev->dev, dev->host_msix_entries, dev->entries_nr);
+ r = pci_enable_msix_exact(dev->dev,
+ dev->host_msix_entries, dev->entries_nr);
if (r)
return r;
--
1.7.7.6
--
Regards,
Alexander Gordeev
agordeev@redhat.com
^ permalink raw reply related [flat|nested] 12+ messages in thread
* Re: [PATCH v2] kvm: Use pci_enable_msix_exact() instead of pci_enable_msix()
2014-02-21 17:05 ` [PATCH v2] kvm: Use pci_enable_msix_exact() " Alexander Gordeev
@ 2014-02-21 17:11 ` Paolo Bonzini
2014-02-21 18:56 ` Alexander Gordeev
2014-04-28 9:13 ` Paolo Bonzini
1 sibling, 1 reply; 12+ messages in thread
From: Paolo Bonzini @ 2014-02-21 17:11 UTC (permalink / raw)
To: Alexander Gordeev; +Cc: linux-kernel, Gleb Natapov, kvm, linux-pci
Il 21/02/2014 18:05, Alexander Gordeev ha scritto:
> 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() or pci_enable_msi_exact()
> and pci_enable_msix_range() or pci_enable_msix_exact()
> interfaces.
>
> Signed-off-by: Alexander Gordeev <agordeev@redhat.com>
> Cc: Gleb Natapov <gleb@kernel.org>
> Cc: Paolo Bonzini <pbonzini@redhat.com>
> Cc: kvm@vger.kernel.org
> Cc: linux-pci@vger.kernel.org
> ---
> virt/kvm/assigned-dev.c | 3 ++-
> 1 files changed, 2 insertions(+), 1 deletions(-)
>
> diff --git a/virt/kvm/assigned-dev.c b/virt/kvm/assigned-dev.c
> index 8db4370..bf06577 100644
> --- a/virt/kvm/assigned-dev.c
> +++ b/virt/kvm/assigned-dev.c
> @@ -395,7 +395,8 @@ static int assigned_device_enable_host_msix(struct kvm *kvm,
> if (dev->entries_nr == 0)
> return r;
>
> - r = pci_enable_msix(dev->dev, dev->host_msix_entries, dev->entries_nr);
> + r = pci_enable_msix_exact(dev->dev,
> + dev->host_msix_entries, dev->entries_nr);
> if (r)
> return r;
>
>
It's okay, but it's not clear to me whether I should include this patch
or someone else will. :)
Paolo
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH v2] kvm: Use pci_enable_msix_exact() instead of pci_enable_msix()
2014-02-21 17:11 ` Paolo Bonzini
@ 2014-02-21 18:56 ` Alexander Gordeev
2014-02-21 21:36 ` Paolo Bonzini
0 siblings, 1 reply; 12+ messages in thread
From: Alexander Gordeev @ 2014-02-21 18:56 UTC (permalink / raw)
To: Paolo Bonzini; +Cc: linux-kernel, Gleb Natapov, kvm, linux-pci
On Fri, Feb 21, 2014 at 06:11:29PM +0100, Paolo Bonzini wrote:
> It's okay, but it's not clear to me whether I should include this
> patch or someone else will. :)
Please, include it.
Thanks!
> Paolo
--
Regards,
Alexander Gordeev
agordeev@redhat.com
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH v2] kvm: Use pci_enable_msix_exact() instead of pci_enable_msix()
2014-02-21 18:56 ` Alexander Gordeev
@ 2014-02-21 21:36 ` Paolo Bonzini
2014-02-22 8:50 ` Alexander Gordeev
0 siblings, 1 reply; 12+ messages in thread
From: Paolo Bonzini @ 2014-02-21 21:36 UTC (permalink / raw)
To: Alexander Gordeev; +Cc: linux-kernel, Gleb Natapov, kvm, linux-pci
Il 21/02/2014 19:56, Alexander Gordeev ha scritto:
> On Fri, Feb 21, 2014 at 06:11:29PM +0100, Paolo Bonzini wrote:
>> It's okay, but it's not clear to me whether I should include this
>> patch or someone else will. :)
>
> Please, include it.
And where do I get pci_enable_msix_exact? When will pci_enable_msix
disappear?
So, do I have to pull something (which I'd rather not, since pulling the
wrong thing in a submaintainer tree will make Linus angry), or should I
do it in the next merge window after pci_enable_msix_exact gets in?
All in all, it seems much simpler to me if the linux-pci tree just
includes the whole patch series with my Acked-by.
Paolo
> Thanks!
>
>> Paolo
>
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH v2] kvm: Use pci_enable_msix_exact() instead of pci_enable_msix()
2014-02-21 21:36 ` Paolo Bonzini
@ 2014-02-22 8:50 ` Alexander Gordeev
2014-02-22 8:58 ` Paolo Bonzini
0 siblings, 1 reply; 12+ messages in thread
From: Alexander Gordeev @ 2014-02-22 8:50 UTC (permalink / raw)
To: Paolo Bonzini; +Cc: linux-kernel, Gleb Natapov, kvm, linux-pci
On Fri, Feb 21, 2014 at 10:36:25PM +0100, Paolo Bonzini wrote:
> Il 21/02/2014 19:56, Alexander Gordeev ha scritto:
> >On Fri, Feb 21, 2014 at 06:11:29PM +0100, Paolo Bonzini wrote:
> >>It's okay, but it's not clear to me whether I should include this
> >>patch or someone else will. :)
> >
> >Please, include it.
>
> And where do I get pci_enable_msix_exact? When will pci_enable_msix
> disappear?
Commit d158fc7 ("Merge tag 'pci-v3.14-fixes-1'") in Linus's tree has it.
pci_enable_msix() is going to be removed once all drivers updated with
new interface.
> So, do I have to pull something (which I'd rather not, since pulling
> the wrong thing in a submaintainer tree will make Linus angry), or
> should I do it in the next merge window after pci_enable_msix_exact
> gets in?
So it is already in.
> All in all, it seems much simpler to me if the linux-pci tree just
> includes the whole patch series with my Acked-by.
>
> Paolo
>
> >Thanks!
> >
> >>Paolo
> >
>
--
Regards,
Alexander Gordeev
agordeev@redhat.com
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH v2] kvm: Use pci_enable_msix_exact() instead of pci_enable_msix()
2014-02-22 8:50 ` Alexander Gordeev
@ 2014-02-22 8:58 ` Paolo Bonzini
2014-04-21 13:38 ` Alexander Gordeev
0 siblings, 1 reply; 12+ messages in thread
From: Paolo Bonzini @ 2014-02-22 8:58 UTC (permalink / raw)
To: Alexander Gordeev; +Cc: linux-kernel, Gleb Natapov, kvm, linux-pci
Il 22/02/2014 09:50, Alexander Gordeev ha scritto:
> Commit d158fc7 ("Merge tag 'pci-v3.14-fixes-1'") in Linus's tree has it.
>
> pci_enable_msix() is going to be removed once all drivers updated with
> new interface.
>
>> > So, do I have to pull something (which I'd rather not, since pulling
>> > the wrong thing in a submaintainer tree will make Linus angry), or
>> > should I do it in the next merge window after pci_enable_msix_exact
>> > gets in?
> So it is already in.
It is not, because maintainer branches are not rebased. KVM development
is based on 3.14-rc1, and will not get that commit until the first 3.15
pull request is sent to Linux.
No big deal, I'll include this patch in a second 3.15 pull request.
Paolo
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH v2] kvm: Use pci_enable_msix_exact() instead of pci_enable_msix()
2014-02-22 8:58 ` Paolo Bonzini
@ 2014-04-21 13:38 ` Alexander Gordeev
2014-04-24 20:45 ` Paolo Bonzini
0 siblings, 1 reply; 12+ messages in thread
From: Alexander Gordeev @ 2014-04-21 13:38 UTC (permalink / raw)
To: Paolo Bonzini; +Cc: linux-kernel, Gleb Natapov, kvm, linux-pci
On Sat, Feb 22, 2014 at 09:58:10AM +0100, Paolo Bonzini wrote:
> Il 22/02/2014 09:50, Alexander Gordeev ha scritto:
> >Commit d158fc7 ("Merge tag 'pci-v3.14-fixes-1'") in Linus's tree has it.
> >
> >pci_enable_msix() is going to be removed once all drivers updated with
> >new interface.
> >
> >>> So, do I have to pull something (which I'd rather not, since pulling
> >>> the wrong thing in a submaintainer tree will make Linus angry), or
> >>> should I do it in the next merge window after pci_enable_msix_exact
> >>> gets in?
> >So it is already in.
>
> It is not, because maintainer branches are not rebased. KVM
> development is based on 3.14-rc1, and will not get that commit until
> the first 3.15 pull request is sent to Linux.
>
> No big deal, I'll include this patch in a second 3.15 pull request.
Hi Paolo,
I believe it is safe to pull it now?
Thanks!
> Paolo
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH v2] kvm: Use pci_enable_msix_exact() instead of pci_enable_msix()
2014-04-21 13:38 ` Alexander Gordeev
@ 2014-04-24 20:45 ` Paolo Bonzini
0 siblings, 0 replies; 12+ messages in thread
From: Paolo Bonzini @ 2014-04-24 20:45 UTC (permalink / raw)
To: Alexander Gordeev; +Cc: linux-kernel, Gleb Natapov, kvm, linux-pci
> > >>> So, do I have to pull something (which I'd rather not, since pulling
> > >>> the wrong thing in a submaintainer tree will make Linus angry), or
> > >>> should I do it in the next merge window after pci_enable_msix_exact
> > >>> gets in?
> > >So it is already in.
> >
> > It is not, because maintainer branches are not rebased. KVM
> > development is based on 3.14-rc1, and will not get that commit until
> > the first 3.15 pull request is sent to Linux.
> >
> > No big deal, I'll include this patch in a second 3.15 pull request.
>
> Hi Paolo,
>
> I believe it is safe to pull it now?
Yup, vacation got in the way of doing this during the merge window but I
can safely send this for -rc next week. It was on my todo list.
Paolo
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH v2] kvm: Use pci_enable_msix_exact() instead of pci_enable_msix()
2014-02-21 17:05 ` [PATCH v2] kvm: Use pci_enable_msix_exact() " Alexander Gordeev
2014-02-21 17:11 ` Paolo Bonzini
@ 2014-04-28 9:13 ` Paolo Bonzini
1 sibling, 0 replies; 12+ messages in thread
From: Paolo Bonzini @ 2014-04-28 9:13 UTC (permalink / raw)
To: Alexander Gordeev; +Cc: linux-kernel, Gleb Natapov, kvm, linux-pci
Il 21/02/2014 18:05, Alexander Gordeev ha scritto:
> 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() or pci_enable_msi_exact()
> and pci_enable_msix_range() or pci_enable_msix_exact()
> interfaces.
>
> Signed-off-by: Alexander Gordeev <agordeev@redhat.com>
> Cc: Gleb Natapov <gleb@kernel.org>
> Cc: Paolo Bonzini <pbonzini@redhat.com>
> Cc: kvm@vger.kernel.org
> Cc: linux-pci@vger.kernel.org
> ---
> virt/kvm/assigned-dev.c | 3 ++-
> 1 files changed, 2 insertions(+), 1 deletions(-)
>
> diff --git a/virt/kvm/assigned-dev.c b/virt/kvm/assigned-dev.c
> index 8db4370..bf06577 100644
> --- a/virt/kvm/assigned-dev.c
> +++ b/virt/kvm/assigned-dev.c
> @@ -395,7 +395,8 @@ static int assigned_device_enable_host_msix(struct kvm *kvm,
> if (dev->entries_nr == 0)
> return r;
>
> - r = pci_enable_msix(dev->dev, dev->host_msix_entries, dev->entries_nr);
> + r = pci_enable_msix_exact(dev->dev,
> + dev->host_msix_entries, dev->entries_nr);
> if (r)
> return r;
>
>
Applying this to kvm/master (i.e. for 3.15), thanks.
Paolo
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2014-04-28 9:13 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-02-19 10:15 [PATCH] kvm: Use pci_enable_msix_range() instead of pci_enable_msix() Alexander Gordeev
2014-02-19 13:24 ` Paolo Bonzini
2014-02-21 17:04 ` Alexander Gordeev
2014-02-21 17:05 ` [PATCH v2] kvm: Use pci_enable_msix_exact() " Alexander Gordeev
2014-02-21 17:11 ` Paolo Bonzini
2014-02-21 18:56 ` Alexander Gordeev
2014-02-21 21:36 ` Paolo Bonzini
2014-02-22 8:50 ` Alexander Gordeev
2014-02-22 8:58 ` Paolo Bonzini
2014-04-21 13:38 ` Alexander Gordeev
2014-04-24 20:45 ` Paolo Bonzini
2014-04-28 9:13 ` Paolo Bonzini
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.