Re: Packet gets stuck in NOLOCK pfifo_fast qdisc

2020-08-20 Thread Jike Song
Hi Josh, On Fri, Jul 3, 2020 at 2:14 AM Josh Hunt wrote: {snip} > Initial results with Cong's patch look promising, so far no stalls. We > will let it run over the long weekend and report back on Tuesday. > > Paolo - I have concerns about possible performance regression with the > change as

[tip:x86/pti] x86/mm/pti: Remove dead logic in pti_user_pagetable_walk*()

2018-01-08 Thread tip-bot for Jike Song
Commit-ID: 8d56eff266f3e41a6c39926269c4c3f58f881a8e Gitweb: https://git.kernel.org/tip/8d56eff266f3e41a6c39926269c4c3f58f881a8e Author: Jike Song <albca...@gmail.com> AuthorDate: Tue, 9 Jan 2018 00:03:41 +0800 Committer: Thomas Gleixner <t...@linutronix.de> CommitDate: Mon, 8

[tip:x86/pti] x86/mm/pti: Remove dead logic in pti_user_pagetable_walk*()

2018-01-08 Thread tip-bot for Jike Song
Commit-ID: 8d56eff266f3e41a6c39926269c4c3f58f881a8e Gitweb: https://git.kernel.org/tip/8d56eff266f3e41a6c39926269c4c3f58f881a8e Author: Jike Song AuthorDate: Tue, 9 Jan 2018 00:03:41 +0800 Committer: Thomas Gleixner CommitDate: Mon, 8 Jan 2018 17:42:13 +0100 x86/mm/pti: Remove dead

[PATCH v3] x86/mm/pti: remove dead logic during user pagetable population

2018-01-08 Thread Jike Song
t it is all single-threaded, there is no chance of a collision, > no need for a lock, and no need for the re-check. v3: mark functions __init; add first-hand explanation v2: add commit message. Signed-off-by: Jike Song <albca...@gmail.com> Cc: David Woodhouse <d...@a

[PATCH v3] x86/mm/pti: remove dead logic during user pagetable population

2018-01-08 Thread Jike Song
t it is all single-threaded, there is no chance of a collision, > no need for a lock, and no need for the re-check. v3: mark functions __init; add first-hand explanation v2: add commit message. Signed-off-by: Jike Song Cc: David Woodhouse Cc: Alan Cox Cc: Jiri Koshina Cc: Linus Torvalds C

Re: [PATCH] x86/mm/pti: remove dead logic during user pagetable population

2018-01-07 Thread Jike Song
On Sun, Jan 7, 2018 at 5:48 PM, Thomas Gleixner <t...@linutronix.de> wrote: > On Sun, 7 Jan 2018, Jike Song wrote: >> On Sun, Jan 7, 2018 at 3:33 AM, Thomas Gleixner <t...@linutronix.de> wrote: >> > On Sun, 7 Jan 2018, Jike Song wrote: >> > >> >

Re: [PATCH] x86/mm/pti: remove dead logic during user pagetable population

2018-01-07 Thread Jike Song
On Sun, Jan 7, 2018 at 5:48 PM, Thomas Gleixner wrote: > On Sun, 7 Jan 2018, Jike Song wrote: >> On Sun, Jan 7, 2018 at 3:33 AM, Thomas Gleixner wrote: >> > On Sun, 7 Jan 2018, Jike Song wrote: >> > >> > Care to explain why you think this is not needed? >

[PATCH v2] x86/mm/pti: remove dead logic during user pagetable population

2018-01-07 Thread Jike Song
the commit message above. Signed-off-by: Jike Song <albca...@gmail.com> Cc: David Woodhouse <d...@amazon.co.uk> Cc: Alan Cox <gno...@lxorguk.ukuu.org.uk> Cc: Jiri Koshina <ji...@kernel.org> Cc: Linus Torvalds <torva...@linux-foundation.org> Cc: Tim Chen <tim

[PATCH v2] x86/mm/pti: remove dead logic during user pagetable population

2018-01-07 Thread Jike Song
the commit message above. Signed-off-by: Jike Song Cc: David Woodhouse Cc: Alan Cox Cc: Jiri Koshina Cc: Linus Torvalds Cc: Tim Chen Cc: Andi Lutomirski Cc: Andi Kleen Cc: Peter Zijlstra Cc: Paul Turner Cc: Tom Lendacky Cc: Greg KH Cc: Dave Hansen Cc: Kees Cook Cc: sta

Re: [PATCH] x86/mm/pti: remove dead logic during user pagetable population

2018-01-06 Thread Jike Song
On Sun, Jan 7, 2018 at 4:03 AM, Willy Tarreau <w...@1wt.eu> wrote: > On Sun, Jan 07, 2018 at 01:50:59AM +0800, Jike Song wrote: >> Signed-off-by: Jike Song <albca...@gmail.com> > > It would be nice to have a commit message, particularly in this quite > sensitiv

Re: [PATCH] x86/mm/pti: remove dead logic during user pagetable population

2018-01-06 Thread Jike Song
On Sun, Jan 7, 2018 at 4:03 AM, Willy Tarreau wrote: > On Sun, Jan 07, 2018 at 01:50:59AM +0800, Jike Song wrote: >> Signed-off-by: Jike Song > > It would be nice to have a commit message, particularly in this quite > sensitive series... Yes that's useful, will add it i

Re: [PATCH] x86/mm/pti: remove dead logic during user pagetable population

