From: Juergen Gross <jgross@suse.com>
To: Thomas Gleixner <tglx@linutronix.de>
Cc: linux-kernel@vger.kernel.org, xen-devel@lists.xenproject.org,
x86@kernel.org, boris.ostrovsky@oracle.com,
sstabellini@kernel.org, hpa@zytor.com, mingo@redhat.com,
bp@alien8.de, hans@knorrie.org, stable@vger.kernel.org
Subject: Re: [PATCH v3] xen: Fix x86 sched_clock() interface for xen
Date: Tue, 15 Jan 2019 12:03:48 +0100 [thread overview]
Message-ID: <a50d1213-2390-14f1-fe78-e8058266978c@suse.com> (raw)
In-Reply-To: <alpine.DEB.2.21.1901151142590.1865@nanos.tec.linutronix.de>
On 15/01/2019 11:43, Thomas Gleixner wrote:
> On Mon, 14 Jan 2019, Juergen Gross wrote:
>
>> Commit f94c8d11699759 ("sched/clock, x86/tsc: Rework the x86 'unstable'
>> sched_clock() interface") broke Xen guest time handling across
>> migration:
>>
>> [ 187.249951] Freezing user space processes ... (elapsed 0.001 seconds) done.
>> [ 187.251137] OOM killer disabled.
>> [ 187.251137] Freezing remaining freezable tasks ... (elapsed 0.001 seconds) done.
>> [ 187.252299] suspending xenstore...
>> [ 187.266987] xen:grant_table: Grant tables using version 1 layout
>> [18446743811.706476] OOM killer enabled.
>> [18446743811.706478] Restarting tasks ... done.
>> [18446743811.720505] Setting capacity to 16777216
>
> I see that it's broken, but the changelog could do with an explanation WHY
> it broke.
This seems to be rather complex.
I believe the mentioned commit just ignored Xen guests resulting in a
"stable" clock where it shouldn't, but maybe I have missed another
aspect of this commit which is to blame. I tried to fix that by
replacing using_native_sched_clock() with a hypervisor specific pvops
function.
Unfortunately this didn't work, maybe due to other uses of
using_native_sched_clock() added by later patches. In the end it was
quite clear that updating the Xen clock offset was the right thing to
do, so I ended up with this patch.
Juergen
next prev parent reply other threads:[~2019-01-15 11:03 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-14 12:44 [PATCH v3] xen: Fix x86 sched_clock() interface for xen Juergen Gross
2019-01-14 13:54 ` Boris Ostrovsky
2019-01-16 0:26 ` Hans van Kranenburg
2019-01-15 10:43 ` Thomas Gleixner
2019-01-15 11:03 ` Juergen Gross [this message]
2019-01-16 0:24 ` Hans van Kranenburg
2019-01-16 7:50 ` Juergen Gross
2019-01-16 13:17 ` Boris Ostrovsky
2019-01-16 14:33 ` Juergen Gross
2019-01-16 15:07 ` Boris Ostrovsky
2019-01-16 15:29 ` Juergen Gross
2019-01-16 18:29 ` Boris Ostrovsky
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=a50d1213-2390-14f1-fe78-e8058266978c@suse.com \
--to=jgross@suse.com \
--cc=boris.ostrovsky@oracle.com \
--cc=bp@alien8.de \
--cc=hans@knorrie.org \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=sstabellini@kernel.org \
--cc=stable@vger.kernel.org \
--cc=tglx@linutronix.de \
--cc=x86@kernel.org \
--cc=xen-devel@lists.xenproject.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