Re: [patch 10/11] x86/vdso: Move cycle_last handling into the caller

2018-09-14 Thread Vitaly Kuznetsov
Thomas Gleixner writes: > Dereferencing gtod->cycle_last all over the place and foing the cycles < > last comparison in the vclock read functions generates horrible code. Doing > it at the call site is much better and gains a few cycles both for TSC and > pvclock. > > Caveat: This adds the compar

Re: [patch 02/11] x86/time: Implement clocksource_arch_init()

2018-09-14 Thread Vitaly Kuznetsov
Thomas Gleixner writes: > Runtime validate the VCLOCK_MODE in clocksource::archdata and disable > VCLOCK if invalid, which disables the VDSO but keeps the system running. > > Signed-off-by: Thomas Gleixner > --- > arch/x86/Kconfig |1 + > arch/x86/kernel/time.c | 16

Re: [patch 00/11] x86/vdso: Cleanups, simmplifications and CLOCK_TAI support

2018-10-03 Thread Vitaly Kuznetsov
Andy Lutomirski writes: > Hi Vitaly, Paolo, Radim, etc., > > On Fri, Sep 14, 2018 at 5:52 AM Thomas Gleixner wrote: >> >> Matt attempted to add CLOCK_TAI support to the VDSO clock_gettime() >> implementation, which extended the clockid switch case and added yet >> another slightly different copy

Re: [patch 00/11] x86/vdso: Cleanups, simmplifications and CLOCK_TAI support

2018-10-03 Thread Vitaly Kuznetsov
Andy Lutomirski writes: >> On Oct 3, 2018, at 2:22 AM, Vitaly Kuznetsov wrote: >> >> Andy Lutomirski writes: >> >>> Hi Vitaly, Paolo, Radim, etc., >>> >> The notification you're talking about exists, it is called >>

Re: [PATCH 02/16] hv_balloon: Replace spin_is_locked() with lockdep

2018-10-03 Thread Vitaly Kuznetsov
!spin_is_locked(&dm_device.ha_lock)); > + lockdep_assert_held(&dm_device.ha_lock); > dm_device.num_pages_onlined++; > } Reviewed-by: Vitaly Kuznetsov However, lockdep_assert_held() is a no-op when !CONFIG_LOCKDEP but this doesn't really matter: hv_page_online_one() is stati

Re: [PATCH RFC] mm/memory_hotplug: Introduce memory block types

2018-10-03 Thread Vitaly Kuznetsov
David Hildenbrand writes: > On 02/10/2018 15:47, Michal Hocko wrote: ... >> >> Why do you need a generic hotplug rule in the first place? Why don't you >> simply provide different set of rules for different usecases? Let users >> decide which usecase they prefer rather than try to be clever whic

Re: [PATCH RFC] mm/memory_hotplug: Introduce memory block types

2018-10-03 Thread Vitaly Kuznetsov
Michal Hocko writes: > On Wed 03-10-18 15:38:04, Vitaly Kuznetsov wrote: >> David Hildenbrand writes: >> >> > On 02/10/2018 15:47, Michal Hocko wrote: >> ... >> >> >> >> Why do you need a generic hotplug rule in the first place? Why don

Re: [PATCH RFC] mm/memory_hotplug: Introduce memory block types

2018-10-03 Thread Vitaly Kuznetsov
Dave Hansen writes: > On 10/03/2018 06:52 AM, Vitaly Kuznetsov wrote: >> It is more than just memmaps (e.g. forking udev process doing memory >> onlining also needs memory) but yes, the main idea is to make the >> onlining synchronous with hotplug. > > That's a g

Re: [patch 00/11] x86/vdso: Cleanups, simmplifications and CLOCK_TAI support

2018-10-04 Thread Vitaly Kuznetsov
Marcelo Tosatti writes: > On Wed, Oct 03, 2018 at 11:22:58AM +0200, Vitaly Kuznetsov wrote: >> >> There is a very long history of different (hardware) issues Marcelo was >> fighting with and the current code is the survived Frankenstein. > > Right, the code has to

Re: [patch 00/11] x86/vdso: Cleanups, simmplifications and CLOCK_TAI support

2018-10-04 Thread Vitaly Kuznetsov
Andy Lutomirski writes: > On Thu, Oct 4, 2018 at 9:43 AM Marcelo Tosatti wrote: >> >> On Wed, Oct 03, 2018 at 03:32:08PM -0700, Andy Lutomirski wrote: >> > On Wed, Oct 3, 2018 at 12:01 PM Marcelo Tosatti >> > wrote: >> > > >> > > On Tue, Oct 02, 2018 at 10:15:49PM -0700, Andy Lutomirski wrote:

RE: [PATCH net-next] hv_netvsc: fix vf serial matching with pci slot info

2018-10-11 Thread Vitaly Kuznetsov
t's kobj name, >> not >> the slot->number. This patch corrects the netvsc driver, so the VF device >> can be >> successfully paired with synthetic NIC. >> >> Fixes: 00d7ddba1143 ("hv_netvsc: pair VF based on serial number") >> S

Re: [PATCH 1/4] arm64: hyperv: Add core Hyper-V include files