2018-01-06 Thread Jike Song
On Sun, Jan 7, 2018 at 3:33 AM, Thomas Gleixner <t...@linutronix.de> wrote: > On Sun, 7 Jan 2018, Jike Song wrote: > > Care to explain why you think this is not needed? > Hi Thomas, Look at one of the original code snippets: 162 if (pgd_none(*pgd)) { 163

Re: [PATCH] x86/mm/pti: remove dead logic during user pagetable population

2018-01-06 Thread Jike Song
On Sun, Jan 7, 2018 at 3:33 AM, Thomas Gleixner wrote: > On Sun, 7 Jan 2018, Jike Song wrote: > > Care to explain why you think this is not needed? > Hi Thomas, Look at one of the original code snippets: 162 if (pgd_none(*pgd)) { 163 unsigned long

[PATCH] x86/mm/pti: remove dead logic during user pagetable population

2018-01-06 Thread Jike Song
Signed-off-by: Jike Song <albca...@gmail.com> --- arch/x86/mm/pti.c | 28 1 file changed, 4 insertions(+), 24 deletions(-) diff --git a/arch/x86/mm/pti.c b/arch/x86/mm/pti.c index 43d4a4a29037..dc611d039bd5 100644 --- a/arch/x86/mm/pti.c +++ b/arch/x86/mm

[PATCH] x86/mm/pti: remove dead logic during user pagetable population

2018-01-06 Thread Jike Song
Signed-off-by: Jike Song --- arch/x86/mm/pti.c | 28 1 file changed, 4 insertions(+), 24 deletions(-) diff --git a/arch/x86/mm/pti.c b/arch/x86/mm/pti.c index 43d4a4a29037..dc611d039bd5 100644 --- a/arch/x86/mm/pti.c +++ b/arch/x86/mm/pti.c @@ -164,12 +164,7

Re: [RFC PATCH v5 0/5] vfio-pci: Add support for mmapping MSI-X table

2017-08-14 Thread Jike Song
On 08/14/2017 09:12 PM, Robin Murphy wrote: > On 14/08/17 10:45, Alexey Kardashevskiy wrote: >> Folks, >> >> Is there anything to change besides those compiler errors and David's >> comment in 5/5? Or the while patchset is too bad? Thanks. > > While I now understand it's not the low-level thing I

Re: [RFC PATCH v5 0/5] vfio-pci: Add support for mmapping MSI-X table

2017-08-14 Thread Jike Song
On 08/14/2017 09:12 PM, Robin Murphy wrote: > On 14/08/17 10:45, Alexey Kardashevskiy wrote: >> Folks, >> >> Is there anything to change besides those compiler errors and David's >> comment in 5/5? Or the while patchset is too bad? Thanks. > > While I now understand it's not the low-level thing I

Re: [RFC PATCH v5 0/5] vfio-pci: Add support for mmapping MSI-X table

2017-08-14 Thread Jike Song
On 08/15/2017 09:33 AM, Benjamin Herrenschmidt wrote: > On Tue, 2017-08-15 at 09:16 +0800, Jike Song wrote: >>> Taking a step back, though, why does vfio-pci perform this check in the >>> first place? If a malicious guest already has control of a device, any >>> kind

Re: [RFC PATCH v5 0/5] vfio-pci: Add support for mmapping MSI-X table

2017-08-14 Thread Jike Song
On 08/15/2017 09:33 AM, Benjamin Herrenschmidt wrote: > On Tue, 2017-08-15 at 09:16 +0800, Jike Song wrote: >>> Taking a step back, though, why does vfio-pci perform this check in the >>> first place? If a malicious guest already has control of a device, any >>> kind

Re: [PATCH] PCI: Do not enable extended tags on pre-dated (v1.x) systems

2017-07-06 Thread Jike Song
On Wed, Jul 5, 2017 at 9:19 PM, Sinan Kaya wrote: > According to extended tags ECN document, all PCIe receivers are expected > to support extended tags support. It should be safe to enable extended > tags on endpoints without checking compatibility. > > This assumption seems

Re: [PATCH] PCI: Do not enable extended tags on pre-dated (v1.x) systems

2017-07-06 Thread Jike Song
On Wed, Jul 5, 2017 at 9:19 PM, Sinan Kaya wrote: > According to extended tags ECN document, all PCIe receivers are expected > to support extended tags support. It should be safe to enable extended > tags on endpoints without checking compatibility. > > This assumption seems to be working fine

Re: [PATCH] kvmgt: Hold struct kvm reference

2017-03-20 Thread Jike Song
pinlock from the invalid reference, but > other failure modes are clearly possible. Hold a reference to avoid > this. > > Signed-off-by: Alex Williamson <alex.william...@redhat.com> > Cc: sta...@vger.kernel.org #v4.10 > Cc: Jike Song <jike.s...@intel.com> > Cc: Pa

Re: [PATCH] kvmgt: Hold struct kvm reference

2017-03-20 Thread Jike Song
pinlock from the invalid reference, but > other failure modes are clearly possible. Hold a reference to avoid > this. > > Signed-off-by: Alex Williamson > Cc: sta...@vger.kernel.org #v4.10 > Cc: Jike Song > Cc: Paolo Bonzini > Cc: Zhenyu Wang > Cc: Zhi Wang > --- R

Re: [PATCH] drm/i915/gvt/kvmgt: mdev ABI is available_instances, not available_instance

2017-01-24 Thread Jike Song
lex Williamson <alex.william...@redhat.com> > --- > > This should really be fixed before initial release in v4.10 Acked-by: Jike Song <jike.s...@intel.com> Thanks for finding this! -- Thanks, Jike > > drivers/gpu/drm/i915/gvt/kvmgt.c |8 > 1 file changed,

Re: [PATCH] drm/i915/gvt/kvmgt: mdev ABI is available_instances, not available_instance

2017-01-24 Thread Jike Song
gned-off-by: Alex Williamson > --- > > This should really be fixed before initial release in v4.10 Acked-by: Jike Song Thanks for finding this! -- Thanks, Jike > > drivers/gpu/drm/i915/gvt/kvmgt.c |8 > 1 file changed, 4 insertions(+), 4 deletions(-) > > diff --git a/driver

[v2 1/2] capability: export has_capability

2017-01-12 Thread Jike Song
has_capability() is sometimes needed by modules to test capability for specified task other than current, so export it. Cc: Alex Williamson <alex.william...@redhat.com> Cc: Kirti Wankhede <kwankh...@nvidia.com> Acked-by: Serge Hallyn <se...@hallyn.com> Signed-off-by:

[v2 1/2] capability: export has_capability

2017-01-12 Thread Jike Song
has_capability() is sometimes needed by modules to test capability for specified task other than current, so export it. Cc: Alex Williamson Cc: Kirti Wankhede Acked-by: Serge Hallyn Signed-off-by: Jike Song --- kernel/capability.c | 1 + 1 file changed, 1 insertion(+) diff --git a/kernel

[v2 2/2] vfio iommu type1: fix the testing of capability for remote task

2017-01-12 Thread Jike Song
hat.com> Signed-off-by: Jike Song <jike.s...@intel.com> --- drivers/vfio/vfio_iommu_type1.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/vfio/vfio_iommu_type1.c b/drivers/vfio/vfio_iommu_type1.c index 9266271..77373e5 100644 --- a/drivers/vfio/vfio_iommu_ty

[v2 2/2] vfio iommu type1: fix the testing of capability for remote task

2017-01-12 Thread Jike Song
is, in a specified namespace. Fix it by using has_capability() instead, which tests the cap for specified task in init_user_ns, the same namespace as capable(). Cc: Alex Williamson Cc: Kirti Wankhede Cc: Gerd Hoffmann Signed-off-by: Jike Song --- drivers/vfio/vfio_iommu_type1.c | 3 +-- 1

[v2 0/2] test capability for remote task

2017-01-12 Thread Jike Song
I kept EXPORT_SYMBOL other than EXPORT_SYMBOL_GPL, since I'm still worry about changing the type of existing exports in 'capability.c'. I'm new to open-source fearing of violating GPL :) Jike Song (2): capability: export has_capability vfio iommu type1: fix the testing of capability for remote task d

[v2 0/2] test capability for remote task

2017-01-12 Thread Jike Song
I kept EXPORT_SYMBOL other than EXPORT_SYMBOL_GPL, since I'm still worry about changing the type of existing exports in 'capability.c'. I'm new to open-source fearing of violating GPL :) Jike Song (2): capability: export has_capability vfio iommu type1: fix the testing of capability for remote task d

