: 6ea6e84 ("KVM: x86: inject exceptions produced by x86_decode_insn")
Cc: Denis Lunev
Cc: Roman Kagan
Cc: Denis Plotnikov
Signed-off-by: Jan Dakinevich
---
arch/x86/kvm/x86.c | 7 ++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
ind
- do sanity check in caller code
- drop patch, that moved emulation_type() function
Jan Dakinevich (2):
KVM: x86: always stop emulation on page fault
KVM: x86: set ctxt->have_exception in x86_decode_insn()
arch/x86/kvm/emulate.c | 2 ++
arch/x86/kvm/x86.c | 7 ++-
2 files chang
nikov
Signed-off-by: Jan Dakinevich
---
arch/x86/kvm/emulate.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/arch/x86/kvm/emulate.c b/arch/x86/kvm/emulate.c
index bef3c3c..698efb8 100644
--- a/arch/x86/kvm/emulate.c
+++ b/arch/x86/kvm/emulate.c
@@ -5416,6 +5416,8 @@ int x86_decod
queue
- add sanity check for exception value of exception vector
Jan Dakinevich (3):
KVM: x86: always stop emulation on page fault
KVM: x86: make exception_class() and exception_type() globally visible
KVM: x86: set ctxt->have_exception in x86_decode_insn()
arch/x86/kvm/emulate.c | 5 +++
: 6ea6e84 ("KVM: x86: inject exceptions produced by x86_decode_insn")
Cc: Denis Lunev
Cc: Roman Kagan
Cc: Denis Plotnikov
Signed-off-by: Jan Dakinevich
---
arch/x86/kvm/x86.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
ind
exception_type() function was moved for upcoming sanity check in
emulation code. exceptions_class() function is not supposed to be used
right now, but it was moved as well to keep things together.
Cc: Denis Lunev
Cc: Roman Kagan
Cc: Denis Plotnikov
Signed-off-by: Jan Dakinevich
---
arch/x86
nikov
Signed-off-by: Jan Dakinevich
---
arch/x86/kvm/emulate.c | 5 +
1 file changed, 5 insertions(+)
diff --git a/arch/x86/kvm/emulate.c b/arch/x86/kvm/emulate.c
index bef3c3c..74b4d79 100644
--- a/arch/x86/kvm/emulate.c
+++ b/arch/x86/kvm/emulate.c
@@ -5416,6 +5416,11 @@ int x86_decod
On Tue, 27 Aug 2019 07:50:30 -0700
Sean Christopherson wrote:
> +Cc Peng Hao and Yi Wang
>
> On Tue, Aug 27, 2019 at 01:07:09PM +0000, Jan Dakinevich wrote:
> > inject_emulated_exception() returns true if and only if nested page
> > fault happens. However, page fault can
On Tue, 27 Aug 2019 07:53:58 -0700
Sean Christopherson wrote:
> On Tue, Aug 27, 2019 at 01:07:08PM +0000, Jan Dakinevich wrote:
> > x86_emulate_instruction() takes into account ctxt->have_exception flag
> > during instruction decoding, but in practice this
me an advise if it is the correct handling of guest page
fault?
Jan Dakinevich (3):
KVM: x86: fix wrong return code
KVM: x86: set ctxt->have_exception in x86_decode_insn()
KVM: x86: always stop emulation on page fault
arch/x86/kvm/emulate.c | 4 +++-
arch/x86/kvm/x86.c | 4 +++-
2
nikov
Signed-off-by: Jan Dakinevich
---
arch/x86/kvm/emulate.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/arch/x86/kvm/emulate.c b/arch/x86/kvm/emulate.c
index 6170ddf..f93880f 100644
--- a/arch/x86/kvm/emulate.c
+++ b/arch/x86/kvm/emulate.c
@@ -5395,6 +5395,8 @@ int x86_decod
: 6ea6e84 ("KVM: x86: inject exceptions produced by x86_decode_insn")
Cc: Denis Lunev
Cc: Roman Kagan
Cc: Denis Plotnikov
Signed-off-by: Jan Dakinevich
---
arch/x86/kvm/x86.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
ind
are equal to 0) this change makes code more consistent and
it is required for further fixes.
Cc: Denis Lunev
Cc: Roman Kagan
Cc: Denis Plotnikov
Signed-off-by: Jan Dakinevich
---
arch/x86/kvm/emulate.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/x86/kvm/emulate.c b
one() become equal to generic skb_clone()
and can be dropped.
Signed-off-by: Jan Dakinevich
---
include/linux/netlink.h | 16
net/ipv4/fib_frontend.c | 2 +-
net/netfilter/nfnetlink.c | 2 +-
net/netlink/af_netlink.c | 16 +++-
4 files changed, 5 insertions(+),
broadcast messages to be
allocated with vmalloc() as well as unicast.
Jan Dakinevich (3):
skbuff: use kvfree() to deallocate head
netlink: always use vmapped memory for skb data
netlink: use generic skb_set_owner_r()
include/linux/netlink.h | 16
net/core/skbuff.c
If skb buffer was allocated using vmalloc() it will make simple its
further deallocation.
Signed-off-by: Jan Dakinevich
---
net/core/skbuff.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/core/skbuff.c b/net/core/skbuff.c
index 0338820..55eac01 100644
--- a/net/core
Since skb destructor is not used for data deallocating,
netlink_skb_set_owner_r() almost completely repeates generic
skb_set_owner_r(). Thus, both netlink_skb_set_owner_r() and
netlink_skb_destructor() are not required anymore.
Signed-off-by: Jan Dakinevich
---
net/netlink/af_netlink.c | 23
ist of skb (->frag_list) in addition
to paged part for huge datagrams.
Signed-off-by: Jan Dakinevich
---
net/unix/af_unix.c | 38 +++---
1 file changed, 27 insertions(+), 11 deletions(-)
diff --git a/net/unix/af_unix.c b/net/unix/af_unix.c
index 67e87db..0
If skb buffer was allocated using vmalloc() it will make simple its
further deallocation.
Signed-off-by: Jan Dakinevich
---
net/core/skbuff.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/core/skbuff.c b/net/core/skbuff.c
index 0338820..55eac01 100644
--- a/net/core
Since skb destructor is not used for data deallocating,
netlink_skb_set_owner_r() almost completely repeates generic
skb_set_owner_r(). Thus, both netlink_skb_set_owner_r() and
netlink_skb_destructor() are not required anymore.
Signed-off-by: Jan Dakinevich
---
net/netlink/af_netlink.c | 23
one() become equal to generic skb_clone()
and can be dropped.
Signed-off-by: Jan Dakinevich
---
include/linux/netlink.h | 16
net/ipv4/fib_frontend.c | 2 +-
net/netfilter/nfnetlink.c | 2 +-
net/netlink/af_netlink.c | 16 +++-
4 files changed, 5 insertions(+),
broadcast messages to be
allocated with vmalloc() as well as unicast.
Jan Dakinevich (3):
skbuff: use kvfree() to deallocate head
netlink: always use vmapped memory for skb data
netlink: use generic skb_set_owner_r()
include/linux/netlink.h | 16
net/core/skbuff.c
On Tue, 18 Sep 2018 08:46:23 -0600
Jason Gunthorpe wrote:
> On Tue, Sep 18, 2018 at 04:03:42PM +0300, Jan Dakinevich wrote:
> > The size of mlx4_ib_device became too large to be allocated as
> > whole contigous block of memory. Currently it takes about 55K. On
> > arch
On Tue, 18 Sep 2018 08:46:23 -0600
Jason Gunthorpe wrote:
> On Tue, Sep 18, 2018 at 04:03:42PM +0300, Jan Dakinevich wrote:
> > The size of mlx4_ib_device became too large to be allocated as
> > whole contigous block of memory. Currently it takes about 55K. On
> > arch
On Wed, 19 Sep 2018 00:23:51 +0300
Leon Romanovsky wrote:
> On Tue, Sep 18, 2018 at 08:46:23AM -0600, Jason Gunthorpe wrote:
> > On Tue, Sep 18, 2018 at 04:03:42PM +0300, Jan Dakinevich wrote:
> > > The size of mlx4_ib_device became too large to be allocated as
> >
On Wed, 19 Sep 2018 00:23:51 +0300
Leon Romanovsky wrote:
> On Tue, Sep 18, 2018 at 08:46:23AM -0600, Jason Gunthorpe wrote:
> > On Tue, Sep 18, 2018 at 04:03:42PM +0300, Jan Dakinevich wrote:
> > > The size of mlx4_ib_device became too large to be allocated as
> >
This is the 1st patch of 3 of the work for decreasing size
of mlx4_ib_dev.
The field takes about 8K and could be safely allocated with kvzalloc.
Signed-off-by: Jan Dakinevich
---
drivers/infiniband/hw/mlx4/main.c| 65 ++--
drivers/infiniband/hw/mlx4
This is the 1st patch of 3 of the work for decreasing size
of mlx4_ib_dev.
The field takes about 8K and could be safely allocated with kvzalloc.
Signed-off-by: Jan Dakinevich
---
drivers/infiniband/hw/mlx4/main.c| 65 ++--
drivers/infiniband/hw/mlx4
This is the 3rd patch of 3 of the work for decreasing size
of mlx4_ib_dev.
The field takes about 6K and could be safely allocated with kvzalloc.
Signed-off-by: Jan Dakinevich
---
drivers/infiniband/hw/mlx4/alias_GUID.c | 192
drivers/infiniband/hw/mlx4/cm.c
This is the 3rd patch of 3 of the work for decreasing size
of mlx4_ib_dev.
The field takes about 6K and could be safely allocated with kvzalloc.
Signed-off-by: Jan Dakinevich
---
drivers/infiniband/hw/mlx4/alias_GUID.c | 192
drivers/infiniband/hw/mlx4/cm.c
This is the 2nd patch of 3 of the work for decreasing size
of mlx4_ib_dev.
The field takes about 36K and could be safely allocated with kvzalloc.
Signed-off-by: Jan Dakinevich
---
drivers/infiniband/hw/mlx4/mad.c | 18 +-
drivers/infiniband/hw/mlx4/main.c| 11
This is the 2nd patch of 3 of the work for decreasing size
of mlx4_ib_dev.
The field takes about 36K and could be safely allocated with kvzalloc.
Signed-off-by: Jan Dakinevich
---
drivers/infiniband/hw/mlx4/mad.c | 18 +-
drivers/infiniband/hw/mlx4/main.c| 11
foo->part = kvmalloc(65536, GFP_KERNEL);
Signed-off-by: Jan Dakinevich
---
drivers/infiniband/core/device.c | 2 ++
include/rdma/ib_verbs.h | 2 ++
2 files changed, 4 insertions(+)
diff --git a/drivers/infiniband/core/device.c b/drivers/infiniband/core/device.c
index db3b627..a8
foo->part = kvmalloc(65536, GFP_KERNEL);
Signed-off-by: Jan Dakinevich
---
drivers/infiniband/core/device.c | 2 ++
include/rdma/ib_verbs.h | 2 ++
2 files changed, 4 insertions(+)
diff --git a/drivers/infiniband/core/device.c b/drivers/infiniband/core/device.c
index db3b627..a8
kvzalloc
Jan Dakinevich (4):
IB/core: introduce ->release() callback
IB/mlx4: move iboe field aside from mlx4_ib_dev
IB/mlx4: move pkeys field aside from mlx4_ib_dev
IB/mlx4: move sriov field aside from mlx4_ib_dev
drivers/infiniband/core/device.c| 2 +
drivers/infiniband/hw/m
kvzalloc
Jan Dakinevich (4):
IB/core: introduce ->release() callback
IB/mlx4: move iboe field aside from mlx4_ib_dev
IB/mlx4: move pkeys field aside from mlx4_ib_dev
IB/mlx4: move sriov field aside from mlx4_ib_dev
drivers/infiniband/core/device.c| 2 +
drivers/infiniband/hw/m
On Mon, 9 Jul 2018 16:51:03 +0300
Jan Dakinevich wrote:
> This table by default takes 32KiB which is 3rd memory order.
> Meanwhile, this memory is not aimed for DMA operation and could be
> safely allocated by vmalloc.
>
> Signed-off-by: Jan Dakinevich
> ---
> drivers
On Mon, 9 Jul 2018 16:51:03 +0300
Jan Dakinevich wrote:
> This table by default takes 32KiB which is 3rd memory order.
> Meanwhile, this memory is not aimed for DMA operation and could be
> safely allocated by vmalloc.
>
> Signed-off-by: Jan Dakinevich
> ---
> drivers
This table by default takes 32KiB which is 3rd memory order. Meanwhile,
this memory is not aimed for DMA operation and could be safely allocated
by vmalloc.
Signed-off-by: Jan Dakinevich
---
drivers/infiniband/ulp/ipoib/ipoib_main.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions
This table by default takes 32KiB which is 3rd memory order. Meanwhile,
this memory is not aimed for DMA operation and could be safely allocated
by vmalloc.
Signed-off-by: Jan Dakinevich
---
drivers/infiniband/ulp/ipoib/ipoib_main.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions
An array of pointers to SRPT contexts in ib_device is over 30KiB even
in default case, in which an amount of contexts is 4095. The patch
is intended to weed out large contigous allocation for non-DMA memory.
Signed-off-by: Jan Dakinevich
---
drivers/infiniband/ulp/srpt/ib_srpt.c | 6 +++---
1
An array of pointers to SRPT contexts in ib_device is over 30KiB even
in default case, in which an amount of contexts is 4095. The patch
is intended to weed out large contigous allocation for non-DMA memory.
Signed-off-by: Jan Dakinevich
---
drivers/infiniband/ulp/srpt/ib_srpt.c | 6 +++---
1
On Wed, 6 Dec 2017 14:43:01 +0300
Jan Dakinevich <jan.dakinev...@virtuozzo.com> wrote:
> w2k16 essentials fails to boot if underlying hypervisor lacks of
> support for LBR MSRs. To workaround the issue, it suggessted to
> ignore these MSRs (but not all).
>
> The in
On Wed, 6 Dec 2017 14:43:01 +0300
Jan Dakinevich wrote:
> w2k16 essentials fails to boot if underlying hypervisor lacks of
> support for LBR MSRs. To workaround the issue, it suggessted to
> ignore these MSRs (but not all).
>
> The information, which MSRs are supported for sp
to be written, expose PERF_CAPABILITIES too,
> and start/stop them on entry/exit, and enable context switching
> through perf in the host.
>
> That would be far better than creating a frankenstate where LBR is
> there but mostly broken on some KVM versions.
>
> -Andi
--
Best regards
Jan Dakinevich
APABILITIES too,
> and start/stop them on entry/exit, and enable context switching
> through perf in the host.
>
> That would be far better than creating a frankenstate where LBR is
> there but mostly broken on some KVM versions.
>
> -Andi
--
Best regards
Jan Dakinevich
On Wed, 6 Dec 2017 10:06:48 -0500
Konrad Rzeszutek Wilk <konrad.w...@oracle.com> wrote:
> On Wed, Dec 06, 2017 at 02:43:01PM +0300, Jan Dakinevich wrote:
> > w2k16 essentials fails to boot if underlying hypervisor lacks of
> > support for LBR MSRs. To workaround the
On Wed, 6 Dec 2017 10:06:48 -0500
Konrad Rzeszutek Wilk wrote:
> On Wed, Dec 06, 2017 at 02:43:01PM +0300, Jan Dakinevich wrote:
> > w2k16 essentials fails to boot if underlying hypervisor lacks of
> > support for LBR MSRs. To workaround the issue, it suggessted to
> &
patch adds ignoring for
these MSRs to pmu_intel code of KVM.
TODO: use MSR load/store areas to make full support of LBR debug.
Jan Dakinevich (2):
perf/x86/intel: make reusable LBR initialization code
KVM: x86/vPMU: ignore access to LBR-related MSRs
arch/x86/events/core.c| 8
patch adds ignoring for
these MSRs to pmu_intel code of KVM.
TODO: use MSR load/store areas to make full support of LBR debug.
Jan Dakinevich (2):
perf/x86/intel: make reusable LBR initialization code
KVM: x86/vPMU: ignore access to LBR-related MSRs
arch/x86/events/core.c| 8
effect which could affect host system.
* LBR information moved to separate structure `struct x86_pmu_lbr';
* All family-specific tweaks on gathered information are applied only
for global x86_pmu.lbr to keep current perf initialization behavior.
Signed-off-by: Jan Dakinevich <jan.daki
effect which could affect host system.
* LBR information moved to separate structure `struct x86_pmu_lbr';
* All family-specific tweaks on gathered information are applied only
for global x86_pmu.lbr to keep current perf initialization behavior.
Signed-off-by: Jan Dakinevich
---
arch/x86
, and dummy handle them (ignore writes and return
zero on reads).
Signed-off-by: Jan Dakinevich <jan.dakinev...@virtuozzo.com>
---
arch/x86/include/asm/kvm_host.h | 2 ++
arch/x86/kvm/pmu_intel.c| 33 +
2 files changed, 35 insertions(+)
diff --git a/ar
, and dummy handle them (ignore writes and return
zero on reads).
Signed-off-by: Jan Dakinevich
---
arch/x86/include/asm/kvm_host.h | 2 ++
arch/x86/kvm/pmu_intel.c| 33 +
2 files changed, 35 insertions(+)
diff --git a/arch/x86/include/asm/kvm_host.h b/arch
was more welcomed and happened earlier:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=c4baad50297d84bde1a7ad45e50c73adae4a2192
On 03/17/2017 08:09 AM, Greg Kroah-Hartman wrote:
> On Fri, Feb 17, 2017 at 11:42:45PM +0300, Jan Dakinevich wrote:
>> The buffer
was more welcomed and happened earlier:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=c4baad50297d84bde1a7ad45e50c73adae4a2192
On 03/17/2017 08:09 AM, Greg Kroah-Hartman wrote:
> On Fri, Feb 17, 2017 at 11:42:45PM +0300, Jan Dakinevich wrote:
>> The buffer
- return __send_to_port(port, sg, 1, count, (void *)buf, false);
> + data = kmemdup(buf, count, GFP_ATOMIC);
> + if (!data)
> + return -ENOMEM;
> +
> + sg_init_one(sg, data, count);
> + ret = __send_to_port(port, sg, 1, count, data, false);
> + kfree(data);
> + return ret;
> }
>
> /*
>
--
Best regards,
Jan Dakinevich
, sg, 1, count, (void *)buf, false);
> + data = kmemdup(buf, count, GFP_ATOMIC);
> + if (!data)
> + return -ENOMEM;
> +
> + sg_init_one(sg, data, count);
> + ret = __send_to_port(port, sg, 1, count, data, false);
> + kfree(data);
> + return ret;
> }
>
> /*
>
--
Best regards,
Jan Dakinevich
The buffer is used by virtio console driver as DMA buffer. Since v4.9
(if VMAP_STACK is enabled) we shouldn't use the stack for DMA.
Signed-off-by: Jan Dakinevich <jan.dakinev...@gmail.com>
---
drivers/tty/hvc/hvc_console.c | 7 ++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff
The buffer is used by virtio console driver as DMA buffer. Since v4.9
(if VMAP_STACK is enabled) we shouldn't use the stack for DMA.
Signed-off-by: Jan Dakinevich
---
drivers/tty/hvc/hvc_console.c | 7 ++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/drivers/tty/hvc
is already copied to
VMCS12 for L1 hypervisor (see prepare_vmcs12 routine) independently of
feature presence.
Signed-off-by: Jan Dakinevich <jan.dakinev...@gmail.com>
---
v1:
* don't copy to basic_cap bits, which are already copied to size field
* fix commit message
arch/x86/kvm/vmx
is already copied to
VMCS12 for L1 hypervisor (see prepare_vmcs12 routine) independently of
feature presence.
Signed-off-by: Jan Dakinevich
---
v1:
* don't copy to basic_cap bits, which are already copied to size field
* fix commit message
arch/x86/kvm/vmx.c | 9 +
1 file changed, 9
On 09/05/2016 03:49 AM, Wanpeng Li wrote:
> 2016-09-05 2:22 GMT+08:00 Jan Dakinevich <jan.dakinev...@gmail.com>:
>> If EPT support is exposed to L1 hypervisor, guest linear-address field
>> of VMCS should contain GVA of L2, the access to which caused EPT violation.
>
On 09/05/2016 03:49 AM, Wanpeng Li wrote:
> 2016-09-05 2:22 GMT+08:00 Jan Dakinevich :
>> If EPT support is exposed to L1 hypervisor, guest linear-address field
>> of VMCS should contain GVA of L2, the access to which caused EPT violation.
>>
>> Signed-off-by: Jan Daki
If EPT support is exposed to L1 hypervisor, guest linear-address field
of VMCS should contain GVA of L2, the access to which caused EPT violation.
Signed-off-by: Jan Dakinevich <jan.dakinev...@gmail.com>
---
arch/x86/kvm/vmx.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/arch/x
If EPT support is exposed to L1 hypervisor, guest linear-address field
of VMCS should contain GVA of L2, the access to which caused EPT violation.
Signed-off-by: Jan Dakinevich
---
arch/x86/kvm/vmx.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
is already copied to
VMCS12 for L1 hypervisor (see prepare_vmcs12 routine) independently
feature presence.
Signed-off-by: Jan Dakinevich <jan.dakinev...@gmail.com>
---
arch/x86/kvm/vmx.c | 9 +
1 file changed, 9 insertions(+)
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
index a
is already copied to
VMCS12 for L1 hypervisor (see prepare_vmcs12 routine) independently
feature presence.
Signed-off-by: Jan Dakinevich
---
arch/x86/kvm/vmx.c | 9 +
1 file changed, 9 insertions(+)
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
index a4bb2bd..4fd22a6 100644
--- a/arch
68 matches
Mail list logo