Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp507169ybi; Fri, 26 Jul 2019 13:42:18 -0700 (PDT) X-Google-Smtp-Source: APXvYqxXEft+48+zSlYZB9mthfJhuiQha6r5TDxXfirbxF3DZopOUbpopqDDDQND3j+g7cUcP3b1 X-Received: by 2002:a62:764d:: with SMTP id r74mr25161039pfc.110.1564173738352; Fri, 26 Jul 2019 13:42:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1564173738; cv=none; d=google.com; s=arc-20160816; b=rcTotBNxVHJ8WLNXjzLuIaMwp9LEuld+yV5tvcntrs2gMkjDukVIWyHdj+0grNdO9J 1s+GSlCrfq4lSllRes9mH1JTuNEc/fIlpmLL+plMM3RSB1Z60yA3Je3Jsq16Qw59i6Dh BDhrAODXFIylXI2R7+n1c2nlT/0+luTQaU4KRV/BFdciwlGvWuKwKcA8GlO48OTRFaY4 j4svcLu1i3zn0b+6/XqrJ4/0UP9TNZfbnzA4sowwIi12KlKyiPUk8sbNKcC16eWRGbzG Fe87NM8kUfeBnnIKfCOh8l/hkhqDWbqO6gyOTv/w2gtICC+SnFx2OQGzpbjvBRY/BK5d qktQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :organization:references:in-reply-to:message-id:subject:cc:to:from :date; bh=6w4K4sy+FPYiiLVJ/YlAauOgSW1/TT/FtLDz5K1P8VI=; b=Vu8X0KaPgc9kjamNszWja6oSrRV5l0nu+cHYBn6U7nPFD/6PBLUvVVCe6/wJlcplHy 4RonoRqHPD24ao0nc3h0QcXV63JOZSb8/OzZyR2VFoHJKjwEMCyCgPwJMUUAY5tdSdhb naVsCf/ieNpoLVkSHAjV34j9SFPaj9nDl7Uijya8Oc6cVjAPLzjGqhVrkYFVlYwPlwEq OxKlNzhCpLAtKKpuJZ1zz2Tyxa4buiiI1IPIqr/Dop58pxknTStMfoxdxzEwxm6sHoxc hU3K6KJ9QSYNzrrYcSBmY9Ep0CnELimt8TC/v+fYx+2qeXWcrSMoVqOADgMIJqbWl6NJ 9Kxw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id ci23si44583329pjb.106.2019.07.26.13.42.00; Fri, 26 Jul 2019 13:42:18 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727115AbfGZUlM (ORCPT + 99 others); Fri, 26 Jul 2019 16:41:12 -0400 Received: from ms.lwn.net ([45.79.88.28]:52136 "EHLO ms.lwn.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726184AbfGZUlM (ORCPT ); Fri, 26 Jul 2019 16:41:12 -0400 Received: from lwn.net (localhost [127.0.0.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ms.lwn.net (Postfix) with ESMTPSA id 885E44BF; Fri, 26 Jul 2019 20:41:11 +0000 (UTC) Date: Fri, 26 Jul 2019 14:41:10 -0600 From: Jonathan Corbet To: Phil Frost Cc: Ingo Molnar , trivial@kernel.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] Correct documentation for /proc/schedstat Message-ID: <20190726144110.3b12ae56@lwn.net> In-Reply-To: <20190724185029.26822-1-indigo@bitglue.com> References: <20190724185029.26822-1-indigo@bitglue.com> Organization: LWN.net MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 24 Jul 2019 11:50:27 -0700 Phil Frost wrote: > Commit 425e0968a25fa3f111f9919964cac079738140b5 ("sched: move code into > kernel/sched_stats.h") appears to have inadvertently changed the unit of > time from jiffies to nanoseconds as part of the implementation of CFS. > > Signed-off-by: Phil Frost > --- > Documentation/scheduler/sched-stats.txt | 10 ++++++++-- > 1 file changed, 8 insertions(+), 2 deletions(-) > > diff --git a/Documentation/scheduler/sched-stats.txt b/Documentation/scheduler/sched-stats.txt > index 8259b34a66ae..b6c1807a01b3 100644 > --- a/Documentation/scheduler/sched-stats.txt > +++ b/Documentation/scheduler/sched-stats.txt > @@ -19,6 +19,11 @@ are no architectures which need more than three domain levels. The first > field in the domain stats is a bit map indicating which cpus are affected > by that domain. > > +2.6.23 introduced the CFS scheduler, and also an inadvertent > +backwards-incompatible change to the statistics. Although the schedstat version > +is 14 in either case, in 2.6.23 and later, counters accumulate time in > +nanoseconds. Prior to that, jiffies. Clearly, making the documentation correct is a good thing to do. I do have to wonder if we really have to document how things were 12 years ago as well, though. Anybody who is unfortunate enough to be dealing with a pre-2.6.23 kernel will want to refer to the documentation files shipped with that kernel rather than what we have now. So I'd recommend just making the file reflect the current state of affairs. Thanks, jon