Re: [PATCH 1/2] capability: export has_capability

2017-01-11 Thread Jike Song
On 01/12/2017 02:47 AM, Alex Williamson wrote: > On Thu, 22 Dec 2016 00:10:15 +0800 > Jike Song <jike.s...@intel.com> wrote: > >> has_capability() is sometimes needed by modules to test capability >> for specified task other than current, so export it. >> >

Re: [PATCH 1/2] capability: export has_capability

2017-01-11 Thread Jike Song
On 01/12/2017 02:47 AM, Alex Williamson wrote: > On Thu, 22 Dec 2016 00:10:15 +0800 > Jike Song wrote: > >> has_capability() is sometimes needed by modules to test capability >> for specified task other than current, so export it. >> >> Cc: Alex Williamson >

Re: [PATCH 2/2] vfio iommu type1: fix the testing of capability for remote task

2016-12-22 Thread Jike Song
On 12/22/2016 08:20 PM, Kirti Wankhede wrote: > On 12/21/2016 9:40 PM, Jike Song wrote: >> Before the mdev enhancement type1 iommu used capable() to test the >> capability of current task; in the course of mdev development a >> new requirement, testing for another ta

Re: [PATCH 2/2] vfio iommu type1: fix the testing of capability for remote task

2016-12-22 Thread Jike Song
On 12/22/2016 08:20 PM, Kirti Wankhede wrote: > On 12/21/2016 9:40 PM, Jike Song wrote: >> Before the mdev enhancement type1 iommu used capable() to test the >> capability of current task; in the course of mdev development a >> new requirement, testing for another ta

Re: [PATCH 2/4] vfio-mdev: de-polute the namespace, rename parent_device & parent_ops

2016-12-21 Thread Jike Song
Not sure if this is appropriate, but if not having the Documentation considered, for patch 2-4: Reviewed-by: Jike Song <jike.s...@intel.com> -- Thanks, Jike On 12/22/2016 07:27 AM, Alex Williamson wrote: > From: Alex Williamson <alwil...@nuc.home> > > Add an mdev_ prefix

Re: [PATCH 2/4] vfio-mdev: de-polute the namespace, rename parent_device & parent_ops

2016-12-21 Thread Jike Song
Not sure if this is appropriate, but if not having the Documentation considered, for patch 2-4: Reviewed-by: Jike Song -- Thanks, Jike On 12/22/2016 07:27 AM, Alex Williamson wrote: > From: Alex Williamson > > Add an mdev_ prefix so we're not poluting the namespace so much. >

Re: [PATCH 0/4] vfio-mdev: Clean namespace and better define ABI

2016-12-21 Thread Jike Song
On 12/22/2016 07:27 AM, Alex Williamson wrote: > Cleanup the namespace a bit by prefixing structures with mdev_ and > also more concretely define the mdev interface. Structs with comments > defining which fields are private vs public tempts poor behavior, > especially for an interface where we

Re: [PATCH 0/4] vfio-mdev: Clean namespace and better define ABI

2016-12-21 Thread Jike Song
On 12/22/2016 07:27 AM, Alex Williamson wrote: > Cleanup the namespace a bit by prefixing structures with mdev_ and > also more concretely define the mdev interface. Structs with comments > defining which fields are private vs public tempts poor behavior, > especially for an interface where we

[PATCH 1/2] capability: export has_capability

2016-12-21 Thread Jike Song
has_capability() is sometimes needed by modules to test capability for specified task other than current, so export it. Cc: Alex Williamson <alex.william...@redhat.com> Cc: Kirti Wankhede <kwankh...@nvidia.com> Signed-off-by: Jike Song <jike.s...@intel.com> --- kernel/capabili

