Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.kernel > #59018

Bug#871608: linux-image-4.9.0-3-amd64: Linux kernel should handle decreasing cpu steal clock counter gracefully

From Michael Laß <bevan@bi-co.net>
Newsgroups linux.debian.bugs.dist, linux.debian.kernel
Subject Bug#871608: linux-image-4.9.0-3-amd64: Linux kernel should handle decreasing cpu steal clock counter gracefully
Date 2017-09-25 09:40 +0200
Message-ID <utw9I-3eX-9@gated-at.bofh.it> (permalink)
References <ucGoO-4hg-23@gated-at.bofh.it> <utp8d-731-1@gated-at.bofh.it> <ucGoO-4hg-23@gated-at.bofh.it> <utp8d-731-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Cross-posted to 2 groups.

Show all headers | View raw


> Am 25.09.2017 um 02:07 schrieb Ben Hutchings <ben@decadent.org.uk>:
> 
> I agree that the kernel ought to work around this, but I'm hesitant to
> add a fix that doesn't look like any upstream change.  Why and how do
> you think this was fixed in 4.11?

Indeed this patch is not included upstream and won’t be as it does not apply to the current development branch. See the following brief discussion on this on Linux stable: http://www.spinics.net/lists/stable/msg186915.html

The main issue here is the conversion between nsecs and cputime and how this behaves when the calculated difference in steal time overflows, i.e. decreases. In this case cpustat does not overflow and therefore decrease as well but instead increases by a large number. In Linux 4.11 the conversion between nsecs and cputime is entirely gone, which should lead to a backwards running cpustat counter without further issues (I have not actually tested this):

2b1f967d80e8e5d7361f0e1654c842869570f573  sched/cputime: Complete nsec conversion of tick based accounting

This change seems to be only the last commit of a larger change though and I’m not sure if this larger change is suitable for backporting.

I agree that it would be nice to have a patch which has undergone a good review process. Unfortunately I cannot provide that. I also cannot estimate how many people are affected by this issue considering that it did not attract attention over the last year.

Michael

Back to linux.debian.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Bug#871608: linux-image-4.9.0-3-amd64: Linux kernel should handle decreasing cpu steal clock counter gracefully Michael Lass <bevan@bi-co.net> - 2017-08-09 23:10 +0200
  Processed: Re: Bug#871608: linux-image-4.9.0-3-amd64: Linux  kernel should handle decreasing cpu steal clock counter gracefully owner@bugs.debian.org (Debian Bug Tracking System) - 2017-09-25 02:10 +0200
  Bug#871608: linux-image-4.9.0-3-amd64: Linux kernel should handle decreasing cpu steal clock counter gracefully Ben Hutchings <ben@decadent.org.uk> - 2017-09-25 02:10 +0200
    Bug#871608: linux-image-4.9.0-3-amd64: Linux kernel should handle decreasing cpu steal clock counter gracefully Michael Laß <bevan@bi-co.net> - 2017-09-25 09:40 +0200
    Bug#871608: linux-image-4.9.0-3-amd64: Linux kernel should handle decreasing cpu steal clock counter gracefully Michael Laß <bevan@bi-co.net> - 2017-10-13 00:40 +0200
  Bug#871608: linux-image-4.9.0-3-amd64: Linux kernel should handle decreasing cpu steal clock counter gracefully Hans van Kranenburg <hans.van.kranenburg@mendix.com> - 2017-11-15 14:40 +0100
  Bug#871608: linux-image-4.9.0-3-amd64: Linux kernel should handle decreasing cpu steal clock counter gracefully Hans van Kranenburg <hans.van.kranenburg@mendix.com> - 2017-12-01 17:40 +0100

csiph-web