2018-12-10 Thread Vitaly Kuznetsov
k...@linuxonhyperv.com writes: > + > +static inline u64 hv_read_tsc_page_tsc(const struct ms_hyperv_tsc_page > *tsc_pg, > +u64 *cur_tsc) > +{ > + u64 scale, offset; > + u32 sequence; > + > + /* > + * The protocol for reading Hyper-V TSC

[PATCH] hv_balloon: avoid touching uninitialized struct page during tail onlining

2019-01-04 Thread Vitaly Kuznetsov
ds inspecting struct pages and checks sections instead. But in Hyper-V balloon driver we do PageReserved(pfn_to_page()) check and this is now wrong. Switch to checking online_section_nr() instead. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/hv_balloon.c | 10 ++ 1 file changed

Re: [PATCH] hv_balloon: avoid touching uninitialized struct page during tail onlining

2019-01-07 Thread Vitaly Kuznetsov
David Hildenbrand writes: > On 04.01.19 15:19, Vitaly Kuznetsov wrote: >> Hyper-V memory hotplug protocol has 2M granularity and in Linux x86 we use >> 128M. To deal with it we implement partial section onlining by registering >> custom page onlining callback (hv_online_page

Re: [PATCH] hv_balloon: avoid touching uninitialized struct page during tail onlining

2019-01-07 Thread Vitaly Kuznetsov
Sasha Levin writes: > On Mon, Jan 07, 2019 at 02:44:30PM +0100, Vitaly Kuznetsov wrote: >>P.S. I still think about bringing mem_hotplug_begin()/done() to >>hv_balloon but that's going to be a separate discussion, here I want to >>have a small fix backportable to stable

Re: [PATCH] hv_balloon: avoid touching uninitialized struct page during tail onlining

2019-01-08 Thread Vitaly Kuznetsov
David Hildenbrand writes: > On 07.01.19 14:44, Vitaly Kuznetsov wrote: >> David Hildenbrand writes: >> ... >>> On 04.01.19 15:19, Vitaly Kuznetsov wrote: >>>>if (start_pfn > has->start_pfn && >>>>

Re: [PATCH] hv_balloon: avoid touching uninitialized struct page during tail onlining

2019-01-08 Thread Vitaly Kuznetsov
Dan Carpenter writes: > On Mon, Jan 07, 2019 at 07:38:20PM +0100, Vitaly Kuznetsov wrote: >> (I remember Greg disliked when people were tagging patches for stable@ >> themselves, he prefered maintainers deciding if the particular commit >> deserves stable@ or not - but as y

Re: [PATCH 1/2] PCI: hv: Replace hv_vp_set with hv_vpset

2019-01-24 Thread Vitaly Kuznetsov
Maya Nakamura writes: > Remove a duplicate definition of VP set (hv_vp_set) and use the common > definition (hv_vpset) that is used in other places. > > Signed-off-by: Maya Nakamura > --- > drivers/pci/controller/pci-hyperv.c | 25 - > 1 file changed, 12 insertions(+), 1

Re: [RFC PATCH] x86, hyperv: fix kernel panic when kexec on HyperV VM

2019-02-26 Thread Vitaly Kuznetsov
Kairui Song writes: > When hypercalls is used for sending IPIs, kexec will fail with a kernel > panic like this: > > kexec_core: Starting new kernel > BUG: unable to handle kernel NULL pointer dereference at > PGD 800057995067 P4D 800057995067 PUD 57990067 PMD 0 > Oops: 0

Re: [PATCH v3 2/2] PCI: hv: Refactor hv_irq_unmask() to use cpumask_to_vpset()

2019-02-27 Thread Vitaly Kuznetsov
Maya Nakamura writes: > Remove the duplicate implementation of cpumask_to_vpset() and use the > shared implementation. Export hv_max_vp_index, which is required by > cpumask_to_vpset(). > > Apply changes to hv_irq_unmask() based on feedback. > I just noticed an issue with this patch, sorry I've

Re: [PATCH v3 1/2] PCI: hv: Replace hv_vp_set with hv_vpset

2019-02-27 Thread Vitaly Kuznetsov
Maya Nakamura writes: > Remove a duplicate definition of VP set (hv_vp_set) and use the common > definition (hv_vpset) that is used in other places. > > Change the order of the members in struct hv_pcibus_device so that the > declaration of retarget_msi_interrupt_params is the last member. Struct

Re: general protection fault in __apic_accept_irq

2019-09-05 Thread Vitaly Kuznetsov
(/home/glider/llvm/clang >> 80fee25776c2fb61e74c1ecb1a523375c2500b69) >> syz repro: https://syzkaller.appspot.com/x/repro.syz?x=1095467660 >> C reproducer: https://syzkaller.appspot.com/x/repro.c?x=1752fe0a600000 >> >> The bug was bisected to: >> >

[PATCH 0/2] Drivers: hv: kvp, vss: improve kernel-userspace communication in failure case

2014-11-06 Thread Vitaly Kuznetsov
discussing. In theory freeze/thaw ioctls should be fast. In case someone thinks 10 seconds is not enough we can easily increase it as we cover the most common failure scenario (when the daemon was stopped) with the second patch of this series. Vitaly Kuznetsov (2): Drivers: hv: vss: Introduce

[PATCH 2/2] Drivers: hv: kvp, vss: Fast propagation of userspace communication failure

2014-11-06 Thread Vitaly Kuznetsov
case userspace daemon gets disconnected so we won't receive new requests. But I'm not sure it is possible. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/hv_kvp.c | 9 - drivers/hv/hv_snapshot.c | 8 +++- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/driv

[PATCH 1/2] Drivers: hv: vss: Introduce timeout for communication with userspace

2014-11-06 Thread Vitaly Kuznetsov
schedule_delayed_work(). Signed-off-by: Vitaly Kuznetsov --- drivers/hv/hv_snapshot.c | 20 ++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/drivers/hv/hv_snapshot.c b/drivers/hv/hv_snapshot.c index 34f14fd..21e51be 100644 --- a/drivers/hv/hv_snapshot.c +++ b/drivers/hv

[PATCH 0/3] Tools: hv: vssdaemon: freeze/thaw logic improvement for the failure case

2014-11-07 Thread Vitaly Kuznetsov
This patch series addresses the following issues: - Wrong error reporting for multiple filesystems case. - Skip all readonly-mounted filesystems instead of skipping iso9660. - Thaw all filesystems after an unsuccessful freeze attempt. Vitaly Kuznetsov (3): Tools: hv: vssdaemon: consult with

[PATCH 2/3] Tools: hv: vssdaemon: skip all filesystems mounted readonly

2014-11-07 Thread Vitaly Kuznetsov
Instead of making a list of exceptions for readonly filesystems in addition to iso9660 we already have it is better to skip freeze operation for all readonly-mounted filesystems. Signed-off-by: Vitaly Kuznetsov --- tools/hv/hv_vss_daemon.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion

[PATCH 3/3] Tools: hv: vssdaemon: thaw everything in case of freeze failure

2014-11-07 Thread Vitaly Kuznetsov
doing freeze/thaw requests at the same time they will collide with vss daemon. This issue can be addressed by introducing a freeze/thaw transaction and keeping track of what was actually frozen Signed-off-by: Vitaly Kuznetsov --- tools/hv/hv_vss_daemon.c | 6 ++ 1 file changed, 6 insertions(+)

[PATCH 1/3] Tools: hv: vssdaemon: consult with errno in case of failure only

2014-11-07 Thread Vitaly Kuznetsov
Hyper-V VSS: VSS: freeze of /: Operation not supported We should also log errors with LOG_ERR instead of LOG_INFO. Signed-off-by: Vitaly Kuznetsov --- tools/hv/hv_vss_daemon.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tools/hv/hv_vss_daemon.c b/tools/hv

Re: [PATCH 0/3] Tools: hv: vssdaemon: freeze/thaw logic improvement for the failure case

2014-11-10 Thread Vitaly Kuznetsov
Dexuan Cui writes: >> -Original Message- >> From: Vitaly Kuznetsov [mailto:vkuzn...@redhat.com] >> Sent: Saturday, November 8, 2014 1:09 AM >> To: KY Srinivasan; Haiyang Zhang; Greg Kroah-Hartman >> Cc: de...@linuxdriverproject.org; linux-ker...@vger.ker

[PATCH v2 0/2] Tools: hv: vssdaemon: freeze/thaw logic improvement for the failure case

2014-11-10 Thread Vitaly Kuznetsov
hing in case of freeze" was thrown away as Dexuan's "Tools: hv: vssdaemon: ignore the EBUSY on multiple freezing the same partition" contains the same change; - "Tools: hv: vssdaemon: consult with errno in case of failure only" was replaced with "To

[PATCH v2 2/2] Tools: hv: vssdaemon: skip all filesystems mounted readonly

2014-11-10 Thread Vitaly Kuznetsov
Instead of making a list of exceptions for readonly filesystems in addition to iso9660 we already have it is better to skip freeze operation for all readonly-mounted filesystems. Signed-off-by: Vitaly Kuznetsov --- tools/hv/hv_vss_daemon.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion

[PATCH v2 1/2] Tools: hv: vssdaemon: report freeze errors

2014-11-10 Thread Vitaly Kuznetsov
during freezing of '/' as it usually results in SEGSEGV. Signed-off-by: Vitaly Kuznetsov --- tools/hv/hv_vss_daemon.c | 16 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/tools/hv/hv_vss_daemon.c b/tools/hv/hv_vss_daemon.c index b720d8f..ee44f0d 100644 ---

Re: [PATCH] hv: hv_fcopy: drop the obsolete message on transfer failure

2014-11-12 Thread Vitaly Kuznetsov
: K. Y. Srinivasan > Signed-off-by: Dexuan Cui Reviewed-by: Vitaly Kuznetsov > --- > drivers/hv/hv_fcopy.c | 9 + > 1 file changed, 9 insertions(+) > > diff --git a/drivers/hv/hv_fcopy.c b/drivers/hv/hv_fcopy.c > index 23b2ce2..177122a 100644 > --- a/drivers/h

Re: [PATCH] tools: hv: ignore ENOBUFS in the KVP daemon

2014-11-19 Thread Vitaly Kuznetsov
Dexuan Cui writes: > Under high memory pressure and very high KVP R/W test pressure, the netlink > recvfrom() may transiently return ENOBUFS to the daemon -- we found this > during a 2-week stress test. > > We'd better not terminate the daemon on this failure, because a typical KVP > user can re-

Re: [PATCH] tools: hv: ignore ENOBUFS in the KVP daemon

2014-11-19 Thread Vitaly Kuznetsov
Dexuan Cui writes: >> -Original Message- >> From: Vitaly Kuznetsov >> Sent: Wednesday, November 19, 2014 18:50 PM >> To: Dexuan Cui >> Cc: gre...@linuxfoundation.org; linux-ker...@vger.kernel.org; driverdev- >> de...@linuxdriverproject.org; o...@aep

Re: [PATCH] tools: hv: ignore ENOBUFS in the KVP daemon

2014-11-19 Thread Vitaly Kuznetsov
Dexuan Cui writes: >> -Original Message- >> From: Vitaly Kuznetsov [mailto:vkuzn...@redhat.com] >> Sent: Wednesday, November 19, 2014 20:41 PM >> To: Dexuan Cui >> Cc: gre...@linuxfoundation.org; linux-ker...@vger.kernel.org; driverdev- >> de...@linux

Re: [PATCH] tools: hv: ignore ENOBUFS in the KVP daemon

2014-11-19 Thread Vitaly Kuznetsov
Dexuan Cui writes: >> -Original Message- >> From: Vitaly Kuznetsov >> >> -- >> >> Vitaly >> > >> > OK, I can add this new check: >> > (I'll send out the v2 tomorrow in case people have new comments) >> &g

Re: [PATCH v2] tools: hv: ignore ENOBUFS and ENOMEM in the KVP daemon

2014-11-20 Thread Vitaly Kuznetsov
l KVP > user will re-try the R/W and hopefully it will succeed next time. > > We can also ignore the errors on sending. > > Cc: Vitaly Kuznetsov > Cc: K. Y. Srinivasan > Signed-off-by: Dexuan Cui > --- > > v2: I also ignore the errors on sending, as Vitaly

[PATCH] Drivers: hv: vmbus: prevent cpu offlining on newer hypervisors

2014-11-26 Thread Vitaly Kuznetsov
on resume). Suspend still works. Tested with WS2008R2 and WS2012R2. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/vmbus_drv.c | 19 +++ 1 file changed, 19 insertions(+) diff --git a/drivers/hv/vmbus_drv.c b/drivers/hv/vmbus_drv.c index 4d6b269..9a82249 100644 --- a/drivers

Re: [PATCH] Drivers: hv: vmbus: prevent cpu offlining on newer hypervisors

2014-11-27 Thread Vitaly Kuznetsov
Dexuan Cui writes: >> -Original Message- >> From: devel [mailto:driverdev-devel-boun...@linuxdriverproject.org] On >> Behalf Of Greg Kroah-Hartman >> Sent: Thursday, November 27, 2014 11:03 AM >> To: Vitaly Kuznetsov >> Cc: de...@linuxdriverproje

Re: [PATCH v3] hv: hv_fcopy: drop the obsolete message on transfer failure

2014-12-01 Thread Vitaly Kuznetsov
vkuzn...@redhat.com; Haiyang Zhang >> >> >> Subject: Re: [PATCH v3] hv: hv_fcopy: drop the obsolete message >> >> on >> >> >> transfer >> >> >> failure >> >> >> On Thu, Nov 27, 2014 at 9:09 PM, D

[PATCH v2] Drivers: hv: vmbus: prevent cpu offlining on newer hypervisors

2014-12-01 Thread Vitaly Kuznetsov
on resume). Suspend still works. Tested with WS2008R2 and WS2012R2. Signed-off-by: Vitaly Kuznetsov --- Changes since v1: - introduce hv_cpu_hotplug_quirk() function to not spread #ifdefs [Greg KH] - add pr_notice() message "hv_vmbus: CPU offlining is not supported by hypervisor" --

Re: [PATCH] tools: hv: kvp_daemon: make IPv6-only-injection work

2014-12-09 Thread Vitaly Kuznetsov
Dexuan Cui writes: > Currently IPv6-only-injection doesn't work because the daemon doesn't parse > any IPv6 information at all once it finds the dhcp_enabled flag is true. > > But according to the Hyper-v host team, the flag is only for IPv4. > In the case the host only injects 1 IPv6 address, th

[PATCH 0/5] Tools: hv: fix compiler warnings and do minor cleanup

2014-12-09 Thread Vitaly Kuznetsov
' in hv_start_fcopy()" Vitaly Kuznetsov (5): Tools: hv: add mising fcopyd to the Makefile Tools: hv: remove unused bytes_written from kvp_update_file() Tools: hv: address compiler warnings for hv_kvp_daemon.c Tools: hv: address compiler warnings for hv_fcopy_daemon.c Tools: h

[PATCH 2/5] Tools: hv: remove unused bytes_written from kvp_update_file()

2014-12-09 Thread Vitaly Kuznetsov
’ set but not used [-Wunused-but-set-variable] Remove bytes_written completely. Signed-off-by: Vitaly Kuznetsov --- tools/hv/hv_kvp_daemon.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/tools/hv/hv_kvp_daemon.c b/tools/hv/hv_kvp_daemon.c index 6a6432a..5a274ca 100644

[PATCH 1/5] Tools: hv: add mising fcopyd to the Makefile

2014-12-09 Thread Vitaly Kuznetsov
fcopyd in missing in the Makefile, add it there. Signed-off-by: Vitaly Kuznetsov --- tools/hv/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/hv/Makefile b/tools/hv/Makefile index bd22f78..99ffe61 100644 --- a/tools/hv/Makefile +++ b/tools/hv/Makefile

[PATCH 3/5] Tools: hv: address compiler warnings for hv_kvp_daemon.c

2014-12-09 Thread Vitaly Kuznetsov
This patch addresses two types of compiler warnings: ... warning: comparison between signed and unsigned integer expressions [-Wsign-compare] and ... warning: pointer targets in passing argument N of ‘kvp_...’ differ in signedness [-Wpointer-sign] Signed-off-by: Vitaly Kuznetsov --- tools/hv

[PATCH 5/5] Tools: hv: do not add redundant '/' in hv_start_fcopy()

2014-12-09 Thread Vitaly Kuznetsov
We don't need to add additional '/' to smsg->path_name as snprintf("%s/%s") does the right thing. Without the patch we get doubled '//' in the log message. Signed-off-by: Vitaly Kuznetsov --- tools/hv/hv_fcopy_daemon.c | 6 -- 1 file changed,

[PATCH 4/5] Tools: hv: address compiler warnings for hv_fcopy_daemon.c

2014-12-09 Thread Vitaly Kuznetsov
This patch addresses two types of compiler warnings: ... warning: unused variable ‘fd’ [-Wunused-variable] and ... warning: format ‘%s’ expects argument of type ‘char *’, but argument 5 has type ‘__u16 *’ [-Wformat=] Signed-off-by: Vitaly Kuznetsov --- tools/hv/hv_fcopy_daemon.c | 4 ++-- 1

Re: [PATCH] tools: hv: kvp_daemon: make IPv6-only-injection work

2014-12-10 Thread Vitaly Kuznetsov
Dexuan Cui writes: > Thanks, > -- Dexuan > >> -Original Message- >> From: Dexuan Cui >> Sent: Wednesday, December 10, 2014 15:34 PM >> To: 'Vitaly Kuznetsov' >> Cc: gre...@linuxfoundation.org; linux-ker...@vger.kernel.org; driverdev- &

Re: [PATCH 0/5] Tools: hv: fix compiler warnings and do minor cleanup

2014-12-10 Thread Vitaly Kuznetsov
Dexuan Cui writes: >> -Original Message- >> From: Vitaly Kuznetsov [mailto:vkuzn...@redhat.com] >> Sent: Tuesday, December 9, 2014 23:48 PM >> To: KY Srinivasan >> Cc: Haiyang Zhang; de...@linuxdriverproject.org; linux- >> ker...@vger.kernel.org; Dexu

Re: [PATCH] tools: hv: kvp_daemon: make IPv6-only-injection work

2014-12-10 Thread Vitaly Kuznetsov
Dexuan Cui writes: >> -Original Message- >> From: Vitaly Kuznetsov [mailto:vkuzn...@redhat.com] >> Sent: Tuesday, December 9, 2014 21:06 PM >> To: Dexuan Cui >> Cc: gre...@linuxfoundation.org; linux-ker...@vger.kernel.org; driverdev- >> de...@linux

Re: [PATCH v2] tools: hv: kvp_daemon: make IPv6-only-injection work

2015-01-02 Thread Vitaly Kuznetsov
jects an IPv6 address, the dhcp_enabled flag is >> true (it's only for IPv4 according to Hyper-V host team), but we still need >> to >> proceed to parse the IPv6 information. >> >> Cc: Vitaly Kuznetsov >> Cc: K. Y. Srinivasan >> Signed-off-by: Dexu

Re: [PATCH 0/5] Tools: hv: fix compiler warnings and do minor cleanup

2015-01-08 Thread Vitaly Kuznetsov
KY Srinivasan writes: >> -Original Message- >> From: devel [mailto:driverdev-devel-boun...@linuxdriverproject.org] On >> Behalf Of gre...@linuxfoundation.org >> Sent: Wednesday, December 10, 2014 6:48 AM >> To: Vitaly Kuznetsov >> Cc: de...@linuxdri

[PATCH v3] Drivers: hv: vmbus: prevent cpu offlining on newer hypervisors

2015-01-12 Thread Vitaly Kuznetsov
on resume). Suspend still works. Tested with WS2008R2 and WS2012R2. Signed-off-by: Vitaly Kuznetsov --- Changes since v2: - repair the build when vmbus is builded as a module [Greg KH] by saving current cpu_disable pointer to previous_cpu_disable and restoring it on unload; - return -ENO

Re: [PATCH v3] hv: hv_fcopy: drop the obsolete message on transfer failure

2015-01-13 Thread Vitaly Kuznetsov
is patch got lost and I don't see it in recent 'resend' series. K.Y., Dexuan, can you please take a look? > > Cc: Jason Wang > Cc: Vitaly Kuznetsov > Cc: K. Y. Srinivasan > Signed-off-by: Dexuan Cui > --- > > v2: I removed the "FCP" prefix as G

[PATCH] Drivers: hv: vmbus: serialize Offer and Rescind offer processing

2015-01-16 Thread Vitaly Kuznetsov
if kzalloc() fails. Reported-by: Jason Wang Suggested-by: Radim Krčmář Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel_mgmt.c | 33 +++-- 1 file changed, 23 insertions(+), 10 deletions(-) diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c index 2

Re: [PATCH] x86/hyperv: Disable preemption while setting reenlightenment vector

2019-06-12 Thread Vitaly Kuznetsov
; Cc: "K. Y. Srinivasan" > Cc: "Michael Kelley (EOSG)" > Cc: Mohammed Gamal > Cc: Paolo Bonzini > Cc: Radim Krčmář > Cc: Roman Kagan > Cc: Sasha Levin > Cc: Stephen Hemminger > Cc: Thomas Gleixner > Cc: Vitaly Kuznetsov > > Cc: de...@linuxd

Re: [PATCH] x86/hyperv: Disable preemption while setting reenlightenment vector

2019-06-12 Thread Vitaly Kuznetsov
gt; Cc: Cathy Avery >> Cc: Haiyang Zhang >> Cc: "H. Peter Anvin" >> Cc: Ingo Molnar >> Cc: "K. Y. Srinivasan" >> Cc: "Michael Kelley (EOSG)" >> Cc: Mohammed Gamal >> Cc: Paolo Bonzini >> Cc: Radim Krčmář >>

Re: [PATCH] x86/hyperv: Disable preemption while setting reenlightenment vector

2019-06-14 Thread Vitaly Kuznetsov
Thomas Gleixner writes: > On Wed, 12 Jun 2019, Vitaly Kuznetsov wrote: >> Dmitry Safonov writes: >> > diff --git a/arch/x86/hyperv/hv_init.c b/arch/x86/hyperv/hv_init.c >> > index 1608050e9df9..0bdd79ecbff8 100644 >> > --- a/arch/x86/hyperv/hv_init.c

Re: [PATCH] x86/hyperv: Disable preemption while setting reenlightenment vector

2019-06-14 Thread Vitaly Kuznetsov
Peter Zijlstra writes: > @@ -182,7 +182,7 @@ void set_hv_tscchange_cb(void (*cb)(void)) > struct hv_reenlightenment_control re_ctrl = { > .vector = HYPERV_REENLIGHTENMENT_VECTOR, > .enabled = 1, > - .target_vp = hv_vp_index[smp_processor_id()] > +

Re: [PATCH] x86/hyperv: Disable preemption while setting reenlightenment vector

2019-06-14 Thread Vitaly Kuznetsov
Dmitry Safonov writes: > On 6/14/19 11:08 AM, Vitaly Kuznetsov wrote: >> Peter Zijlstra writes: >> >>> @@ -182,7 +182,7 @@ void set_hv_tscchange_cb(void (*cb)(void)) >>> struct hv_reenlightenment_control re_ctrl = { >>>

Re: [PATCH] x86/hyperv: Disable preemption while setting reenlightenment vector

2019-06-14 Thread Vitaly Kuznetsov
Peter Zijlstra writes: > > I know you probably can't change the HV interface, but I'm thinking its > rather daft you have to specify a CPU at all for this. The HV can just > pick one and send the notification there, who cares. Generally speaking, hypervisor can't know if the CPU is offline (or e

[PATCH] x86/hyper-v: Remove doubled HV_X64_EX_PROCESSOR_MASKS_RECOMMENDED definition

2017-09-11 Thread Vitaly Kuznetsov
Commit 7dcf90e9e032 ("PCI: hv: Use vPCI protocol version 1.2") and commit 628f54cc6451 ("x86/hyper-v: Support extended CPU ranges for TLB flush hypercalls") adding the same definition came through different trees. Fix the glitch. Signed-off-by: Vitaly Kuznetsov --- arch/

Re: [PATCH 1/1] Drivers: hv: vmbus: Fix rescind handling issues

2017-09-15 Thread Vitaly Kuznetsov
Stephen Hemminger writes: > On Fri, 11 Aug 2017 10:03:59 -0700 > k...@exchange.microsoft.com wrote: > >> From: K. Y. Srinivasan >> >> This patch handles the following issues that were observed when we are >> handling racing channel offer message and rescind message for the same >> offer: >> >>

Re: [PATCH 1/1] Drivers: hv: vmbus: Fix rescind handling issues

2017-09-15 Thread Vitaly Kuznetsov
Vitaly Kuznetsov writes: > Stephen Hemminger writes: > >> On Fri, 11 Aug 2017 10:03:59 -0700 >> k...@exchange.microsoft.com wrote: >> >>> From: K. Y. Srinivasan >>> >>> This patch handles the following issues that were observed when we are &g

Re: [PATCH 1/1] Drivers: hv: vmbus: Fix rescind handling issues

2017-09-18 Thread Vitaly Kuznetsov
Stephen Hemminger writes: > On Sep 15, 2017 11:01 AM, "KY Srinivasan" wrote: > > > Vitaly Kuznetsov writes: > > > > > > > > I'm seeing the same issue, reverting the offending > > > > > > commit 6f3d791f300618caf82a2be0c

Re: [PATCH 1/1] Drivers: hv: vmbus: Fix rescind handling issues

2017-09-18 Thread Vitaly Kuznetsov
Vitaly Kuznetsov writes: > > Reverting 6f3d791f300618caf82a2be0c27456edd76d5164 still helps. In addition to the above I got the following crash while playing with 4.14-rc1 (unmodified): [ 55.810080] kernel tried to execute NX-protected page - exploit attempt? (uid: 0) [ 55.81429

[PATCH 02/16] hyper-v: trace vmbus_on_message()

2017-09-20 Thread Vitaly Kuznetsov
Add tracepoint to vmbus_on_message() which is called when we start processing a blocking from work context. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel_mgmt.c | 2 ++ drivers/hv/hv_trace.h | 8 2 files changed, 10 insertions(+) diff --git a/drivers/hv/channel_mgmt.c b

[PATCH 00/16] Hyper-V: add tracing to VMBus module and trace all messages

2017-09-20 Thread Vitaly Kuznetsov
.. 465.932709: vmbus_close_internal: sending child_relid 0x10, ret 0 kworker/5:4-2535 [005] 465.986417: vmbus_release_relid: sending child_relid 0x10, ret 0 CHANNELMSG_UNLOAD/CHANNELMSG_UNLOAD_RESPONSE are not traced as these are mostly used on crash. Vitaly Kuznetsov (16): hyper-v: trace v

[PATCH 01/16] hyper-v: trace vmbus_on_msg_dpc()

2017-09-20 Thread Vitaly Kuznetsov
Add tracing subsystem to Hyper-V VMBus module and add tracepoint to vmbus_on_msg_dpc() which is called when we receive a message from host. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/Makefile | 4 +++- drivers/hv/hv_trace.c | 4 drivers/hv/hv_trace.h | 24

[PATCH 03/16] hyper-v: trace vmbus_onoffer()

2017-09-20 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_OFFERCHANNEL handler. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel_mgmt.c | 2 ++ drivers/hv/hv_trace.h | 37 + 2 files changed, 39 insertions(+) diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c

[PATCH 07/16] hyper-v: trace vmbus_ongpadl_torndown()

2017-09-20 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_GPADL_TORNDOWN handler. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel_mgmt.c | 2 ++ drivers/hv/hv_trace.h | 8 2 files changed, 10 insertions(+) diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c index af2448e245ca

[PATCH 06/16] hyper-v: trace vmbus_ongpadl_created()

2017-09-20 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_GPADL_CREATED handler. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel_mgmt.c | 2 ++ drivers/hv/hv_trace.h | 17 + 2 files changed, 19 insertions(+) diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c index 2abe0563876b

[PATCH 05/16] hyper-v: trace vmbus_onopen_result()

2017-09-20 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_OPENCHANNEL_RESULT handler. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel_mgmt.c | 2 ++ drivers/hv/hv_trace.h | 17 + 2 files changed, 19 insertions(+) diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c index

[PATCH 10/16] hyper-v: trace vmbus_open()

2017-09-20 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_OPENCHANNEL sender. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel.c | 2 ++ drivers/hv/hv_trace.h | 27 +++ 2 files changed, 29 insertions(+) diff --git a/drivers/hv/channel.c b/drivers/hv/channel.c index 676a130f0575

[PATCH 09/16] hyper-v: trace vmbus_request_offers()

2017-09-20 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_REQUESTOFFERS sender. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel_mgmt.c | 4 +++- drivers/hv/hv_trace.h | 8 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c index

[PATCH 04/16] hyper-v: trace vmbus_onoffer_rescind()

2017-09-20 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_RESCIND_CHANNELOFFER handler. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel_mgmt.c | 2 ++ drivers/hv/hv_trace.h | 8 2 files changed, 10 insertions(+) diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c index 290ea25ce409

[PATCH 13/16] hyper-v: trace vmbus_teardown_gpadl()

2017-09-20 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_GPADL_TEARDOWN sender. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel.c | 2 ++ drivers/hv/hv_trace.h | 18 ++ 2 files changed, 20 insertions(+) diff --git a/drivers/hv/channel.c b/drivers/hv/channel.c index f51ddc89c85a..2422ef6f9164

[PATCH 15/16] hyper-v: trace vmbus_release_relid()

2017-09-20 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_RELID_RELEASED sender. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel_mgmt.c | 7 +-- drivers/hv/hv_trace.h | 16 2 files changed, 21 insertions(+), 2 deletions(-) diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c

[PATCH 16/16] hyper-v: trace vmbus_send_tl_connect_request()

2017-09-20 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_TL_CONNECT_REQUEST sender. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel.c | 7 ++- drivers/hv/hv_trace.h | 20 2 files changed, 26 insertions(+), 1 deletion(-) diff --git a/drivers/hv/channel.c b/drivers/hv/channel.c index

[PATCH 14/16] hyper-v: trace vmbus_negotiate_version()

2017-09-20 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_INITIATE_CONTACT sender. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/connection.c | 3 +++ drivers/hv/hv_trace.h | 26 ++ 2 files changed, 29 insertions(+) diff --git a/drivers/hv/connection.c b/drivers/hv/connection.c index

[PATCH 08/16] hyper-v: trace vmbus_onversion_response()

2017-09-20 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_VERSION_RESPONSE handler. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel_mgmt.c | 3 +++ drivers/hv/hv_trace.h | 11 +++ 2 files changed, 14 insertions(+) diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c index 1ff2cc064850

[PATCH 11/16] hyper-v: trace vmbus_close_internal()

2017-09-20 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_CLOSECHANNEL sender. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel.c | 2 ++ drivers/hv/hv_trace.h | 15 +++ 2 files changed, 17 insertions(+) diff --git a/drivers/hv/channel.c b/drivers/hv/channel.c index 7b114b390871..9fe4c0624dbd 100644

[PATCH 12/16] hyper-v: trace vmbus_establish_gpadl()

2017-09-20 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_GPADL_HEADER/CHANNELMSG_GPADL_BODY sender. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel.c | 6 ++ drivers/hv/hv_trace.h | 42 ++ 2 files changed, 48 insertions(+) diff --git a/drivers/hv/channel.c b/drivers/hv

Re: [PATCH 02/16] hyper-v: trace vmbus_on_message()

2017-09-21 Thread Vitaly Kuznetsov
Steven Rostedt writes: > On Wed, 20 Sep 2017 19:21:53 +0200 > Vitaly Kuznetsov wrote: > >> diff --git a/drivers/hv/hv_trace.h b/drivers/hv/hv_trace.h >> index 9a29ef55477d..72911dfc9682 100644 >> --- a/drivers/hv/hv_trace.h >> +++ b/drivers/hv/hv_trace.h

[PATCH v2 07/16] hyper-v: trace vmbus_ongpadl_torndown()

2017-09-29 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_GPADL_TORNDOWN handler. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel_mgmt.c | 2 ++ drivers/hv/hv_trace.h | 8 2 files changed, 10 insertions(+) diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c index af2448e245ca

[PATCH v2 00/16] Hyper-V: add tracing to VMBus module and trace all messages

2017-09-29 Thread Vitaly Kuznetsov
ANNELMSG_UNLOAD/CHANNELMSG_UNLOAD_RESPONSE are not traced as these are mostly used on crash. Vitaly Kuznetsov (16): hyper-v: trace vmbus_on_msg_dpc() hyper-v: trace vmbus_on_message() hyper-v: trace vmbus_onoffer() hyper-v: trace vmbus_onoffer_rescind() hyper-v: trace vmbus_onopen_result()

[PATCH v2 02/16] hyper-v: trace vmbus_on_message()

2017-09-29 Thread Vitaly Kuznetsov
Add tracepoint to vmbus_on_message() which is called when we start processing a blocking from work context. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel_mgmt.c | 2 ++ drivers/hv/hv_trace.h | 5 + 2 files changed, 7 insertions(+) diff --git a/drivers/hv/channel_mgmt.c b

[PATCH v2 03/16] hyper-v: trace vmbus_onoffer()

2017-09-29 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_OFFERCHANNEL handler. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel_mgmt.c | 2 ++ drivers/hv/hv_trace.h | 37 + 2 files changed, 39 insertions(+) diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c

[PATCH v2 09/16] hyper-v: trace vmbus_request_offers()

2017-09-29 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_REQUESTOFFERS sender. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel_mgmt.c | 4 +++- drivers/hv/hv_trace.h | 8 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c index

[PATCH v2 13/16] hyper-v: trace vmbus_teardown_gpadl()

2017-09-29 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_GPADL_TEARDOWN sender. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel.c | 2 ++ drivers/hv/hv_trace.h | 18 ++ 2 files changed, 20 insertions(+) diff --git a/drivers/hv/channel.c b/drivers/hv/channel.c index cf6bc0667cde..9cb81838e7bb

[PATCH v2 15/16] hyper-v: trace vmbus_release_relid()

2017-09-29 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_RELID_RELEASED sender. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel_mgmt.c | 7 +-- drivers/hv/hv_trace.h | 16 2 files changed, 21 insertions(+), 2 deletions(-) diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c

[PATCH v2 10/16] hyper-v: trace vmbus_open()

2017-09-29 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_OPENCHANNEL sender. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel.c | 2 ++ drivers/hv/hv_trace.h | 27 +++ 2 files changed, 29 insertions(+) diff --git a/drivers/hv/channel.c b/drivers/hv/channel.c index efd5db743319

[PATCH v2 04/16] hyper-v: trace vmbus_onoffer_rescind()

2017-09-29 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_RESCIND_CHANNELOFFER handler. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel_mgmt.c | 2 ++ drivers/hv/hv_trace.h | 8 2 files changed, 10 insertions(+) diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c index 290ea25ce409

[PATCH v2 08/16] hyper-v: trace vmbus_onversion_response()

2017-09-29 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_VERSION_RESPONSE handler. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel_mgmt.c | 3 +++ drivers/hv/hv_trace.h | 11 +++ 2 files changed, 14 insertions(+) diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c index 1ff2cc064850

[PATCH v2 14/16] hyper-v: trace vmbus_negotiate_version()

2017-09-29 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_INITIATE_CONTACT sender. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/connection.c | 3 +++ drivers/hv/hv_trace.h | 26 ++ 2 files changed, 29 insertions(+) diff --git a/drivers/hv/connection.c b/drivers/hv/connection.c index

[PATCH v2 05/16] hyper-v: trace vmbus_onopen_result()

2017-09-29 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_OPENCHANNEL_RESULT handler. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel_mgmt.c | 2 ++ drivers/hv/hv_trace.h | 17 + 2 files changed, 19 insertions(+) diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c index

[PATCH v2 11/16] hyper-v: trace vmbus_close_internal()

2017-09-29 Thread Vitaly Kuznetsov
Add tracepoint to CHANNELMSG_CLOSECHANNEL sender. Signed-off-by: Vitaly Kuznetsov --- drivers/hv/channel.c | 2 ++ drivers/hv/hv_trace.h | 15 +++ 2 files changed, 17 insertions(+) diff --git a/drivers/hv/channel.c b/drivers/hv/channel.c index 82cb57e2d6bd..f919d9dd984b 100644

  1   2   3   4   5   6   7   8   9   10   >