[PATCH 2/2] vfio iommu type1: fix the testing of capability for remote task

2016-12-21 Thread Jike Song
hat.com> Signed-off-by: Jike Song <jike.s...@intel.com> --- drivers/vfio/vfio_iommu_type1.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/vfio/vfio_iommu_type1.c b/drivers/vfio/vfio_iommu_type1.c index f3726ba..b54aedf 100644 --- a/drivers/vfio/vfio_iom

[PATCH 1/2] capability: export has_capability

2016-12-21 Thread Jike Song
has_capability() is sometimes needed by modules to test capability for specified task other than current, so export it. Cc: Alex Williamson Cc: Kirti Wankhede Signed-off-by: Jike Song --- kernel/capability.c | 1 + 1 file changed, 1 insertion(+) diff --git a/kernel/capability.c b/kernel

[PATCH 2/2] vfio iommu type1: fix the testing of capability for remote task

2016-12-21 Thread Jike Song
is, in a specified namespace. Fix it by using has_capability() instead, which tests the cap for specified task in init_user_ns, the same namespace as capable(). Cc: Alex Williamson Cc: Kirti Wankhede Cc: Gerd Hoffmann Signed-off-by: Jike Song --- drivers/vfio/vfio_iommu_type1.c | 6 ++ 1

[PATCH 0/2] test capability for remote task

2016-12-21 Thread Jike Song
symbols allows a specified task. So here has_capability() is exported then used in the vfio iommu type1 driver. Jike Song (2): capability: export has_capability vfio iommu type1: fix the testing of capability for remote task drivers/vfio/vfio_iommu_type1.c | 6 ++ kernel/capability.c

[PATCH 0/2] test capability for remote task

2016-12-21 Thread Jike Song
symbols allows a specified task. So here has_capability() is exported then used in the vfio iommu type1 driver. Jike Song (2): capability: export has_capability vfio iommu type1: fix the testing of capability for remote task drivers/vfio/vfio_iommu_type1.c | 6 ++ kernel/capability.c

Re: [PATCH v9 00/12] Add Mediated device support

2016-12-05 Thread Jike Song
On 12/06/2016 01:44 AM, Gerd Hoffmann wrote: > Hi, > >> Just want to share that we have published a KVMGT implementation >> based on this v9 patchset, to: >> >> https://github.com/01org/gvt-linux/tree/gvt-next-kvmgt >> >> It doesn't utilize common routines introduced by 05+ patches yet. >>

Re: [PATCH v9 00/12] Add Mediated device support

2016-12-05 Thread Jike Song
On 12/06/2016 01:44 AM, Gerd Hoffmann wrote: > Hi, > >> Just want to share that we have published a KVMGT implementation >> based on this v9 patchset, to: >> >> https://github.com/01org/gvt-linux/tree/gvt-next-kvmgt >> >> It doesn't utilize common routines introduced by 05+ patches yet. >>

Re: [Qemu-devel] [PATCH v14 00/22] Add Mediated device support

2016-11-17 Thread Jike Song
On 11/18/2016 10:00 AM, Kirti Wankhede wrote: > On 11/18/2016 3:35 AM, Neo Jia wrote: >> On Thu, Nov 17, 2016 at 02:25:15PM -0700, Alex Williamson wrote: >>> On Thu, 17 Nov 2016 02:16:12 +0530 >>> Kirti Wankhede wrote: Documentation/ABI/testing/sysfs-bus-vfio-mdev

Re: [Qemu-devel] [PATCH v14 00/22] Add Mediated device support

2016-11-17 Thread Jike Song
On 11/18/2016 10:00 AM, Kirti Wankhede wrote: > On 11/18/2016 3:35 AM, Neo Jia wrote: >> On Thu, Nov 17, 2016 at 02:25:15PM -0700, Alex Williamson wrote: >>> On Thu, 17 Nov 2016 02:16:12 +0530 >>> Kirti Wankhede wrote: Documentation/ABI/testing/sysfs-bus-vfio-mdev | 111 ++

Re: [PATCH v14 12/22] vfio: Add notifier callback to parent's ops structure of mdev

2016-11-17 Thread Jike Song
On 11/17/2016 04:46 AM, Kirti Wankhede wrote: > Add a notifier calback to parent's ops structure of mdev device so that per > device notifer for vfio module is registered through vfio_mdev module. > > Signed-off-by: Kirti Wankhede > Signed-off-by: Neo Jia

Re: [PATCH v14 12/22] vfio: Add notifier callback to parent's ops structure of mdev

2016-11-17 Thread Jike Song
On 11/17/2016 04:46 AM, Kirti Wankhede wrote: > Add a notifier calback to parent's ops structure of mdev device so that per > device notifer for vfio module is registered through vfio_mdev module. > > Signed-off-by: Kirti Wankhede > Signed-off-by: Neo Jia > Change-Id:

Re: [PATCH v14 11/22] vfio iommu: Add blocking notifier to notify DMA_UNMAP

2016-11-16 Thread Jike Song
On 11/17/2016 04:46 AM, Kirti Wankhede wrote: > Added blocking notifier to IOMMU TYPE1 driver to notify vendor drivers > about DMA_UNMAP. > Exported two APIs vfio_register_notifier() and vfio_unregister_notifier(). > Notifier should be registered, if external user wants to use >

Re: [PATCH v14 11/22] vfio iommu: Add blocking notifier to notify DMA_UNMAP

2016-11-16 Thread Jike Song
On 11/17/2016 04:46 AM, Kirti Wankhede wrote: > Added blocking notifier to IOMMU TYPE1 driver to notify vendor drivers > about DMA_UNMAP. > Exported two APIs vfio_register_notifier() and vfio_unregister_notifier(). > Notifier should be registered, if external user wants to use >

