Message ID | 202010281621.09SGLvR81544770@finist-co8.sw.ru |
---|---|
State | New |
Series | "ve/sched/loadavg: loadavg virtualization" |
Headers | show
Delivered-To: criupatchwork@gmail.com Received: from imap.gmail.com [108.177.119.109] by patchwork.criu.org with IMAP (fetchmail-6.4.8) for <root@localhost> (single-drop); Thu, 12 Nov 2020 11:38:50 +0100 (CET) Received: by 2002:a9a:2f:0:b029:91:d28a:c332 with SMTP id 44csp443136lka; Wed, 28 Oct 2020 09:22:13 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxD2kzOfq1oa0XmsAQe2mU8VA/yIgrMMWZYQObeW56vX0fKUD7PpZ1U85lUzmkW5apr2+ba X-Received: by 2002:a05:651c:20d:: with SMTP id y13mr1756ljn.425.1603902133256; Wed, 28 Oct 2020 09:22:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1603902133; cv=none; d=google.com; s=arc-20160816; b=BtHtmhmr7KH3W4CbxF2JGcDNwWl507ZxNT31vWuQHDC1m8tc15QyNeZJw+UrvxrrO3 qtEujNTmdh7G0gMumTYpBZ2ISdY9f2zSeFgMkUJyLYeml33WG9rH9W6tDCJnUDOp4na2 4PhQqlT9vR5VWR6BnSArHgvEeKSTqAZO7wBioWABgeWC/IIDo2aseQTEmtRGG9AuvaBQ HP0x/+s9qZo73tqV/JEdPI+pPEuovfMAzXTF2VoZsDi9qrfmOimHCPJBk9lZQwxzLJky FEVGqpYJtzYCA63hzYRlqpIGi5fnZXuy3YaGI+X5ltDAruT33AkPSyfBZO2zhV8u2I7h 74hQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:list-subscribe:list-help :list-post:list-archive:list-unsubscribe:list-id:precedence:subject :cc:mime-version:in-reply-to:to:from:message-id:date; bh=BlICYPkq3kJ/UgAp5hbUYPs84yqftg0wiIIuFNxrdCA=; b=S5ah5G+r76nOFKGI/5Ch1jBs7AvH9PMfuLE0KgLWUiKEiA0DRqUukD3VgvU9iWz8Ln SUQvFiLt5sYt6eNUw6IqiHzGjQMADj4yBrN/PkV1MCQkTN4x/0EravxrZ/ikKyd2VKhY UrwIdlnqAZDZZqtyoq/spIaOwf25ALdMF6nAH39V1HqBS9skutVEpf84fkCErKcy4rKG k/nV1Iytc1+XzCHJ/u+E/xdLVkE0fBmIzW7yFDPeN2AdoqYy+P4Hca3Htv09g5FdgAeL GMyHqtqhD7FBExsgGkrg9kBJJfClJNZSdjgcyUc6zx4DbqCS6ZqsIJTm+KIXga+NMkF/ rQXw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of devel-bounces@openvz.org designates 185.231.241.50 as permitted sender) smtp.mailfrom=devel-bounces@openvz.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=virtuozzo.com Return-Path: <devel-bounces@openvz.org> Received: from mail.openvz.org (mail.openvz.org. [185.231.241.50]) by mx.google.com with ESMTPS id e22si2389260ljn.174.2020.10.28.09.22.11 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Wed, 28 Oct 2020 09:22:12 -0700 (PDT) Received-SPF: pass (google.com: domain of devel-bounces@openvz.org designates 185.231.241.50 as permitted sender) client-ip=185.231.241.50; Authentication-Results: mx.google.com; spf=pass (google.com: domain of devel-bounces@openvz.org designates 185.231.241.50 as permitted sender) smtp.mailfrom=devel-bounces@openvz.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=virtuozzo.com Received: from localhost.localdomain (localhost [127.0.0.1]) by mail.openvz.org (8.14.4/8.14.4) with ESMTP id 09SGLw6I007145; Wed, 28 Oct 2020 19:21:58 +0300 Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-he1eur04lp2054.outbound.protection.outlook.com [104.47.13.54]) by mail.openvz.org (8.14.4/8.14.4) with ESMTP id 09SGLuWe007141 for <devel@openvz.org>; Wed, 28 Oct 2020 19:21:56 +0300 Received: from DB6PR07CA0023.eurprd07.prod.outlook.com (2603:10a6:6:2d::33) by AM9PR08MB5873.eurprd08.prod.outlook.com (2603:10a6:20b:2dd::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3499.18; Wed, 28 Oct 2020 16:21:59 +0000 Received: from DB5EUR01FT038.eop-EUR01.prod.protection.outlook.com (2603:10a6:6:2d:cafe::fc) by DB6PR07CA0023.outlook.office365.com (2603:10a6:6:2d::33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3499.9 via Frontend Transport; Wed, 28 Oct 2020 16:21:59 +0000 Authentication-Results: spf=pass (sender IP is 185.231.240.75) smtp.mailfrom=virtuozzo.com; openvz.org; dkim=none (message not signed) header.d=none; openvz.org; dmarc=pass action=none header.from=virtuozzo.com; Received-SPF: Pass (protection.outlook.com: domain of virtuozzo.com designates 185.231.240.75 as permitted sender) receiver=protection.outlook.com; client-ip=185.231.240.75; helo=relay3.sw.ru; Received: from relay3.sw.ru (185.231.240.75) by DB5EUR01FT038.mail.protection.outlook.com (10.152.4.191) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3520.15 via Frontend Transport; Wed, 28 Oct 2020 16:21:58 +0000 Received: from [10.94.5.150] (helo=finist-co8.sw.ru) by relay3.sw.ru with esmtp (Exim 4.94) (envelope-from <khorenko@virtuozzo.com>) id 1kXoCo-006XKU-4p; Wed, 28 Oct 2020 19:21:46 +0300 Received: from finist-co8.sw.ru (localhost [127.0.0.1]) by finist-co8.sw.ru (8.15.2/8.15.2) with ESMTPS id 09SGLvTY1544771 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT); Wed, 28 Oct 2020 19:21:57 +0300 Received: (from khorenko@localhost) by finist-co8.sw.ru (8.15.2/8.15.2/Submit) id 09SGLvR81544770; Wed, 28 Oct 2020 19:21:57 +0300 Date: Wed, 28 Oct 2020 19:21:57 +0300 Message-Id: <202010281621.09SGLvR81544770@finist-co8.sw.ru> X-Authentication-Warning: finist-co8.sw.ru: khorenko set sender to khorenko@virtuozzo.com using -f From: Konstantin Khorenko <khorenko@virtuozzo.com> To: Konstantin Khorenko <khorenko@virtuozzo.com> In-Reply-to: <20201022125452.367506-7-khorenko@virtuozzo.com> X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email MIME-Version: 1.0 X-MS-Office365-Filtering-Correlation-Id: e462dde6-214b-439a-7f3d-08d87b5d9816 X-MS-TrafficTypeDiagnostic: AM9PR08MB5873: X-Forefront-Antispam-Report: CIP:185.231.240.75; CTRY:RU; LANG:en; SCL:-1; SRV:; IPV:CAL; SFV:SKN; H:relay3.sw.ru; PTR:relay.sw.ru; CAT:NONE; SFS:; DIR:INB; X-MS-Oob-TLC-OOBClassifiers: OLM:133; X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?94MO0rO47LlG0PhvqeHdRAINkJZ5S4qtZjh/tM8g6sRJeFPP2wbuehwBnKAO?= =?us-ascii?Q?pe7a1P1/crAHnN2FOd5YeDm25tLA7UY8eIPXFJTy8zNzcgzuzSq8OJKxzV9D?= =?us-ascii?Q?ijx3/prucisQtX3TTlzWmo3Ivsqp2k71+tGwoaYvZVtEFUT+30HbL9uSqEk9?= =?us-ascii?Q?xjPGFkY2iGQpNTdQaOrMc78iAf07zonv6DLgakf0QBxoi6IWiNa7heQ6ENen?= =?us-ascii?Q?hka+TzaBrkwFerIOsL0kMmoUpYY7trzVAdLGIFQEU7htYL4QSvlgOKJgeD/U?= =?us-ascii?Q?pieHXEC1Gyy8Al2yK8EzVZpJTO3w43RPgiJIlUsNyvcNTcEqN5svOgcCYnq8?= =?us-ascii?Q?+ediegPQesMLFVWEsZUjxhSS+5jZZtKaU8M3zFT5y3Pz6Qdk8STB5V55erSR?= =?us-ascii?Q?Vr0V+zyIHR76z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fgLa322tyx1EeKX?= =?us-ascii?Q?3dTopBuWho6G/KA4QT48ZXMr4auQ0/gMReRqMMl6N/R2+jxfEe6vS8IrETzm?= =?us-ascii?Q?+/eo8qbe5g34xewadhtmy8gasCeLLPYmopCocXcJwBlxS8tyBf71drBM0vG3?= =?us-ascii?Q?U3fpu+ovq8G6KRktWJ0dbuWrQ2wlxefB?= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 28 Oct 2020 16:21:58.6691 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: e462dde6-214b-439a-7f3d-08d87b5d9816 X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=0bc7f26d-0264-416e-a6fc-8352af79c58f; Ip=[185.231.240.75]; Helo=[relay3.sw.ru] X-MS-Exchange-CrossTenant-AuthSource: DB5EUR01FT038.eop-EUR01.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR08MB5873 X-MS-Exchange-CrossPremises-OriginalClientIPAddress: 185.231.240.75 X-MS-Exchange-CrossPremises-TransportTrafficType: Email X-MS-Exchange-CrossPremises-AuthSource: DB5EUR01FT038.eop-EUR01.prod.protection.outlook.com X-MS-Exchange-CrossPremises-AuthAs: Anonymous X-MS-Exchange-CrossPremises-SCL: -1 X-MS-Exchange-CrossPremises-Processed-By-Journaling: Journal Agent X-OrganizationHeadersPreserved: AM9PR08MB5873.eurprd08.prod.outlook.com Cc: OpenVZ devel <devel@openvz.org> Subject: [Devel] [PATCH RHEL8 COMMIT] vzstat: Add kstat_glob.nr_unint_avg real accounting X-BeenThere: devel@openvz.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: OpenVZ development <devel.openvz.org> List-Unsubscribe: <https://lists.openvz.org/mailman/options/devel>, <mailto:devel-request@openvz.org?subject=unsubscribe> List-Archive: <http://lists.openvz.org/pipermail/devel/> List-Post: <mailto:devel@openvz.org> List-Help: <mailto:devel-request@openvz.org?subject=help> List-Subscribe: <https://lists.openvz.org/mailman/listinfo/devel>, <mailto:devel-request@openvz.org?subject=subscribe> Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: devel-bounces@openvz.org Errors-To: devel-bounces@openvz.org |
diff --git a/kernel/sched/loadavg.c b/kernel/sched/loadavg.c index c62f34033112..c76b1c842ad8 100644 --- a/kernel/sched/loadavg.c +++ b/kernel/sched/loadavg.c @@ -105,7 +105,7 @@ extern spinlock_t load_ve_lock; void calc_load_ve(void) { - unsigned long nr_active; + unsigned long nr_unint, nr_active; struct task_group *tg; int i; @@ -137,6 +137,14 @@ void calc_load_ve(void) tg->avenrun[1] = calc_load(tg->avenrun[1], EXP_5, nr_active); tg->avenrun[2] = calc_load(tg->avenrun[2], EXP_15, nr_active); } + + nr_unint = nr_uninterruptible() * FIXED_1; + + write_seqcount_begin(&kstat_glob.nr_unint_avg_seq); + calc_load(kstat_glob.nr_unint_avg[0], EXP_1, nr_unint); + calc_load(kstat_glob.nr_unint_avg[1], EXP_5, nr_unint); + calc_load(kstat_glob.nr_unint_avg[2], EXP_15, nr_unint); + write_seqcount_end(&kstat_glob.nr_unint_avg_seq); spin_unlock(&load_ve_lock); } #endif /* CONFIG_VE */
The commit is pushed to "branch-rh8-4.18.0-193.6.3.vz8.4.x-ovz" and will appear at https://src.openvz.org/scm/ovz/vzkernel.git after rh8-4.18.0-193.6.3.vz8.4.14 ------> commit fe6585fb13b2318202f0dba0cab87ca410b2c593 Author: Konstantin Khorenko <khorenko@virtuozzo.com> Date: Mon Oct 19 13:57:36 2020 +0300 vzstat: Add kstat_glob.nr_unint_avg real accounting This should be a part of commit 127bd48f3385 ("vzstat: Add vzstat module and kstat interfaces") but depends on task_group::avenrun accounting and thus goes separately. Signed-off-by: Konstantin Khorenko <khorenko@virtuozzo.com> --- kernel/sched/loadavg.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-)