From: Dexuan Cui <decui@microsoft.com>
To: vkuznets <vkuznets@redhat.com>,
"linux-hyperv@vger.kernel.org" <linux-hyperv@vger.kernel.org>
Cc: Wei Liu <wei.liu@kernel.org>, "x86@kernel.org" <x86@kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"kvm@vger.kernel.org" <kvm@vger.kernel.org>,
Michael Kelley <mikelley@microsoft.com>,
Tianyu Lan <Tianyu.Lan@microsoft.com>
Subject: RE: [PATCH] x86/hyperv: Properly suspend/resume reenlightenment notifications
Date: Tue, 12 May 2020 21:03:36 +0000 [thread overview]
Message-ID: <HK0P153MB016460EAB0E994FFD0653EB2BFBE0@HK0P153MB0164.APCP153.PROD.OUTLOOK.COM> (raw)
In-Reply-To: <20200512160153.134467-1-vkuznets@redhat.com>
> From: Vitaly Kuznetsov <vkuznets@redhat.com>
> Sent: Tuesday, May 12, 2020 9:02 AM
> To: linux-hyperv@vger.kernel.org
> Cc: Wei Liu <wei.liu@kernel.org>; x86@kernel.org;
> linux-kernel@vger.kernel.org; kvm@vger.kernel.org; Michael Kelley
> <mikelley@microsoft.com>; Dexuan Cui <decui@microsoft.com>; Tianyu Lan
> <Tianyu.Lan@microsoft.com>
> Subject: [PATCH] x86/hyperv: Properly suspend/resume reenlightenment
> notifications
>
> Errors during hibernation with reenlightenment notifications enabled were
> reported:
>
> [ 51.730435] PM: hibernation entry
> [ 51.737435] PM: Syncing filesystems ...
> ...
> [ 54.102216] Disabling non-boot CPUs ...
> [ 54.106633] smpboot: CPU 1 is now offline
> [ 54.110006] unchecked MSR access error: WRMSR to 0x40000106 (tried
> to
> write 0x47c72780000100ee) at rIP: 0xffffffff90062f24
> native_write_msr+0x4/0x20)
> [ 54.110006] Call Trace:
> [ 54.110006] hv_cpu_die+0xd9/0xf0
> ...
>
> Normally, hv_cpu_die() just reassigns reenlightenment notifications to some
> other CPU when the CPU receiving them goes offline. Upon hibernation, there
> is no other CPU which is still online so cpumask_any_but(cpu_online_mask)
> returns >= nr_cpu_ids and using it as hv_vp_index index is incorrect.
> Disable the feature when cpumask_any_but() fails.
>
> Also, as we now disable reenlightenment notifications upon hibernation we
> need to restore them on resume. Check if hv_reenlightenment_cb was
> previously set and restore from hv_resume().
>
> Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com>
> ---
Looks good to me. Thanks!
Reviewed-by: Dexuan Cui <decui@microsoft.com>
next prev parent reply other threads:[~2020-05-12 21:03 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-05-12 16:01 [PATCH] x86/hyperv: Properly suspend/resume reenlightenment notifications Vitaly Kuznetsov
2020-05-12 21:03 ` Dexuan Cui [this message]
2020-05-13 13:35 ` Tianyu Lan
2020-05-13 15:01 ` Wei Liu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=HK0P153MB016460EAB0E994FFD0653EB2BFBE0@HK0P153MB0164.APCP153.PROD.OUTLOOK.COM \
--to=decui@microsoft.com \
--cc=Tianyu.Lan@microsoft.com \
--cc=kvm@vger.kernel.org \
--cc=linux-hyperv@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mikelley@microsoft.com \
--cc=vkuznets@redhat.com \
--cc=wei.liu@kernel.org \
--cc=x86@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).