Re: [PATCH v12 12/22] vfio: Add notifier callback to parent's ops structure of mdev

2016-11-15 Thread Jike Song
On 11/15/2016 11:19 PM, Alex Williamson wrote: > On Tue, 15 Nov 2016 14:45:42 +0800 > Jike Song <jike.s...@intel.com> wrote: > >> On 11/14/2016 11:42 PM, Kirti Wankhede wrote: >>> Add a notifier calback to parent's ops structure of mdev device so that per >

Re: [PATCH v12 12/22] vfio: Add notifier callback to parent's ops structure of mdev

2016-11-15 Thread Jike Song
On 11/15/2016 11:19 PM, Alex Williamson wrote: > On Tue, 15 Nov 2016 14:45:42 +0800 > Jike Song wrote: > >> On 11/14/2016 11:42 PM, Kirti Wankhede wrote: >>> Add a notifier calback to parent's ops structure of mdev device so that per >>> device notifer for

Re: [PATCH v12 12/22] vfio: Add notifier callback to parent's ops structure of mdev

2016-11-15 Thread Jike Song
On 11/15/2016 04:11 PM, Kirti Wankhede wrote: > > > On 11/15/2016 12:15 PM, Jike Song wrote: >> On 11/14/2016 11:42 PM, Kirti Wankhede wrote: >>> Add a notifier calback to parent's ops structure of mdev device so that per >>> device notifer for vfio module is re

Re: [PATCH v12 12/22] vfio: Add notifier callback to parent's ops structure of mdev

2016-11-15 Thread Jike Song
On 11/15/2016 04:11 PM, Kirti Wankhede wrote: > > > On 11/15/2016 12:15 PM, Jike Song wrote: >> On 11/14/2016 11:42 PM, Kirti Wankhede wrote: >>> Add a notifier calback to parent's ops structure of mdev device so that per >>> device notifer for vfio module is re

Re: [PATCH v12 12/22] vfio: Add notifier callback to parent's ops structure of mdev

2016-11-14 Thread Jike Song
On 11/14/2016 11:42 PM, Kirti Wankhede wrote: > Add a notifier calback to parent's ops structure of mdev device so that per > device notifer for vfio module is registered through vfio_mdev module. > > Signed-off-by: Kirti Wankhede > Signed-off-by: Neo Jia

Re: [PATCH v12 12/22] vfio: Add notifier callback to parent's ops structure of mdev

2016-11-14 Thread Jike Song
On 11/14/2016 11:42 PM, Kirti Wankhede wrote: > Add a notifier calback to parent's ops structure of mdev device so that per > device notifer for vfio module is registered through vfio_mdev module. > > Signed-off-by: Kirti Wankhede > Signed-off-by: Neo Jia > Change-Id:

Re: [PATCH v11 10/22] vfio iommu type1: Add support for mediated devices

2016-11-07 Thread Jike Song
On 11/08/2016 07:16 AM, Alex Williamson wrote: > On Sat, 5 Nov 2016 02:40:44 +0530 > Kirti Wankhede wrote: > >> VFIO IOMMU drivers are designed for the devices which are IOMMU capable. >> Mediated device only uses IOMMU APIs, the underlying hardware can be >> managed by an

Re: [PATCH v11 10/22] vfio iommu type1: Add support for mediated devices

2016-11-07 Thread Jike Song
On 11/08/2016 07:16 AM, Alex Williamson wrote: > On Sat, 5 Nov 2016 02:40:44 +0530 > Kirti Wankhede wrote: > >> VFIO IOMMU drivers are designed for the devices which are IOMMU capable. >> Mediated device only uses IOMMU APIs, the underlying hardware can be >> managed by an IOMMU domain. >> >>

Re: [ANNOUNCE] 2016-Q3 release of KVMGT (Was Re: KVMGT - the implementation of ...)

2016-11-06 Thread Jike Song
uct nor should it be considered one. Extra care should be taken when testing and configuring a system to use the KVMGT project. -- Thanks, Jike On 07/20/2016 12:52 PM, Jike Song wrote: > Hi all, > > We are pleased to announce another update of Intel GVT-g for KVM. > > Intel GVT-g f

Re: [ANNOUNCE] 2016-Q3 release of KVMGT (Was Re: KVMGT - the implementation of ...)

2016-11-06 Thread Jike Song
uct nor should it be considered one. Extra care should be taken when testing and configuring a system to use the KVMGT project. -- Thanks, Jike On 07/20/2016 12:52 PM, Jike Song wrote: > Hi all, > > We are pleased to announce another update of Intel GVT-g for KVM. > > Intel GVT-g f

Re: [Intel-gfx] [Announcement] 2016-Q3 release of XenGT - a Mediated Graphics Passthrough Solution from Intel

2016-11-06 Thread Jike Song
a work in progress. As such it is not a complete product nor should it be considered one. Extra care should be taken when testing and configuring a system to use the XenGT project. -- Thanks, Jike On 07/22/2016 01:42 PM, Jike Song wrote: > Hi all, > > We are pleased to announce anoth

Re: [Intel-gfx] [Announcement] 2016-Q3 release of XenGT - a Mediated Graphics Passthrough Solution from Intel

2016-11-06 Thread Jike Song
a work in progress. As such it is not a complete product nor should it be considered one. Extra care should be taken when testing and configuring a system to use the XenGT project. -- Thanks, Jike On 07/22/2016 01:42 PM, Jike Song wrote: > Hi all, > > We are pleased to announce anoth

Re: [PATCH v10 08/19] vfio iommu type1: Add find_iommu_group() function

2016-11-02 Thread Jike Song
* last domain, then all the mappings go away too. > + */ > + if (list_empty(>group_list)) { > + if (list_is_singular(>domain_list)) > + vfio_iommu_unmap_unpin_all(iommu); > + iommu_domain_free(domain->domain); > + list_del(>next); > + kfree(domain); > } > + goto done; > } > > done: > Reviewed-by: Jike Song <jike.s...@intel.com> -- Thanks, Jike

