Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp2298600pxk; Mon, 14 Sep 2020 09:33:33 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwbaFm9QmvMUB5z0oqpUIJ6PY7tyNI0sZq+n4wj9h2FNiVumJ8Khkk/RrNuurLSQHqsRU6P X-Received: by 2002:a50:fa81:: with SMTP id w1mr17695138edr.122.1600101213237; Mon, 14 Sep 2020 09:33:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600101213; cv=none; d=google.com; s=arc-20160816; b=wHhC1Vs0BfrDWD7GCGcAb1LRPfe08gGuclFQz0TI551PFAU8HLXXJQU+S49H0TKXhy edLqNIbJU9ZCj2ubvf+AbyELgceJZiS/QiFR1JFgg9Nyrdz/czx0ndUIQEEfnGeB20K4 799l9O1iY7Ef8CggJSRyHV47Fys0zEr9a3g7GEyNCcIlipQgxOO6gyRC91j+7yLzYv9A bgGmqB38LIsg1ZO0LtaDqWJWGKd3J7XsnjV2RnJ2QXa863Oo2qDiXVUZsBM3W5JgmT+1 DHfzv5hMPdlvmNr4z3Pum0IStcanF8E9ijzcLGwPnNwcDhadNVeTV5Ta5Z2yZCm06fbR xh9Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-language :content-transfer-encoding:in-reply-to:mime-version:user-agent:date :message-id:from:references:to:subject:dkim-signature; bh=Evh2jsniAFKHtrc5+Oi5f7q5JnurDPbwp2ePFfWfGgA=; b=yVU6iUdOQhANTEHz7Ob1p1Z9sNHx5BVPJn8ecpqV4XZ5FF4MWR8V5Um5bWaFAJgbye qNYxSKWX7XtPkfRo7neB5pf0nDmc527w/bs0ztUWRBWbH+kPmuqyNpVoarYfGb2UqbDw Ecrv+MVWS3NnYcPnVnSb1E/yS1YBczrtpkcKZR4FBTTgsZPCdd69m+QkBKit4JHTvR+j spv4A3zy7/DhlX4vT7EYsZxDFTl0lqv1F5rAdElX5k0f8/ff60//W1j9m8oicbflcbqQ nlLOeFZU2LSDY/muGGflSvWImuBmCdKC4/g8Po4L7TKCza+/b1wzRuQqgqHvz6J9VhOH A3yw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2020-01-29 header.b=g4+VVkyn; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=oracle.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id q14si7039717ejc.297.2020.09.14.09.33.09; Mon, 14 Sep 2020 09:33:33 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2020-01-29 header.b=g4+VVkyn; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=oracle.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726024AbgINQci (ORCPT + 99 others); Mon, 14 Sep 2020 12:32:38 -0400 Received: from userp2130.oracle.com ([156.151.31.86]:41028 "EHLO userp2130.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726162AbgINQcO (ORCPT ); Mon, 14 Sep 2020 12:32:14 -0400 Received: from pps.filterd (userp2130.oracle.com [127.0.0.1]) by userp2130.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 08EGPXrX112214; Mon, 14 Sep 2020 16:31:56 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=subject : to : references : from : message-id : date : mime-version : in-reply-to : content-type : content-transfer-encoding; s=corp-2020-01-29; bh=Evh2jsniAFKHtrc5+Oi5f7q5JnurDPbwp2ePFfWfGgA=; b=g4+VVkynB3PXXkpaEe3vbY2N5Hj/gkN3QmlYB+JVQ/RmurzmNnTZnPMuhRI4p76N61ui BabxXQh9sUugesUMD9B8aFk3gxlCfJ94SXfrqk1CEqLe06eIlMomnTvaQHdPf1zy1fnl CVvEFdNPOIiBO6fFA+y1/apY9n9nMzy7BYoPB5ImJCu2zi5nAUTQrfQoH/9Bgsicvh11 4ca41Qp1xXBq4c3b1+7eZV9H289lZyxZnmqn/pvBSqEz0LUT1W+RxYKxdDZkhI7blt8D L28lrqlBpLUZkNsPy2FMHgjM+EXNPHrTgxGDkEauxcH9Bj6IQrR1hQ/ks1Yaxjtx7hVv FQ== Received: from aserp3030.oracle.com (aserp3030.oracle.com [141.146.126.71]) by userp2130.oracle.com with ESMTP id 33gnrqqqb2-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 14 Sep 2020 16:31:56 +0000 Received: from pps.filterd (aserp3030.oracle.com [127.0.0.1]) by aserp3030.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 08EGTtNW142320; Mon, 14 Sep 2020 16:31:56 GMT Received: from userv0122.oracle.com (userv0122.oracle.com [156.151.31.75]) by aserp3030.oracle.com with ESMTP id 33h7wmennp-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 14 Sep 2020 16:31:55 +0000 Received: from abhmp0020.oracle.com (abhmp0020.oracle.com [141.146.116.26]) by userv0122.oracle.com (8.14.4/8.14.4) with ESMTP id 08EGVsWH013859; Mon, 14 Sep 2020 16:31:54 GMT Received: from OracleT490.vogsphere (/73.203.30.179) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Mon, 14 Sep 2020 16:31:54 +0000 Subject: Re: [RESEND PATCH 0/2] iowait and idle fixes in /proc/stat To: linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org, fweisbec@gmail.com, tglx@linutronix.de, mingo@kernel.org, adobriyan@gmail.com References: <20200909144122.77210-1-tom.hromatka@oracle.com> From: Tom Hromatka Message-ID: <11c8b2ee-7d87-ae0b-c11b-71a052865000@oracle.com> Date: Mon, 14 Sep 2020 10:31:51 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.11.0 MIME-Version: 1.0 In-Reply-To: <20200909144122.77210-1-tom.hromatka@oracle.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9744 signatures=668679 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 adultscore=0 bulkscore=0 phishscore=0 mlxlogscore=999 mlxscore=0 spamscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2006250000 definitions=main-2009140133 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9744 signatures=668679 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 phishscore=0 spamscore=0 lowpriorityscore=0 malwarescore=0 mlxscore=0 bulkscore=0 suspectscore=0 clxscore=1015 mlxlogscore=999 adultscore=0 priorityscore=1501 impostorscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2006250000 definitions=main-2009140132 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Thanks for your time and  feedback, Thomas and Alexey.  I'll address the comments and send out a v2 in the next couple days. Thanks! Tom On 9/9/20 8:41 AM, Tom Hromatka wrote: > A customer is using /proc/stat to track cpu usage in a VM and noted > that the iowait and idle times behave strangely when a cpu goes > offline and comes back online. > > This patchset addresses two issues that can cause iowait and idle > to fluctuate up and down. With these changes, cpu iowait and idle > now only monotonically increase. > > Tom Hromatka (2): > tick-sched: Do not clear the iowait and idle times > /proc/stat: Simplify iowait and idle calculations when cpu is offline > > fs/proc/stat.c | 24 ++++++------------------ > kernel/time/tick-sched.c | 9 +++++++++ > 2 files changed, 15 insertions(+), 18 deletions(-) >