Received: by 2002:a25:868d:0:0:0:0:0 with SMTP id z13csp1499808ybk; Sun, 10 May 2020 19:06:48 -0700 (PDT) X-Google-Smtp-Source: APiQypLZmOXT2X2swSFteVYCUfsgsYJ+o+iBX0l722IOEeeRyoLEgtguntopVVWnlsbPoYSu2cn8 X-Received: by 2002:a17:906:3da:: with SMTP id c26mr11647244eja.290.1589162808213; Sun, 10 May 2020 19:06:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1589162808; cv=none; d=google.com; s=arc-20160816; b=heYTOJQovr1FujM8JN2+I5dubl7yKvKpohut3/Oh6CqKOS4piZDaH2Vr/2OXmTgWyk r9R/1dKvaA/ivBQMI9EbJIh2pm+/1c4QdJzYca/y6dfSLgEKf5RvcS8nsVRJXL/enghC orE4Log1itv3Lf2j1MP80dOSXrRSBxV1J0V6rNQLiaRK4ipn1EtqGoC8Jx/T+rW45tIt NZolr7NwnJ8e/V6iHxanMNPlGBeLNwdGsZogQRjIyrc5lPxoVzy7WMOPAnd1vhkM7mm4 N+BlVCoqIuxy0nyjFpZyedhvKr630nVmBp8m13Qfqpi/hoNYPNuummmm9G1MpME4RFRL NTqw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dmarc-filter:dkim-signature; bh=sKT+oxTM1IiLkHUsa6WEuo4yedQX4JYSfJZMYeF+gSg=; b=IbD/LEl6d/bMrd7af6X2scP/wuj2mfKg9xiIavapsSVXxN5pGjp09D3zzRVL20SADu Vdhlxui9KHBr4lClS/hxNpCs9vLoU71lazl0jZVANGfdp6v7yGMBBWhoEqNCuGCdWlfT j+SLi6yYPMd6E0Eb3t/BYd5dOdLw2KClBol+BCwHx/ZeFKh1A+bYuyYS0uy8g3RpwhS+ NNI5HB/a5I4lnlce0amBjSyYfvKC6UHicDq5XE75GbEGuDbh+eXJx8nf2qesoXLTqVZo HRybkpMBE0MX5ttbAu+DTv69SWEzOt5M8zQkkpEUiUg04+Mfc4Uyd/7sLcvntq7B/DFY zRZw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@mg.codeaurora.org header.s=smtp header.b=SOO0YQg1; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id x2si5327740ejw.475.2020.05.10.19.06.15; Sun, 10 May 2020 19:06:48 -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=fail header.i=@mg.codeaurora.org header.s=smtp header.b=SOO0YQg1; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729085AbgEKByN (ORCPT + 99 others); Sun, 10 May 2020 21:54:13 -0400 Received: from mail26.static.mailgun.info ([104.130.122.26]:16772 "EHLO mail26.static.mailgun.info" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727789AbgEKByN (ORCPT ); Sun, 10 May 2020 21:54:13 -0400 DKIM-Signature: a=rsa-sha256; v=1; c=relaxed/relaxed; d=mg.codeaurora.org; q=dns/txt; s=smtp; t=1589162053; h=Message-Id: Date: Subject: Cc: To: From: Sender; bh=sKT+oxTM1IiLkHUsa6WEuo4yedQX4JYSfJZMYeF+gSg=; b=SOO0YQg18W4wuJFwD8Um67oEI9Llhl05i6Di5mbZNYDsbzzZWpFSvuYcL/1Zc9TOQohK59pI qFAxJokL6vch9sDsZkwTZYwj4uysHiu50YscaUnD+tMljO8r8HjgY+m7XsV1ZgLj5y+P8XR8 9/vbygyLMfxT58e+iqq0jNgebQc= X-Mailgun-Sending-Ip: 104.130.122.26 X-Mailgun-Sid: WyI0MWYwYSIsICJsaW51eC1rZXJuZWxAdmdlci5rZXJuZWwub3JnIiwgImJlOWU0YSJd Received: from smtp.codeaurora.org (ec2-35-166-182-171.us-west-2.compute.amazonaws.com [35.166.182.171]) by mxa.mailgun.org with ESMTP id 5eb8b033.7ffa428a06c0-smtp-out-n02; Mon, 11 May 2020 01:53:55 -0000 (UTC) Received: by smtp.codeaurora.org (Postfix, from userid 1001) id 0585FC44791; Mon, 11 May 2020 01:53:53 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-caf-mail-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=2.0 tests=ALL_TRUSTED,SPF_NONE autolearn=unavailable autolearn_force=no version=3.4.0 Received: from codeaurora.org (blr-c-bdr-fw-01_GlobalNAT_AllZones-Outside.qualcomm.com [103.229.19.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: pkondeti) by smtp.codeaurora.org (Postfix) with ESMTPSA id 924B4C433CB; Mon, 11 May 2020 01:53:49 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 924B4C433CB Authentication-Results: aws-us-west-2-caf-mail-1.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: aws-us-west-2-caf-mail-1.web.codeaurora.org; spf=none smtp.mailfrom=pkondeti@codeaurora.org From: Pavankumar Kondeti To: linux-kernel@vger.kernel.org Cc: Pavankumar Kondeti , Ingo Molnar , Peter Zijlstra , Juri Lelli , Vincent Guittot , Dietmar Eggemann , Steven Rostedt , Ben Segall , Mel Gorman , Valentin Schneider , Qais Yousef Subject: [PATCH v2] sched/debug: Fix requested task uclamp values shown in procfs Date: Mon, 11 May 2020 07:23:30 +0530 Message-Id: <1589162011-4998-1-git-send-email-pkondeti@codeaurora.org> X-Mailer: git-send-email 2.7.4 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The intention of commit 96e74ebf8d59 ("sched/debug: Add task uclamp values to SCHED_DEBUG procfs") was to print requested and effective task uclamp values. The requested values printed are read from p->uclamp, which holds the last effective values. Fix this by printing the values from p->uclamp_req. Fixes: 96e74ebf8d59 ("sched/debug: Add task uclamp values to SCHED_DEBUG procfs") Tested-and-reviewed-by: Valentin Schneider Signed-off-by: Pavankumar Kondeti --- V2: Added "requested" prefix (suggested by Valentin) kernel/sched/debug.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kernel/sched/debug.c b/kernel/sched/debug.c index a562df5..77ecebd 100644 --- a/kernel/sched/debug.c +++ b/kernel/sched/debug.c @@ -948,8 +948,8 @@ void proc_sched_show_task(struct task_struct *p, struct pid_namespace *ns, P(se.avg.util_est.enqueued); #endif #ifdef CONFIG_UCLAMP_TASK - __PS("uclamp.min", p->uclamp[UCLAMP_MIN].value); - __PS("uclamp.max", p->uclamp[UCLAMP_MAX].value); + __PS("requested uclamp.min", p->uclamp_req[UCLAMP_MIN].value); + __PS("requested uclamp.max", p->uclamp_req[UCLAMP_MAX].value); __PS("effective uclamp.min", uclamp_eff_value(p, UCLAMP_MIN)); __PS("effective uclamp.max", uclamp_eff_value(p, UCLAMP_MAX)); #endif -- Qualcomm India Private Limited, on behalf of Qualcomm Innovation Center, Inc. Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project.