Re: [PATCH v10 08/19] vfio iommu type1: Add find_iommu_group() function

2016-11-02 Thread Jike Song
y too. > + */ > + if (list_empty(>group_list)) { > + if (list_is_singular(>domain_list)) > + vfio_iommu_unmap_unpin_all(iommu); > + iommu_domain_free(domain->domain); > + list_del(>next); > + kfree(domain); > } > + goto done; > } > > done: > Reviewed-by: Jike Song -- Thanks, Jike

Re: [Qemu-devel] [PATCH v9 04/12] vfio iommu: Add support for mediated devices

2016-11-02 Thread Jike Song
On 11/02/2016 09:18 PM, Kirti Wankhede wrote: > On 11/2/2016 6:30 PM, Jike Song wrote: >> On 11/02/2016 08:41 PM, Kirti Wankhede wrote: >>> On 11/2/2016 5:51 PM, Jike Song wrote: >>>> On 11/02/2016 12:09 PM, Alexey Kardashevskiy wrote: >>>>> O

Re: [Qemu-devel] [PATCH v9 04/12] vfio iommu: Add support for mediated devices

2016-11-02 Thread Jike Song
On 11/02/2016 09:18 PM, Kirti Wankhede wrote: > On 11/2/2016 6:30 PM, Jike Song wrote: >> On 11/02/2016 08:41 PM, Kirti Wankhede wrote: >>> On 11/2/2016 5:51 PM, Jike Song wrote: >>>> On 11/02/2016 12:09 PM, Alexey Kardashevskiy wrote: >>>>> O

Re: [PATCH v10 09/19] vfio iommu type1: Add support for mediated devices

2016-11-02 Thread Jike Song
On 10/27/2016 05:29 AM, Kirti Wankhede wrote: > VFIO IOMMU drivers are designed for the devices which are IOMMU capable. > Mediated device only uses IOMMU APIs, the underlying hardware can be > managed by an IOMMU domain. > > Aim of this change is: > - To use most of the code of TYPE1 IOMMU

Re: [PATCH v10 09/19] vfio iommu type1: Add support for mediated devices

2016-11-02 Thread Jike Song
On 10/27/2016 05:29 AM, Kirti Wankhede wrote: > VFIO IOMMU drivers are designed for the devices which are IOMMU capable. > Mediated device only uses IOMMU APIs, the underlying hardware can be > managed by an IOMMU domain. > > Aim of this change is: > - To use most of the code of TYPE1 IOMMU

Re: [Qemu-devel] [PATCH v9 04/12] vfio iommu: Add support for mediated devices

2016-11-02 Thread Jike Song
On 11/02/2016 08:41 PM, Kirti Wankhede wrote: > On 11/2/2016 5:51 PM, Jike Song wrote: >> On 11/02/2016 12:09 PM, Alexey Kardashevskiy wrote: >>> Or you could just reference and use @mm as KVM and others do. Or there is >>> anything else you need from @current than

Re: [Qemu-devel] [PATCH v9 04/12] vfio iommu: Add support for mediated devices

2016-11-02 Thread Jike Song
On 11/02/2016 08:41 PM, Kirti Wankhede wrote: > On 11/2/2016 5:51 PM, Jike Song wrote: >> On 11/02/2016 12:09 PM, Alexey Kardashevskiy wrote: >>> Or you could just reference and use @mm as KVM and others do. Or there is >>> anything else you need from @current than

Re: [Qemu-devel] [PATCH v9 04/12] vfio iommu: Add support for mediated devices

2016-11-02 Thread Jike Song
On 11/02/2016 12:09 PM, Alexey Kardashevskiy wrote: > On 02/11/16 14:29, Kirti Wankhede wrote: >> >> >> On 11/2/2016 6:54 AM, Alexey Kardashevskiy wrote: >>> On 02/11/16 01:01, Kirti Wankhede wrote: On 10/28/2016 7:48 AM, Alexey Kardashevskiy wrote: > On 27/10/16 23:31, Kirti

Re: [Qemu-devel] [PATCH v9 04/12] vfio iommu: Add support for mediated devices

2016-11-02 Thread Jike Song
On 11/02/2016 12:09 PM, Alexey Kardashevskiy wrote: > On 02/11/16 14:29, Kirti Wankhede wrote: >> >> >> On 11/2/2016 6:54 AM, Alexey Kardashevskiy wrote: >>> On 02/11/16 01:01, Kirti Wankhede wrote: On 10/28/2016 7:48 AM, Alexey Kardashevskiy wrote: > On 27/10/16 23:31, Kirti

Re: [PATCH v10 04/19] vfio: Common function to increment container_users

2016-11-02 Thread Jike Song
return ERR_PTR(-EPERM); > - } > - > - if (!group->container->iommu_driver || > - !vfio_group_viable(group)) { > - atomic_dec(>container_users); > - return ERR_PTR(-EINVAL); > - } > + ret = vfio_group_add_container_user(group); > + if (ret) > + return ERR_PTR(ret); > > vfio_group_get(group); > Reviewed-by: Jike Song <jike.s...@intel.com> -- Thanks, Jike

Re: [PATCH v10 04/19] vfio: Common function to increment container_users

2016-11-02 Thread Jike Song
if (!group->container->iommu_driver || > - !vfio_group_viable(group)) { > - atomic_dec(>container_users); > - return ERR_PTR(-EINVAL); > - } > + ret = vfio_group_add_container_user(group); > + if (ret) > + return ERR_PTR(ret); > > vfio_group_get(group); > Reviewed-by: Jike Song -- Thanks, Jike

Re: [PATCH v10 03/19] vfio: Rearrange functions to get vfio_group from dev

2016-11-02 Thread Jike Song
vfio_device *device; > > - iommu_group = iommu_group_get(dev); > - if (!iommu_group) > - return NULL; > - > - group = vfio_group_get_from_iommu(iommu_group); > - iommu_group_put(iommu_group); > + group = vfio_group_get_from_dev(dev); > if (!group) > return NULL; > Reviewed-by: Jike Song <jike.s...@intel.com> -- Thanks, Jike

Re: [PATCH v10 03/19] vfio: Rearrange functions to get vfio_group from dev

2016-11-02 Thread Jike Song
iommu_group_get(dev); > - if (!iommu_group) > - return NULL; > - > - group = vfio_group_get_from_iommu(iommu_group); > - iommu_group_put(iommu_group); > + group = vfio_group_get_from_dev(dev); > if (!group) > return NULL; > Reviewed-by: Jike Song -- Thanks, Jike

Re: [PATCH v10 02/19] vfio: VFIO based driver for Mediated devices

2016-11-02 Thread Jike Song
evice *mdev = to_mdev_device(dev); > + > + return vfio_add_group_dev(dev, _mdev_dev_ops, mdev); > +} > + > +void vfio_mdev_remove(struct device *dev) > +{ > + vfio_del_group_dev(dev); > +} > + > +struct mdev_driver vfio_mdev_driver = { > + .name = "vfio_mdev", > + .probe = vfio_mdev_probe, > + .remove = vfio_mdev_remove, > +}; > + > +static int __init vfio_mdev_init(void) > +{ > + return mdev_register_driver(_mdev_driver, THIS_MODULE); > +} > + > +static void __exit vfio_mdev_exit(void) > +{ > + mdev_unregister_driver(_mdev_driver); > +} > + > +module_init(vfio_mdev_init) > +module_exit(vfio_mdev_exit) > + > +MODULE_VERSION(DRIVER_VERSION); > +MODULE_LICENSE("GPL"); > +MODULE_AUTHOR(DRIVER_AUTHOR); > +MODULE_DESCRIPTION(DRIVER_DESC); > Reviewed-by: Jike Song <jike.s...@intel.com> -- Thanks, Jike

Re: [PATCH v10 02/19] vfio: VFIO based driver for Mediated devices

2016-11-02 Thread Jike Song
gt; +} > + > +void vfio_mdev_remove(struct device *dev) > +{ > + vfio_del_group_dev(dev); > +} > + > +struct mdev_driver vfio_mdev_driver = { > + .name = "vfio_mdev", > + .probe = vfio_mdev_probe, > + .remove = vfio_mdev_remove, > +}; > + > +static int __init vfio_mdev_init(void) > +{ > + return mdev_register_driver(_mdev_driver, THIS_MODULE); > +} > + > +static void __exit vfio_mdev_exit(void) > +{ > + mdev_unregister_driver(_mdev_driver); > +} > + > +module_init(vfio_mdev_init) > +module_exit(vfio_mdev_exit) > + > +MODULE_VERSION(DRIVER_VERSION); > +MODULE_LICENSE("GPL"); > +MODULE_AUTHOR(DRIVER_AUTHOR); > +MODULE_DESCRIPTION(DRIVER_DESC); > Reviewed-by: Jike Song -- Thanks, Jike

Re: [Qemu-devel] [PATCH v10 01/19] vfio: Mediated device Core driver

2016-11-02 Thread Jike Song
On 11/02/2016 03:59 PM, Kirti Wankhede wrote: > On 10/29/2016 11:41 PM, Jike Song wrote: >> On 10/29/2016 06:06 PM, Kirti Wankhede wrote: >>> >>> >>> On 10/29/2016 10:00 AM, Jike Song wrote: >>>> On 10/27/2016 05:29 AM, Kirti Wankhede wrote: &g

Re: [Qemu-devel] [PATCH v10 01/19] vfio: Mediated device Core driver

2016-11-02 Thread Jike Song
On 11/02/2016 03:59 PM, Kirti Wankhede wrote: > On 10/29/2016 11:41 PM, Jike Song wrote: >> On 10/29/2016 06:06 PM, Kirti Wankhede wrote: >>> >>> >>> On 10/29/2016 10:00 AM, Jike Song wrote: >>>> On 10/27/2016 05:29 AM, Kirti Wankhede wrote: &g

Re: [Qemu-devel] [PATCH v10 00/19] Add Mediated device support

2016-11-01 Thread Jike Song
On 11/01/2016 11:24 PM, Gerd Hoffmann wrote: >> I rebased KVMGT upon v10, with 2 minor changes: >> >> 1, get_user_pages_remote has only 7 args > > Appears to be a 4.9 merge window change. v10 as-is applies and builds > fine against 4.8, after rebasing to 4.9-rc3 it stops building due to >

Re: [Qemu-devel] [PATCH v10 00/19] Add Mediated device support

2016-11-01 Thread Jike Song
On 11/01/2016 11:24 PM, Gerd Hoffmann wrote: >> I rebased KVMGT upon v10, with 2 minor changes: >> >> 1, get_user_pages_remote has only 7 args > > Appears to be a 4.9 merge window change. v10 as-is applies and builds > fine against 4.8, after rebasing to 4.9-rc3 it stops building due to >

Re: [PATCH v10 00/19] Add Mediated device support

2016-11-01 Thread Jike Song
On 10/27/2016 05:29 AM, Kirti Wankhede wrote: > This series adds Mediated device support to Linux host kernel. Purpose > of this series is to provide a common interface for mediated device > management that can be used by different devices. This series introduces > Mdev core module that creates

Re: [PATCH v10 00/19] Add Mediated device support

2016-11-01 Thread Jike Song
On 10/27/2016 05:29 AM, Kirti Wankhede wrote: > This series adds Mediated device support to Linux host kernel. Purpose > of this series is to provide a common interface for mediated device > management that can be used by different devices. This series introduces > Mdev core module that creates

Re: [PATCH v10 05/19] vfio iommu: Added pin and unpin callback functions to vfio_iommu_driver_ops

2016-11-01 Thread Jike Song
On 10/27/2016 05:29 AM, Kirti Wankhede wrote: > Added two new callback functions to struct vfio_iommu_driver_ops. Backend > IOMMU module that supports pining and unpinning pages for mdev devices > should provide these functions. > Added APIs for pining and unpining pages to VFIO module. These

Re: [PATCH v10 05/19] vfio iommu: Added pin and unpin callback functions to vfio_iommu_driver_ops

2016-11-01 Thread Jike Song
On 10/27/2016 05:29 AM, Kirti Wankhede wrote: > Added two new callback functions to struct vfio_iommu_driver_ops. Backend > IOMMU module that supports pining and unpinning pages for mdev devices > should provide these functions. > Added APIs for pining and unpining pages to VFIO module. These

Re: [PATCH v10 01/19] vfio: Mediated device Core driver

2016-10-31 Thread Jike Song
On 11/01/2016 11:44 AM, Alex Williamson wrote: > On Tue, 01 Nov 2016 11:08:15 +0800 > Jike Song <jike.s...@intel.com> wrote: >> On 10/27/2016 05:29 AM, Kirti Wankhede wrote: >>> +static int mdev_attach_iommu(struct mdev_device *mdev) >>> +{ >>> +

Re: [PATCH v10 01/19] vfio: Mediated device Core driver

2016-10-31 Thread Jike Song
On 11/01/2016 11:44 AM, Alex Williamson wrote: > On Tue, 01 Nov 2016 11:08:15 +0800 > Jike Song wrote: >> On 10/27/2016 05:29 AM, Kirti Wankhede wrote: >>> +static int mdev_attach_iommu(struct mdev_device *mdev) >>> +{ >>> + int ret; >>> +

Re: [PATCH v10 01/19] vfio: Mediated device Core driver

2016-10-31 Thread Jike Song
On 10/27/2016 05:29 AM, Kirti Wankhede wrote: > Design for Mediated Device Driver: > Main purpose of this driver is to provide a common interface for mediated > device management that can be used by different drivers of different > devices. > > This module provides a generic interface to create

Re: [PATCH v10 01/19] vfio: Mediated device Core driver

2016-10-31 Thread Jike Song
On 10/27/2016 05:29 AM, Kirti Wankhede wrote: > Design for Mediated Device Driver: > Main purpose of this driver is to provide a common interface for mediated > device management that can be used by different drivers of different > devices. > > This module provides a generic interface to create

Re: [PATCH v10 18/19] docs: Sysfs ABI for mediated device framework

2016-10-31 Thread Jike Song
On 10/27/2016 05:29 AM, Kirti Wankhede wrote: > Added details of sysfs ABI for mediated device framework > > Signed-off-by: Kirti Wankhede > Signed-off-by: Neo Jia > Change-Id: Icb0fd4ed58a2fa793fbcb1c3d5009a4403c1f3ac > --- >

Re: [PATCH v10 18/19] docs: Sysfs ABI for mediated device framework

2016-10-31 Thread Jike Song
On 10/27/2016 05:29 AM, Kirti Wankhede wrote: > Added details of sysfs ABI for mediated device framework > > Signed-off-by: Kirti Wankhede > Signed-off-by: Neo Jia > Change-Id: Icb0fd4ed58a2fa793fbcb1c3d5009a4403c1f3ac > --- > Documentation/ABI/testing/sysfs-bus-vfio-mdev | 111 >

Re: [PATCH v10 10/19] vfio iommu: Add blocking notifier to notify DMA_UNMAP

2016-10-31 Thread Jike Song
On 10/31/2016 01:59 PM, Kirti Wankhede wrote: > On 10/31/2016 9:20 AM, Jike Song wrote: >> On 10/27/2016 05:29 AM, Kirti Wankhede wrote: >>> Added blocking notifier to IOMMU TYPE1 driver to notify vendor drivers >>> about DMA_UNMAP. >>> Expo

Re: [PATCH v10 10/19] vfio iommu: Add blocking notifier to notify DMA_UNMAP

2016-10-31 Thread Jike Song
On 10/31/2016 01:59 PM, Kirti Wankhede wrote: > On 10/31/2016 9:20 AM, Jike Song wrote: >> On 10/27/2016 05:29 AM, Kirti Wankhede wrote: >>> Added blocking notifier to IOMMU TYPE1 driver to notify vendor drivers >>> about DMA_UNMAP. >>> Expo

Re: [PATCH v10 10/19] vfio iommu: Add blocking notifier to notify DMA_UNMAP

2016-10-30 Thread Jike Song
On 10/27/2016 05:29 AM, Kirti Wankhede wrote: > Added blocking notifier to IOMMU TYPE1 driver to notify vendor drivers > about DMA_UNMAP. > Exported two APIs vfio_register_notifier() and vfio_unregister_notifier(). > Vendor driver should register notifer using these APIs. > Vendor driver should

Re: [PATCH v10 10/19] vfio iommu: Add blocking notifier to notify DMA_UNMAP

2016-10-30 Thread Jike Song
On 10/27/2016 05:29 AM, Kirti Wankhede wrote: > Added blocking notifier to IOMMU TYPE1 driver to notify vendor drivers > about DMA_UNMAP. > Exported two APIs vfio_register_notifier() and vfio_unregister_notifier(). > Vendor driver should register notifer using these APIs. > Vendor driver should

Re: [PATCH v10 01/19] vfio: Mediated device Core driver

2016-10-29 Thread Jike Song
On 10/29/2016 06:06 PM, Kirti Wankhede wrote: > > > On 10/29/2016 10:00 AM, Jike Song wrote: >> On 10/27/2016 05:29 AM, Kirti Wankhede wrote: >>> +int mdev_register_device(struct device *dev, const struct parent_ops *ops) >>> +{ >>> + int

  1   2   >